@extends('admin.admin_dashboard') @section('customcss') @endsection @section('admin')
@foreach($report as $roomData) @php $matrix = $roomData['matrix'] ?? []; $columnCount = count($matrix[0] ?? []); @endphp
Room: {{ $roomData['room']['name'] ?? '' }} @if(!empty($roomData['room']['code'])) ({{ $roomData['room']['code'] }}) @endif
@foreach($roomData['data'] as $class)
Class: {{ $class['class'] }} @foreach($class['sections'] as $section) | Section: {{ $section['section'] }} @foreach($section['groups'] as $group) | Group: {{ $group['group'] }} @endforeach @endforeach
@endforeach
@for($i = 1; $i <= $columnCount; $i++) @endfor @foreach($matrix as $row) @foreach($row as $cell) @endforeach @endforeach
Column {{ chr(64 + $i) }}
@if($cell['occupied'] && $cell['assignment']) @php $reg = $cell['assignment']->registration; $studentName = $reg?->student?->student_name_english ?? $reg?->student?->student_name_bangla ?? 'N/A'; $className = $reg?->class?->name ?? $reg?->class_model?->name ?? ''; $sectionName = $reg?->section?->name ?? ''; $classRoll = $reg?->class_roll ?? ''; @endphp
{{ $studentName }}
@if($className) {{ $className }} @endif @if($sectionName) ({{ $sectionName }}) @endif @if($classRoll) Roll: {{ $classRoll }} @endif
@else - @endif
@endforeach
@endsection @section('customjs') @endsection