@extends('backend.app')
@section('title', 'Admin Dashboard')
@section('content')
{{ $totalEvents }}
Total Events
Published
{{ $publishedEvents }}
Completed
{{ $completedEvents }}
Cancelled
{{ $cancelledEvents }}
Last Contact Submission
@if($lastContact)
{{ strtoupper(substr($lastContact->first_name, 0, 1)) }}{{ strtoupper(substr($lastContact->last_name, 0, 1)) }}
{{ $lastContact->first_name }} {{ $lastContact->last_name }}
{{ $lastContact->email }}
Business:
{{ $lastContact->business_name ?? 'N/A' }}
Budget:
{{ $lastContact->budget ?? 'N/A' }}
{{--
Goal:
{{ Str::limit($lastContact->project_goal, 45) }}
--}}
@else
No contact submissions found.
@endif
£{{ number_format($totalRevenue, 2) }}
Total Event Revenue
Total Bookings
{{ $totalBookingsCount }}
Paid Bookings
{{ $paidBookingsCount }}
Pending Bookings
{{ $pendingBookingsCount }}
| Ref / Date |
Customer |
Event |
Amount |
Status |
Method |
Actions |
@forelse($recentBookings as $booking)
|
{{ $booking->booking_reference }}
{{ $booking->booked_at ? $booking->booked_at->format('d M Y, h:i A') : $booking->created_at->format('d M Y, h:i A') }}
|
{{ $booking->customer_name }}
{{ $booking->customer_email }}
|
@if($booking->event)
{{ $booking->event->title }}
@else
N/A
@endif
|
£{{ number_format($booking->total_amount, 2) }}
|
@php
$status = $booking->payment_status?->value ?? 'pending';
$badgeClass = match ($status) {
'paid' => 'badge-light-success',
'failed' => 'badge-light-danger',
'expired' => 'badge-light-info',
'cancelled' => 'badge-light-secondary',
default => 'badge-light-warning',
};
@endphp
{{ ucfirst($status) }}
|
{{ ucfirst($booking->payment_method ?? 'N/A') }}
|
View
|
@empty
|
No bookings found.
|
@endforelse
@push('script')
@endpush
@endsection