{{-- resources/views/rooms/status-board.blade.php --}} @extends('layouts.app') @section('title', 'Room Board') @section('page_title', 'Room Status Board') @section('page_subtitle', 'Live overview of all rooms') @section('content') {{-- Summary strip --}}
@php $statusConfig = [ 'available' => ['label' => 'Available', 'bg' => '#d1fae5', 'color' => '#065f46'], 'occupied' => ['label' => 'Occupied', 'bg' => '#fdf1eb', 'color' => '#C4622D'], 'dirty' => ['label' => 'Dirty', 'bg' => '#fef3c7', 'color' => '#92400e'], 'clean' => ['label' => 'Clean', 'bg' => '#dbeafe', 'color' => '#1e40af'], 'maintenance' => ['label' => 'Maintenance', 'bg' => '#f1f5f9', 'color' => '#475569'], 'out_of_order' => ['label' => 'Out of Order', 'bg' => '#fee2e2', 'color' => '#991b1b'], ]; @endphp @foreach($statusConfig as $status => $config) @if(isset($statusCounts[$status]))
{{ $statusCounts[$status] }} {{ $config['label'] }}
@endif @endforeach
List View Add Room
{{-- Board by category --}} @forelse($categories as $category)
{{ $category->name }} {{ $category->rooms->count() }} {{ Str::plural('room', $category->rooms->count()) }}
@if($category->rooms->isEmpty())

No rooms in this category. Add room →

@else
@foreach($category->rooms as $room) @php $sc = $statusConfig[$room->status] ?? $statusConfig['available']; $guest = $occupiedRooms[$room->id] ?? null; @endphp
{{ $room->number }}
@if($room->name)
{{ $room->name }}
@endif @if($guest)
{{ $guest->reservation?->guest?->first_name }} {{ Str::limit($guest->reservation?->guest?->last_name ?? '', 8) }}
out: {{ $guest->reservation?->check_out_date?->format('d M') }}
@else
{{ $sc['label'] }}
@endif {{-- Quick status buttons (shown on hover via JS) --}} @if($room->status !== 'occupied') @endif
@endforeach
@endif
@empty

No rooms configured yet

Start by creating room categories, then add rooms.

Create Room Category
@endforelse @endsection