@php($upcoming = $appointments->filter(fn ($appointment) => $appointment->startAt->isFuture() && ! in_array($appointment->status->value, ['CANCELLED', 'COMPLETED']))->values()) @php($past = $appointments->reject(fn ($appointment) => $upcoming->contains('id', $appointment->id))->values())

Appointments

@forelse ($upcoming as $appointment)
{{ str_replace('_', ' ', strtolower($appointment->status->value)) }}

{{ $appointment->startAt->setTimezone($business->timezone)->format('D, M j') }}

{{ $appointment->startAt->setTimezone($business->timezone)->format('g:i A') }}

{{ $appointment->services->pluck('service.name')->join(', ') }}

with {{ $appointment->staff->user?->name ?: 'your barber' }}

Details@if (in_array($appointment->status->value, ['PENDING', 'CONFIRMED']))
@csrf
@endif
@empty

No upcoming appointments

Book your next visit in a few taps.

Book now
@endforelse