@extends('Admin.layout') @section('content') {{-- Header --}}
Details
{{-- Patient identity strip --}}
{{ strtoupper(substr($patient->patient_name, 0, 1)) }}
{{ $patient->patient_name }}
Patient ID · {{ $patient->sheet_no }}
{{-- Step navigation --}}
{{-- Form panel --}}
Past History
{{-- Past history record — collapsible accordion --}}
@forelse($pastHistoryRecord as $entry) @php $tags = []; $details = []; if ($entry->hypertension == 'yes') { $tags[] = 'Hypertension'; if ($entry->hypertension_details) { $details[] = $entry->hypertension_details; } } if ($entry->dm == 'yes') { $tags[] = 'DM'; if ($entry->dm_details) { $details[] = $entry->dm_details; } } if ($entry->cad == 'yes') { $tags[] = 'CAD'; if ($entry->cad_details) { $details[] = $entry->cad_details; } } if ($entry->thyroid == 'yes') { $tags[] = 'Thyroid'; if ($entry->thyroid_details) { $details[] = $entry->thyroid_details; } } if ($entry->ckd == 'yes') { $tags[] = 'CKD'; if ($entry->ckd_details) { $details[] = $entry->ckd_details; } } if ($entry->cva == 'yes') { $tags[] = 'CVA'; if ($entry->cva_details) { $details[] = $entry->cva_details; } } @endphp
{{ $entry->created_at->format('d M Y') }} {{ $entry->created_at->format('h:i A') }}
@foreach($tags as $tag) {{ $tag }} @endforeach

{{ count($details) ? implode(' | ', $details) : 'No additional notes recorded.' }}

@empty
No past history found.
@endforelse
@csrf
@php $conditions = ['Hypertension', 'DM', 'CAD', 'Thyroid', 'CKD', 'CVA']; @endphp @foreach($conditions as $i => $condition)
{{ $condition }}
Yes
No
@endforeach
{{-- Sticky bottom action bar --}}
@endsection