{{ __('Laporan Absensi Bulanan') }}

{{-- PANEL INFORMASI PANDUAN BARU --}}
{{-- Form Filter Bulan dan Tahun --}}
Filter
{{-- Tabel Laporan --}}
@php $daysInMonth = \Carbon\Carbon::createFromDate($tahun, $bulan)->daysInMonth; @endphp @for ($day = 1; $day <= $daysInMonth; $day++) @endfor @foreach ($karyawan as $user) @php $hadirCount = 0; $alphaCount = 0; @endphp @for ($day = 1; $day <= $daysInMonth; $day++) @php $currentDate = \Carbon\Carbon::createFromDate($tahun, $bulan, $day); $attendance = $user->attendances->firstWhere('attendance_date', $currentDate->toDateString()); $isWeekend = $currentDate->isWeekend(); @endphp @endfor @endforeach
Karyawan{{ $day }}H A
{{ $user->name }} @if ($attendance) {{ \Carbon\Carbon::parse($attendance->check_in_time)->format('H:i') }} @php $hadirCount++; @endphp @elseif($isWeekend) L @else A @php $alphaCount++; @endphp @endif {{ $hadirCount }} {{ $alphaCount }}