{{ __('translations.Waiting') }}

    @foreach ($bookings->where('status', 'pending')->sortBy(fn($booking) => $booking->is_arrived == 2 ? 1 : 0) as $booking)
  • @if ($booking->ticket) {{ $booking->ticket }} @else @endif
    {{ __('translations.Patient') }} : {{ @$booking->getUser->first_name . ' ' . @$booking->getUser->last_name }}

    {{ __('translations.Doctor') }}: {{ @$booking->Doctor->name }}

    @if ($booking->status != 'cancel')

    {{ __('translations.Arrival Time') }}: {{ $booking->arrival_time }}

    @endif @if (($booking->is_arrived == 1 || $booking->is_arrived == 2) && $booking->arrived_at)

    {{ __('translations.Arrived At') }}: {{ $booking->arrived_at }}

    @endif
    {{ $booking->start_time . ' - ' . $booking->end_time }} {{ $booking->date }} @if ($booking->status != 'cancel') @if ($booking->is_arrived == '0') {{ __('translations.Waiting') }} @elseif($booking->is_arrived == '1' && $booking->late_arrived == 0) {{ __('translations.Arrived') }} @elseif($booking->is_arrived == '1' && $booking->late_arrived == 1) {{ __('translations.Late Arrived') }} @elseif($booking->is_arrived == '2') {{ __('translations.Late') }} @elseif($booking->is_arrived == '3') {{ __('translations.Not Arrived') }} @elseif($booking->is_arrived == '4') {{ __('translations.On the way') }} @endif @endif
  • @endforeach

{{ __('translations.In Progress') }}

    @foreach ($bookings->where('status', 'in_progress') as $booking)
  • @if ($booking->ticket) {{ $booking->ticket }} @else @endif
    {{ __('translations.Patient') }} : {{ @$booking->getUser->first_name . ' ' . @$booking->getUser->last_name }}

    {{ __('translations.Doctor') }}: {{ @$booking->Doctor->name }}

    {{ $booking->start_time . ' - ' . $booking->end_time }} {{ $booking->date }} {{-- --}}
  • @endforeach

{{ __('translations.Absent') }}

    @foreach ($bookings->whereIn('status', ['absent','cancel']) as $booking)
  • @if ($booking->ticket) {{ $booking->ticket }} @else @endif
    {{ __('translations.Patient') }} : {{ @$booking->getUser->first_name . ' ' . @$booking->getUser->last_name }}

    {{ __('translations.Doctor') }}: {{ @$booking->Doctor->name }}

    {{ $booking->start_time . ' - ' . $booking->end_time }} {{ $booking->date }} {{ucfirst($booking->status == 'cancel' ? 'cancelled' : $booking->status)}}
  • @endforeach

{{ __('translations.Completed') }}

    @foreach ($bookings->where('status', 'completed') as $booking)
  • @if ($booking->ticket) {{ $booking->ticket }} @else @endif
    {{ __('translations.Patient') }} : {{ @$booking->getUser->first_name . ' ' . @$booking->getUser->last_name }}

    {{ __('translations.Doctor') }}: {{ @$booking->Doctor->name }}

    {{ $booking->start_time . ' - ' . $booking->end_time }} {{ $booking->date }}
    {{--
    --}} {{-- {{ $booking->start_time . ' - ' . $booking->end_time }} --}} {{-- {{ $booking->date }} --}} {{--
    --}}
  • @endforeach