@extends('layouts.app') @section('content')
You have not made any Dewan bookings yet.
| Dewan | Event | Date | Time | Total (RM) | Status | Actions |
|---|---|---|---|---|---|---|
| {{ $booking->dewan->name ?? '—' }} | {{ $booking->event_name }} | {{ \Carbon\Carbon::parse($booking->date)->format('d M Y') }} | @if($booking->start_time && $booking->end_time) {{ \Carbon\Carbon::parse($booking->start_time)->format('h:i A') }} – {{ \Carbon\Carbon::parse($booking->end_time)->format('h:i A') }} @else Full Day @endif | RM{{ number_format($booking->total_amount, 2) }} | @php $statusStyles = [ 'pending' => 'bg-yellow-100 text-yellow-800', 'need_payment' => 'bg-blue-100 text-blue-800', 'awaiting_verification' => 'bg-gray-100 text-gray-800', 'booked' => 'bg-green-100 text-green-800', 'rejected' => 'bg-red-100 text-red-800', 'cancelled' => 'bg-red-100 text-red-800', ]; @endphp {{ ucfirst(str_replace('_', ' ', $booking->status)) }} | @php $buttonStyles = [ 'pay' => 'bg-yellow-100 text-yellow-800 hover:bg-yellow-200', 'cancel' => 'bg-red-100 text-red-800 hover:bg-red-200', 'view' => 'bg-indigo-100 text-indigo-800 hover:bg-indigo-200', 'view_gray' => 'bg-gray-100 text-gray-700 hover:bg-gray-200', 'print' => 'bg-gray-100 text-gray-700 hover:bg-gray-200', ]; $pillClass = 'inline-block px-3 py-1 rounded-full text-xs font-semibold transition'; @endphp @if($booking->status === 'pending') @if($booking->deposit_receipt_path) View Deposit @endif @elseif($booking->status === 'need_payment') Pay Now @elseif($booking->status === 'awaiting_verification') View Receipt @elseif($booking->status === 'booked') Print Receipt @elseif($booking->status === 'rejected') Redo Payment @elseif($booking->status === 'cancelled') Cancelled @endif @php $cancellableStatuses = ['pending', 'need_payment', 'awaiting_verification','booked']; @endphp @if(in_array($booking->status, $cancellableStatuses)) @endif |