@php
// Get latest appointment and its physical exam result for this patient
$latestAppointment = $patient
->appointments()
->whereIn('status', ['pemeriksaan', 'in_progress'])
->latest()
->first();
$existingVitalSigns = $latestAppointment ? $latestAppointment->physicalExamResult : null;
@endphp