Cancellation Details
{{ $ref }}
{{ $patientName }}
Student ID: {{ $upsiId }}
“{{ $cancelReason }}”
Policy Check
Request made {{ $hoursBefore }} hours before. Policy requires admin review.
@php $patientName = $patient['full_name'] ?? 'Unknown Patient'; $initial = strtoupper(substr($patientName, 0, 1)); $upsiId = $patient['upsi_id'] ?? '-'; $ref = $appointment['reference_no'] ?? 'PKU-' . substr($appointment['id'] ?? '', 0, 8); $treatment = $appointment['reason'] ?? 'Dental Appointment'; $date = !empty($appointment['appointment_date']) ? date('l, d M Y', strtotime($appointment['appointment_date'])) : '-'; $time = !empty($appointment['appointment_time']) ? date('g:i A', strtotime($appointment['appointment_time'])) : '-'; $roomName = $room['room_name'] ?? '-'; $cancelReason = $appointment['cancellation_reason'] ?? 'No reason provided.'; $appointmentDateTime = strtotime(($appointment['appointment_date'] ?? '') . ' ' . ($appointment['appointment_time'] ?? '')); $hoursBefore = $appointmentDateTime ? round(($appointmentDateTime - time()) / 3600) : 0; $policyOk = $hoursBefore >= 48; @endphp
Student ID: {{ $upsiId }}
“{{ $cancelReason }}”
Request made {{ $hoursBefore }} hours before. Policy requires admin review.