@php $addAttendancePermission = user()->permission('add_attendance'); @endphp
@lang('app.employee') @for ($i = 1; $i <= $daysInMonth; $i++) {{ $i }}
{{ $weekMap[\Carbon\Carbon::parse(\Carbon\Carbon::parse($i . '-' . $month . '-' . $year))->dayOfWeek] }} @endfor @lang('app.total')
@foreach ($employeeAttendence as $key => $attendance) @php $totalPresent = 0; $userId = explode('#', $key); $userId = $userId[0]; @endphp {!! end($attendance) !!} @foreach ($attendance as $key2 => $day) @if ($key2 + 1 <= count($attendance)) @php $attendanceDate = \Carbon\Carbon::parse($year.'-'.$month.'-'.$key2); @endphp @if ($day == 'Leave') @elseif ($day == 'Day Off') @elseif ($day == 'Half Day') @if ($attendanceDate->isFuture()) @else @endif @elseif ($day == 'Absent') @elseif ($day == 'Holiday') @else @if ($day != '-') @php $totalPresent = $totalPresent + 1; @endphp @endif {!! $day !!} @endif @endif @endforeach {!! $totalPresent . ' / ' . (count($attendance) - 1) . '' !!} @endforeach