{{-- A. Corporate Stats Bar --}}
Total Batches

{{ $stats['total'] }}

Open Slots

{{ $stats['active'] }}

Full / Closed

{{ $stats['full'] }}

Avg Occupancy

{{ round($stats['occupancy']) }}%

{{-- B. Filter & Action Toolbar --}}
{{-- Left: Specific Filters Requested --}}
{{-- Right: Search & Dropdown --}}
{{-- C. Data Table --}}
@forelse($batches as $batch) @php $occ = $batch->percent_full; $barColor = $occ >= 90 ? 'bg-danger' : ($occ >= 60 ? 'bg-warning' : 'bg-success'); $isClosed = $batch->status === 'closed'; @endphp {{-- 1. Details --}} {{-- 2. Schedule --}} {{-- 3. Instructor --}} {{-- 4. Occupancy --}} {{-- 5. Status --}} {{-- 6. Actions --}} @empty @endforelse
Batch Details Schedule Instructor Occupancy Status Actions
{{ \Carbon\Carbon::parse($batch->start_date)->format('d') }} {{ \Carbon\Carbon::parse($batch->start_date)->format('M') }}
{{ $batch->batch_name }}
{{ $batch->batch_code }} {{-- Course Name + Deleted Check --}} @if ($batch->course) {{ Str::limit($batch->course->name, 20) }} @if ($batch->course->trashed()) DELETED @endif @else Course Removed @endif
{{ \Carbon\Carbon::parse($batch->start_time)->format('h:i A') }} - {{ \Carbon\Carbon::parse($batch->end_time)->format('h:i A') }} {{ \Carbon\Carbon::parse($batch->start_date)->diffInDays(\Carbon\Carbon::parse($batch->end_date)) + 1 }} Days Duration
@if ($batch->instructor)
{{ substr($batch->instructor->name, 0, 1) }}
{{ $batch->instructor->name }}
@else Unassigned @endif
{{ $batch->booked_seats }} / {{ $batch->total_seats }} {{ $occ }}%
@if ($batch->status === 'open') Open @elseif($batch->status === 'full') Full @else Closed @endif
No Batches Found

Try adjusting your filters or search.

{{-- Footer --}}
{{-- ========================== --}} {{-- BATCH DETAIL MODAL --}} {{-- ========================== --}}