Files
ladill-frontdesk/resources/views/frontdesk/visits/calendar.blade.php
T
isaaccladandCursor 9e2d79936c
Deploy Ladill Frontdesk / deploy (push) Failing after 35s
Test / test (push) Failing after 2m45s
Initial Ladill Frontdesk release with deploy pipeline.
Visitor management app with SSO, kiosk, badges, reports, and Gitea CI deploy to frontdesk.ladill.com.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-27 20:37:15 +00:00

40 lines
2.5 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<x-app-layout title="Visit calendar">
<div class="flex items-center justify-between">
<div>
<h1 class="text-xl font-semibold text-slate-900">Visit calendar</h1>
<p class="text-sm text-slate-500">{{ $start->format('M j') }} {{ $end->format('M j, Y') }}</p>
</div>
<div class="flex gap-2">
<a href="{{ route('frontdesk.visits.calendar', ['start' => $start->copy()->subWeek()->toDateString()]) }}"
class="rounded-lg border border-slate-200 px-3 py-2 text-sm text-slate-700 hover:bg-slate-50">Previous</a>
<a href="{{ route('frontdesk.visits.calendar', ['start' => $start->copy()->addWeek()->toDateString()]) }}"
class="rounded-lg border border-slate-200 px-3 py-2 text-sm text-slate-700 hover:bg-slate-50">Next</a>
<a href="{{ route('frontdesk.visits.schedule') }}" class="rounded-lg bg-teal-600 px-4 py-2 text-sm font-medium text-white hover:bg-teal-700">Schedule</a>
</div>
</div>
<div class="mt-6 grid gap-4 lg:grid-cols-7">
@for ($day = $start->copy(); $day->lte($end); $day->addDay())
@php $dateKey = $day->toDateString(); @endphp
<section class="rounded-2xl border border-slate-200 bg-white">
<div class="border-b border-slate-100 px-3 py-2">
<p class="text-xs font-semibold uppercase text-slate-500">{{ $day->format('D') }}</p>
<p class="text-sm font-medium text-slate-900">{{ $day->format('M j') }}</p>
</div>
<div class="space-y-1 p-2">
@forelse ($visits->get($dateKey, collect()) as $visit)
<a href="{{ route('frontdesk.visits.show', $visit) }}"
class="block rounded-lg px-2 py-1.5 text-xs hover:bg-slate-50 @if($visit->status === 'overdue') border border-amber-200 bg-amber-50 @endif">
<p class="font-medium text-slate-800">{{ $visit->scheduled_at->format('g:i A') }}</p>
<p class="truncate text-slate-600">{{ $visit->visitor->full_name }}</p>
<p class="capitalize text-slate-400">{{ str_replace('_', ' ', $visit->status) }}</p>
</a>
@empty
<p class="px-2 py-4 text-center text-xs text-slate-400">No visits</p>
@endforelse
</div>
</section>
@endfor
</div>
</x-app-layout>