@extends('admin.layout.master') @section('content')

Monthly Roster Duties

@if(count($attendances) >0)
@include('payroll.includes.printAndExcel')
@endif
@if(count($attendances) >0) {{-- @dd($attendances) --}}
@php $i=1; @endphp @foreach (collect($attendances)->chunk(40) as $chunk_data)
@include('payroll.report_header',['store_address'=>true,'store_email'=>true,'contact_info'=>true,'text_align'=>"text-center"])
Roster Duties ({{ date("d-m-Y", strtotime($date_from)) }} - {{date("d-m-Y", strtotime($date_to))}})
@if(request('department_id')) {{ department(request('department_id'))->name }} @endif
Total Days : {{$total_days}} Fridays : {{$total_fridays}} Holidays : {{$total_holidays}} Working Days : {{$total_working_days}}
{{-- --}} @foreach ($chunk_data as $data) {{-- @dd($data['attendances']->whereNotIn('status',['Weekend'])); --}} @php $total_present = $data['attendances']->where('status','Present')->count(); $total_leave =$data['attendances']->where('status','Leave')->count(); $total = $total_present + $total_leave; @endphp {{-- --}} @endforeach
#SL Code Name Designation No Of Rosters Present Leaves TotalSht/Exs.
{{$i++}} {{$data['employee_info']->emp_code}} {{$data['employee_info']->emp_name}} {{$data['employee_info']->fetch_designation ? $data['employee_info']->fetch_designation->name : null}} {{$data['attendances']->whereNotIn('status',['Weekend','Holiday','Absent'])->count()}} {{$total_present}} {{$total_leave}} {{$total}}
@endforeach
@else @if(request()->get('search') !=null)

No Data Found

@endif @endif @endsection @section('script') @endsection