{{isset(generalSetting()->school_name)?generalSetting()->school_name:'Infix School Management ERP'}}

{{isset(generalSetting()->address)?generalSetting()->address:'Infix School Address'}}

@lang('common.role'): {{ $role->name}}

@lang('hr.month'): {{ date("F", strtotime('00-'.$month.'-01')) }}

@lang('common.year'): {{ $year }}

@lang('hr.staff_attendance_report')

@for($i = 1; $i<=$days; $i++) @endfor @foreach($attendances as $values) @php $total_attendance = 0; @endphp @php $count_absent = 0; @endphp @for($i = 1; $i<=$days; $i++) @php $date=$year.'-'.$month.'-'.$i; @endphp @endfor @endforeach
@lang('hr.staff_name') @lang('hr.staff_no') @lang('hr.P') @lang('hr.L') @lang('hr.A') @lang('hr.H') @lang('hr.F') % {{$i}}
@php $student = 0; @endphp @foreach($values as $value) @php $student++; @endphp @if($student == 1) {{$value->staffInfo->full_name}} @endif @endforeach @php $student = 0; @endphp @foreach($values as $value) @php $student++; @endphp @if($student == 1) {{$value->staffInfo->staff_no}} @endif @endforeach @php $p = 0; @endphp @foreach($values as $value) @if($value->attendence_type == 'P') @php $p++; $total_attendance++; @endphp @endif @endforeach {{$p}} @php $l = 0; @endphp @foreach($values as $value) @if($value->attendence_type == 'L') @php $l++; $total_attendance++; @endphp @endif @endforeach {{$l}} @php $a = 0; @endphp @foreach($values as $value) @if($value->attendence_type == 'A') @php $a++; $count_absent++; $total_attendance++; @endphp @endif @endforeach {{$a}} @php $h = 0; @endphp @foreach($values as $value) @if($value->attendence_type == 'H') @php $h++; $total_attendance++; @endphp @endif @endforeach {{$h}} @php $f = 0; @endphp @foreach($values as $value) @if($value->attendence_type == 'F') @php $f++; $total_attendance++; @endphp @endif @endforeach {{$f}} @php $total_present = $total_attendance - $count_absent; if($count_absent == 0){ echo '100%'; }else{ $percentage = $total_present / $total_attendance * 100; echo number_format((float)$percentage, 2, '.', '').'%'; } @endphp @foreach($values as $value) @if(strtotime($value->attendence_date) == strtotime($date)) {{$value->attendence_type}} @endif @endforeach