@extends('layouts.doctor') @section('title', 'My Appointments') @section('content') @forelse($appointments as $a) {{ $a->code }} {{ $a->appointment_date->format('d M Y') }} {{ $a->patient->full_name }} {{ $a->diagnosis?->name ?? $a->reason ?? '—' }} @if($a->consultation) Open @elseif(! in_array($a->status, ['cancelled', 'completed']))
@csrf
@else — @endif @empty No appointments. @endforelse
{{ $appointments->links() }}
@endsection