@extends('layouts.admin') @section('title', 'Appointments') @section('page', 'appointments') @section('content') @php $statusClass = fn($s) => match($s) { 'confirmed','allocated' => 'confirmed', 'in_consultation' => 'consulting', 'completed' => 'completed', default => 'cancelled', }; @endphp

Appointments

View and manage all clinic appointments in one place.

Total Appointments
{{ $stats['total'] }}
All scheduled appointments
Confirmed
{{ $stats['confirmed'] }}
Ready for consultation
In Consultation
{{ $stats['consulting'] }}
Currently with doctor
Completed
{{ $stats['completed'] }}
Completed visits

All Appointments

Showing {{ $appointments->total() }} scheduled appointment(s)

{{ $appointments->total() }} Appointments
@forelse($appointments as $a) @empty @endforelse
AppointmentPatientDoctorProcedureDate & TimeStatusAction
{{ $a->code }}
{{ strtoupper(\Illuminate\Support\Str::of($a->patient->full_name)->explode(' ')->map(fn($x)=>$x[0]??'')->join('')) }}
{{ $a->patient->full_name }}{{ $a->patient->phone }}
{{ $a->doctor?->name ?? 'Unassigned' }}
{{ $a->diagnosis?->name ?? $a->reason ?? '—' }}
{{ $a->appointment_date->format('Y-m-d') }}{{ $a->appointment_time ? \Illuminate\Support\Carbon::parse($a->appointment_time)->format('h:i A') : '' }} {{ strtoupper(str_replace('_',' ',$a->status)) }} View @if($a->status === 'allocated')
@csrf @method('PUT')
@endif @unless(in_array($a->status, ['cancelled','completed']))
@csrf @method('PUT')
@endunless
No appointments found

Try changing your search or filters.

Showing {{ $appointments->firstItem() ?? 0 }}–{{ $appointments->lastItem() ?? 0 }} of {{ $appointments->total() }}
@for($i=1;$i<=$appointments->lastPage();$i++){{ $i }}@endfor
@endsection