Files
ladill-events/resources/views/events/badges-hub.blade.php
T
isaaccladandCursor 5e00f319a5
Deploy Ladill Events / deploy (push) Successful in 35s
Split attendees and badge printing; add a 3-step event create flow.
Give each area its own sidebar entry and hub pages, and walk new events through details, QR design, then review before publish.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-07 12:27:42 +00:00

55 lines
3.9 KiB
PHP

<x-user-layout>
<x-slot name="title">Badge printing</x-slot>
<div class="mx-auto max-w-5xl space-y-6">
<div>
<h1 class="text-2xl font-bold text-slate-900">Badge printing</h1>
<p class="mt-1 text-sm text-slate-500">Select attendees and print badges or download ZPL for label printers.</p>
</div>
<form method="GET" class="flex items-center gap-2">
<input type="text" name="search" value="{{ $search }}" placeholder="Search events…"
class="w-full max-w-sm rounded-xl border border-slate-200 px-3.5 py-2 text-sm focus:border-indigo-400 focus:outline-none focus:ring-1 focus:ring-indigo-400/30">
<button type="submit" class="rounded-xl border border-slate-200 px-4 py-2 text-sm font-semibold text-slate-600 hover:bg-slate-50 transition">Search</button>
</form>
<div class="overflow-hidden rounded-2xl border border-slate-200 bg-white">
@if($events->isEmpty())
<div class="px-6 py-14 text-center">
<p class="text-sm text-slate-500">{{ $search ? 'No events match your search.' : 'No events yet.' }}</p>
@unless($search)
<a href="{{ route('events.create') }}" class="mt-4 inline-flex items-center gap-2 rounded-xl bg-indigo-600 px-4 py-2.5 text-sm font-semibold text-white hover:bg-indigo-700 transition">
Create your first event
</a>
@endunless
</div>
@else
<div class="divide-y divide-slate-100">
@foreach($events as $event)
@php
$content = $event->content();
$isContribution = ($content['mode'] ?? 'ticketing') === 'contributions';
@endphp
@if($isContribution)
@continue
@endif
<a href="{{ route('events.badge-printing', $event) }}" class="flex items-center gap-4 px-6 py-4 transition hover:bg-slate-50">
<div class="flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-violet-50 text-violet-600">
<svg class="h-5 w-5" fill="none" stroke="currentColor" stroke-width="1.8" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="M9 12h3.75M9 15h3.75M9 18h3.75m3 .75H18a2.25 2.25 0 0 0 2.25-2.25V6.108c0-1.135-.845-2.098-1.976-2.192a48.424 48.424 0 0 0-1.123-.08m-5.801 0c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75 2.25 2.25 0 0 0-.1-.664m-5.8 0A2.251 2.251 0 0 1 13.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m0 0H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V9.375c0-.621-.504-1.125-1.125-1.125H8.25Z"/></svg>
</div>
<div class="min-w-0 flex-1">
<p class="truncate text-sm font-semibold text-slate-900">{{ $content['name'] ?? $event->label }}</p>
<p class="truncate text-xs text-slate-500">Badge size: {{ strtoupper($content['badge_size'] ?? '4x3') }}</p>
</div>
<div class="hidden text-right text-xs text-slate-500 sm:block">
<p class="font-semibold text-slate-900">{{ number_format($event->printable_count) }} printable</p>
</div>
<svg class="h-4 w-4 shrink-0 text-slate-300" fill="none" stroke="currentColor" stroke-width="2" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" d="m8.25 4.5 7.5 7.5-7.5 7.5"/></svg>
</a>
@endforeach
</div>
@endif
</div>
</div>
</x-user-layout>