Appointments

View and manage your patient appointments

Today's Schedule

{{ $appointments->filter(function($apt) { return \Carbon\Carbon::parse($apt->date)->isToday(); })->count() }}

Appointments

@if (session()->has('success'))
{{ session('success') }}
@endif @if (session()->has('error'))
{{ session('error') }}
@endif
@if($appointments->isEmpty())

No appointments found

@if($activeTab === 'upcoming') You don't have any upcoming appointments. @elseif($activeTab === 'completed') No completed appointments found. @elseif($activeTab === 'cancelled') No cancelled appointments found. @else No appointments match your current filters. @endif

@else
@foreach($appointments as $appointment)
@php $avatarUrl = null; // First check ExpectantMother avatar_url if ($appointment->mother->expectantMother && $appointment->mother->expectantMother->avatar_url) { $avatarUrl = asset('storage/' . $appointment->mother->expectantMother->avatar_url); } // Fallback to User profile_picture elseif ($appointment->mother->profile_picture) { $avatarUrl = asset('storage/' . $appointment->mother->profile_picture); } // Final fallback to UI Avatars else { $avatarUrl = 'https://ui-avatars.com/api/?name=' . urlencode($appointment->mother->name) . '&background=FB97AE&color=fff&size=200'; } @endphp {{ $appointment->mother->name }}

{{ $appointment->mother->name }}

Phone: {{ $appointment->mother->phone ?? $appointment->mother->expectantMother->phone_number ?? 'Not provided' }}

{{ $appointment->date->format('M d, Y') }} {{ $appointment->slot_label }} @if($appointment->clinic) {{ $appointment->clinic->name }} @endif
{{ ucfirst(str_replace('_', ' ', $appointment->status)) }}
@if($appointment->notes)

{{ $appointment->notes }}

@endif
@if($appointment->status === 'pending' || $appointment->status === 'approved')
@if($appointment->status === 'pending') @endif @if($appointment->status === 'approved') @endif
@endif
@endforeach
{{ $appointments->links() }}
@endif
@if($showViewModal && $selectedAppointment) @endif @if($showApprovalModal && $selectedAppointment) @endif