@extends(session('staff_logged_in') ? 'Staff.layout' : 'Admin.layout') @push('styles') @endpush @section('content')

{{ $patient->patient_name }}

Patient
{{ $patient->sheet_no }} {{ $patient->phone }} @if($patient->gender) {{ $patient->gender }} @endif @if($patient->age) {{ $patient->age }} Years @endif
@if($patient->blood_group) {{ $patient->blood_group }} @endif @if($patient->place) {{ $patient->place }} @endif
{{-- Sidebar Tabs + Content --}}
{{-- Vertical Tabs (sidebar on laptop, stacked pills on mobile) — UNCHANGED --}}
{{-- Tab Content --}}
{{-- Profile Tab (now editable) --}}
@csrf @method('PUT') {{-- Basic Details Card --}}
Basic Details
{{-- Address Card --}}
Address
{{-- Emergency Contact Card --}}
Emergency Contact
@error('guardian_relation') {{ $message }} @enderror
{{-- Body Health Tab (now editable) --}}
@php $savedPrakritiJson = $patient->prakritis->map(function ($p) { return [ 'row' => $p->row_no, 'dosha' => $p->dosha, 'option' => $p->option_text, ]; }); @endphp
@csrf
Prakriti Analysis
# Characteristics Vata Pitta Kapha
1 Body Frame
2 Type of Hair
3 Colour of Hair
4 Skin
5 Complexion
6 Body Weight
7 Nails
8 Size and Color of the Teeth
9 Pace of Performing Work
10 Mental Activity
11 Memory
12 Grasping power
13 Sleep Pattern
14 Intolerance to weather Conditions
15 Reactions Under Adverse Situation
16 Mood
17 Eating Habit
18 Hunger
19 Body Temperature
20 Joints
21 Nature
22 Body Energy
23 Eyeball
24 Quality of Voice
25 Dreams
26 Social Relations
27 Wealth
28 Bowel Movements
29 Walking Pace
30 Communication Skills
Vata 0
Pitta 0
Kapha 0
{{-- Medical Tab (now editable) --}}
@csrf {{-- Medical History Card --}}
Medical History
{{-- Insurance Card --}}
Insurance
{{-- Lifestyle Card --}}
Lifestyle
{{-- Reports Tab — UNCHANGED --}}
Reports
@forelse($reports as $report)
{{ $report->reportType->report_type ?? '-' }}
{{ $report->report_date }}{{ $report->notes ? ' • ' . $report->notes : '' }}
@if($report->file_path) @endif
@empty

No reports added yet

@endforelse
{{-- Cases Tab — UNCHANGED --}}
Cases
@forelse($cases as $case) @empty @endforelse
Date Title Type Doctor Follow Up Follow Up Status Action
{{ $case->created_at->format('d M Y') }} {{ $case->title }} {{ $case->type == 'text' ? 'Text' : 'Handwritten' }} {{ $case->doctor->doctor_name ?? '-' }} @if($case->followUps->isNotEmpty()) {{ $case->followUps->first()->follow_up_date ?? '-' }} @else - @endif @php $latestFollowup = $case->followUps->sortByDesc('follow_up_date')->first(); @endphp @if($latestFollowup) @php $class = match ($latestFollowup->status) { 'Completed' => 'bg-label-success', 'Cancelled' => 'bg-label-danger', 'Pending' => 'bg-label-warning', default => 'bg-label-secondary', }; @endphp {{ $latestFollowup->status }} @else No Follow Up @endif

No case notes added yet

{{-- Followups Tab --}}
Follow Ups
@forelse($followups as $followup) @empty @endforelse
Date Doctor Remarks Status
{{ \Carbon\Carbon::parse($followup->followup_date)->format('d-m-Y') }} {{ $followup->doctor->doctor_name ?? '-' }} {{ $followup->notes ?? '-' }} @php $cls = match ($followup->status) { 'Completed' => 'bg-label-success', 'Pending' => 'bg-label-warning', 'Cancelled' => 'bg-label-danger', default => 'bg-label-secondary' }; @endphp {{ $followup->status }}

No follow ups found

{{-- Appointments Tab — UNCHANGED --}}
Appointments
{{-- Inline Appointment Form --}}
@forelse($appointments as $apt) @empty @endforelse
Doctor Date Time Consulation Status
{{ $apt->doctor->doctor_name ?? '-' }} {{ $apt->appointment_date }} {{ $apt->appointment_time }} @if($apt->consultation) Consultation @else Not added @endif @php $cls = match ($apt->status) { 'Confirmed' => 'bg-label-success', 'Cancelled' => 'bg-label-danger', 'Closed' => 'bg-label-info', 'Completed' => 'bg-label-primary', default => 'bg-label-warning' }; @endphp {{ $apt->status }}

No appointments found

{{-- Delete Patient Modal --}} {{-- Add Report Modal --}} {{-- Add Report Type Modal --}} {{-- Case Type Modal --}} @if ($errors->has('report_type')) @endif @if(session('error')) @endif @endsection