@php $tenant = \App\Support\Facades\Tenancy::get(); $brandStyle = $tenant->brand_primary_color ? ":root { --color-brand-600: {$tenant->brand_primary_color}; } .dark { --color-brand-600: {$tenant->brand_primary_color}; }" : null; $statusColors = ['active' => 'green', 'inactive' => 'amber', 'graduated' => 'brand', 'transferred' => 'slate', 'expelled' => 'red']; $atLimit = $studentLimit && $studentCount >= $studentLimit; @endphp @if($atLimit) Add Student @else Add Student @endif
@if(request('section_id')) @else @endif
@if($section) @php $offeringsBySubject = $section->courseOfferings->keyBy('subject_id'); @endphp

{{ $section->schoolClass->name }} · Section {{ $section->name }}

Class Teacher: @if($section->classTeacher) {{ $section->classTeacher->fullName() }} @else Not assigned @endif

All Subjects ({{ $sectionSubjects->count() }})

@forelse($sectionSubjects as $index => $subject) @php $offering = $section->courseOfferings->firstWhere('subject_id', $subject->id); $otherClassNames = $subject->courseOfferings ->pluck('section.schoolClass.name') ->filter() ->unique() ->reject(fn ($name) => $name === $section->schoolClass->name) ->values(); @endphp @empty @endforelse
# Subject Code Teacher Actions
{{ $index + 1 }} {{ $subject->name }} {{ $subject->code }} @if($offering && $offering->teacher) {{ $offering->teacher->teacher?->fullName() ?? $offering->teacher->name }} @else @endif
@if($offering && $offering->teacher) @endif
No subjects found.
@if($timetableEntries->isEmpty())

No routine has been created for this section yet.

@else @php $entriesBySlot = $timetableEntries; $slotsUsed = $timetableSlots->filter(fn ($slot) => $entriesBySlot->has($slot->id)); $daysPresent = $slotsUsed->pluck('day_of_week')->unique()->sort()->values(); $timeBands = $slotsUsed->pluck('start_time')->map(fn ($t) => $t->format('H:i'))->unique()->sort()->values(); @endphp
@foreach($daysPresent as $day) @endforeach @foreach($timeBands as $band) @foreach($daysPresent as $day) @php $slot = $slotsUsed->first(fn ($s) => $s->day_of_week === $day && $s->start_time->format('H:i') === $band); @endphp @endforeach @endforeach
Time{{ \App\Models\TimetableSlot::DAYS[$day] }}
{{ \Carbon\Carbon::createFromFormat('H:i', $band)->format('g:i A') }} @if($slot) @foreach($entriesBySlot->get($slot->id, collect()) as $entry)

{{ $entry->courseOffering->subject->name }}

{{ $entry->courseOffering->teacher?->teacher?->fullName() ?? $entry->courseOffering->teacher?->name ?? 'unassigned' }}

@endforeach @else — @endif
@endif
@csrf @method('PUT')
@csrf
@csrf @if($section->schoolClass->department_id) @endif

This will be added to {{ $section->schoolClass->name }} and offered to all its sections.

@csrf @method('PUT')
@endif
@forelse($students as $student) @empty @endforelse
SL Code Name Branch Department Class & Section Session Status
{{ $students->firstItem() + $loop->index }} {{ $student->student_code }}
@if($student->photo_path) {{ $student->fullName() }} @else @endif {{ $student->fullName() }}
{{ $student->branch->name }} {{ $student->department?->name ?? '—' }} {{ $student->section ? $student->section->label() : '—' }} {{ $student->academicSession->name }} {{ ucfirst($student->status) }}
No students found.
{{ $students->links() }}