Salad Order Management
{{ $tabLabel }} • {{ $totalCount }} row{{ $totalCount === 1 ? '' : 's' }}
SALAD ORDER REPORT
Salad Date: {{ $date->format('d M Y') }} ({{ $date->format('l') }})
Generated {{ $generatedAt->format('d M Y, h:i A') }}
@php // Compact address: drop repeated parts ("Coimbatore, ..., Coimbatore"), // the country, and cap the length so one record never runs past ~3 lines. $compactAddress = function (?string $address): string { if (!$address) { return '-'; } $parts = collect(preg_split('/\s*,\s*/', $address)) ->map(fn ($p) => trim($p)) ->map(fn ($p) => trim(preg_replace('/\bTamil Nadu\b\s*-?\s*/i', '', $p), " -")) ->filter(fn ($p) => $p !== '' && !in_array(mb_strtolower($p), ['india'], true)) ->unique(fn ($p) => mb_strtolower($p)) ->values(); $text = $parts->implode(', '); return mb_strlen($text) > 150 ? rtrim(mb_substr($text, 0, 148)) . '…' : $text; }; @endphp @forelse ($groups as $group) @foreach ($group['rows'] as $r) @endforeach @empty @endforelse
Production No Type Salad Name Qty Customer Phone Address Order Source Payment Method Delivery Person Delivery Slot
{{ $group['label'] }} ({{ $group['rows']->count() }})
{{ $r['production_no'] }} {{ $r['salad_type_label'] }} {{ $r['salad_name'] }} {{ $r['quantity'] }} {{ $r['customer_name'] }} {{ $r['customer_phone'] ?: '-' }} {{ $compactAddress($r['customer_address']) }} {{ $r['order_source'] }} {{ $r['payment_method'] ?: '-' }} {{ $r['delivery_person'] ?: '-' }} {{ $r['delivery_slot'] ?: '-' }}
No records found for the selected filters.