@extends('layouts.app') @section('title', 'Customers') @section('content')
Manage all customer records and transactions
Total Customers
VIP Customers
Registered
Total Revenue
| Customer | Contact | Type | Channels | Orders | Bookings | Total Spent | Last Purchase | Actions |
|---|---|---|---|---|---|---|---|---|
|
{{ $customer->name }}
{{ $customer->email }} |
@if($customer->phone) {{ $customer->phone }} @else - @endif | {{ ucfirst($customer->customer_type) }} | @if(!empty($customer->channels)) @foreach($customer->channels as $channel) @php $channelBadge = match($channel) { 'ecommerce' => ['class' => 'primary', 'icon' => 'cart', 'label' => 'E-commerce'], 'booking' => ['class' => 'success', 'icon' => 'calendar-check', 'label' => 'Booking'], 'payment_form' => ['class' => 'info', 'icon' => 'credit-card', 'label' => 'Payment'], default => ['class' => 'secondary', 'icon' => 'question', 'label' => ucfirst($channel)] }; @endphp {{ $channelBadge['label'] }} @endforeach @else - @endif | {{ $customer->total_orders }} | {{ $customer->total_bookings }} | RM {{ number_format($customer->total_spent, 2) }} | @if($customer->last_purchase_at) {{ $customer->last_purchase_at->format('M d, Y') }} @else Never @endif | View |
No customers found
@if(request('search') || request('customer_type') || request('channel')) Clear Filters @endif