Monthly Attendance Details Report

Date Range: {{ $rangeText }} @if(!empty($teamName)) | Team: {{ $teamName }} @endif
@php $chunks = $users->chunk(8); // employees per page @endphp @foreach($chunks as $chunk)
@foreach($days as $d) @endforeach @foreach($chunk as $u) @foreach($days as $d) @php $c = $attendanceMap[$u->user_id][$d->toDateString()] ?? []; @endphp @endforeach @endforeach
Employee {{ $d->format('d M') }}
{{ $d->format('D') }}
P A H L T
{{ $u->name }} {{ $u->lastName }}
{{ $u->team }}
@if(!empty($c['all_punches'])) @foreach($c['all_punches'] as $p)
{{ $p }}
@endforeach @else
@endif @if(!empty($c['status']))
{{ $c['status'] }}
@endif @if(!empty($c['work_display']))
{{ $c['work_display'] }} hrs @if(!empty($c['break_display'])) {{ $c['break_display'] }} hrs @endif
@endif
{{ $totals[$u->user_id]['P'] ?? 0 }} {{ $totals[$u->user_id]['A'] ?? 0 }} {{ $totals[$u->user_id]['H'] ?? 0 }} {{ $totals[$u->user_id]['L'] ?? 0 }} {{ $totals[$u->user_id]['T'] ?? count($days) }}
@if(!$loop->last)
@endif @endforeach