@extends('layouts.app') @section('title', 'Holidays') @section('content')
@if(session('success'))
{{ session('success') }}
@endif @if ($errors->any())
{!! implode('
', $errors->all(':message')) !!}
@endif
@foreach($calendar as $week) @foreach($week as $day) @php $class = ''; if ($day->month < $firstDayOfMonth->month) { $class = 'previous-month'; } elseif ($day->month > $lastDayOfMonth->month) { $class = 'next-month'; } else { $class = 'current-month'; } $absents = \App\Http\Controllers\HrController::getAbsents($day->format('Y-m-d')) @endphp @endforeach @endforeach
MON TUE WED THU FRI SAT SUN
{{ $day->day }}
@if($absents->count()!=0)
{{ $absents->count() }} @if($absents->count()==1) Person @else People @endif Absent @endif
@foreach($absents as $absent)
Pic
@endforeach
@endsection @section('js') @endsection