@extends('layouts.business') @section('title', 'Booking History') @section('breadcrumb_title', 'Vehicle Bookings') @section('breadcrumb_title_route', route('business.vehicle_bookings.index')) @section('breadcrumb_sub_title', 'History') @section('page_title', 'Booking Status & Payment History') @section('content')
Booking Status History ({{ $statusLogs->count() }})
@if($statusLogs && $statusLogs->count() > 0)
@foreach($statusLogs as $log) @php $logStatusValue = (int)$log->status; $logStatusLabel = ''; $logStatusClass = ''; switch($logStatusValue) { case 0: $logStatusLabel = 'Pending'; $logStatusClass = 'warning'; break; case 1: $logStatusLabel = 'Confirmed'; $logStatusClass = 'success'; break; case 2: $logStatusLabel = 'Handover to Client'; $logStatusClass = 'info'; break; case 3: $logStatusLabel = 'Return by Client'; $logStatusClass = 'primary'; break; case 4: $logStatusLabel = 'Rejected'; $logStatusClass = 'danger'; break; default: $logStatusLabel = 'Unknown'; $logStatusClass = 'secondary'; break; } @endphp @endforeach
Status Changed By Date
{{ $logStatusLabel }}
{{ $log->creator->name ?? 'System' }}

{{ $log->creator->email ?? '-' }}

{{ $log->created_at->format('M d, Y') }}

@else

No booking status history found.

@endif
Payment Status History ({{ $paymentLogs->count() }})
@if($paymentLogs && $paymentLogs->count() > 0)
@foreach($paymentLogs as $log) @endforeach
Payment Status Changed By Date
@if($log->payment_status == 1) Paid @else Non Paid @endif
{{ $log->creator->name ?? 'System' }}

{{ $log->creator->email ?? '-' }}

{{ $log->created_at->format('M d, Y') }}

@else

No payment status history found.

@endif
@endsection