@extends('layouts.app') @section('title', $patient->full_name . ' - EMR Record') @section('content')
{{ strtoupper(substr($patient->first_name, 0, 1)) }}{{ strtoupper(substr($patient->last_name, 0, 1)) }}

{{ $patient->full_name }}

{{ $patient->blood_group }} @if($patient->currentIpdAdmission) Admitted: {{ $patient->currentIpdAdmission->bed->bed_number }} @endif
Age: {{ $patient->age ?? 'N/A' }} yrs Gender: {{ $patient->gender }} Mobile: {{ $patient->mobile }} UHID: {{ $patient->uhid }}
{{ $patient->full_address }}
{!! $barcodeSvg !!}
Unique Patient Identification
Book OPD Visit @if(! $patient->currentIpdAdmission) Admit Patient @else View IPD Case @endif
@if($patient->known_allergies || $patient->existing_diseases)
@if($patient->known_allergies)
Known Drug / Food Allergies {{ $patient->known_allergies }}
@endif @if($patient->existing_diseases)
Chronic Diseases / Medical History {{ $patient->existing_diseases }}
@endif
@endif

Clinical Vitals History

@if($patient->vitals->count() > 0)
@foreach($patient->vitals as $v) @endforeach
Date / Time BP (mmHg) Pulse (bpm) Temp (°F) SpO2 (%) Resp Rate BMI RBS (mg/dL)
{{ $v->recorded_at->format('d/m/Y h:i A') }} {{ $v->systolic_bp && $v->diastolic_bp ? "{$v->systolic_bp}/{$v->diastolic_bp}" : '—' }} {{ $v->pulse_rate ?? '—' }} {{ $v->temperature_f ? "{$v->temperature_f}°F" : '—' }} {{ $v->spo2_percent ? "{$v->spo2_percent}%" : '—' }} {{ $v->respiratory_rate ?? '—' }} {{ $v->bmi ?? '—' }} {{ $v->blood_sugar_mgdl ?? '—' }}
@else
No vital signs recorded yet.
@endif

Clinical Notes & Diagnoses

@forelse($patient->clinicalNotes as $note)
{{ $note->doctor->full_name }} ({{ $note->doctor->department->name }}) {{ $note->note_date->format('d M Y, h:i A') }}
@if($note->chief_complaints)
Chief Complaints: {{ $note->chief_complaints }}
@endif @if($note->clinical_impression)
Impression / Diagnosis: {{ $note->clinical_impression }}
@endif @if($note->treatment_plan)
Plan: {{ $note->treatment_plan }}
@endif
@empty
No clinical consultation notes recorded yet.
@endforelse

Outpatient Consultation Records

@forelse($patient->opdVisits as $v) @empty @endforelse
Visit # Date / Time Doctor Department Token Status Actions
{{ $v->visit_number }} {{ $v->visit_date->format('d/m/Y') }} {{ $v->visit_time }} {{ $v->doctor->full_name }} {{ $v->department->name }} #{{ $v->token_number }} {{ $v->queue_status }} Consultation Slip
No OPD visits found.

Medical Prescriptions

@forelse($patient->prescriptions as $rx)
{{ $rx->prescription_number }} • {{ $rx->prescription_date->format('d/m/Y') }} • By {{ $rx->doctor->full_name }}
Print Rx
@foreach($rx->items as $item)
{{ $item->medicine_name }} ({{ $item->dosage }})
{{ $item->frequency }} • {{ $item->duration_val }} {{ $item->duration_unit }} • {{ $item->food_relation }}
@endforeach
@empty
No prescriptions on record.
@endforelse

Diagnostic Laboratory Orders & Reports

@forelse($patient->labOrders as $lo) @empty @endforelse
Order Number Date Tests Ordered Priority Status Action
{{ $lo->order_number }} {{ $lo->order_date->format('d/m/Y') }} @foreach($lo->items as $it) {{ $it->test->name }} @endforeach {{ $lo->priority }} {{ $lo->status }} View Report
No laboratory investigations found.

Inpatient Admission History

@forelse($patient->ipdAdmissions as $adm) @empty @endforelse
Admission # Admitted Date Ward & Bed Consultant Diagnosis Status Action
{{ $adm->admission_number }} {{ $adm->admission_date->format('d/m/Y h:i A') }} {{ $adm->ward->name }} - {{ $adm->bed->bed_number }} {{ $adm->primaryDoctor->full_name }} {{ $adm->provisional_diagnosis }} {{ $adm->status }} View Case
No inpatient admission records.

Invoices & Financial Receipts

@forelse($patient->invoices as $inv) @empty @endforelse
Invoice # Date Total Amount Paid Amount Balance Due Status Action
{{ $inv->invoice_number }} {{ $inv->invoice_date->format('d/m/Y') }} ₹{{ number_format($inv->grand_total, 2) }} ₹{{ number_format($inv->paid_amount, 2) }} ₹{{ number_format($inv->balance_due, 2) }} {{ $inv->payment_status }} View Print
No invoices issued for this patient.
@endsection