{{-- Header & Breadcrumb --}}
{{-- Filter Section --}}
{{-- Report Cards per Employee --}}
@if(isset($reportData) && $reportData->isNotEmpty())
@foreach($reportData as $data)
@php
$emp = $data['employee'];
$primaryId = (!empty($emp->primary_id) && $emp->primary_id !== '0' && $emp->primary_id !== 0) ? $emp->primary_id : '-';
$secondaryId = (!empty($emp->e_id) && $emp->e_id !== '0' && $emp->e_id !== 0) ? $emp->e_id : '-';
$post = $emp->postDetails->name ?? ($emp->post ?? '-');
@endphp
Staff Attendance Details Report
{{-- School Header for Print --}}
{{-- Employee Header Info for Web View --}}
@endforeach
@elseif(request()->has('from_date'))
{{ $schoolProfile->school_name ?? config('app.name', 'Smart Shikkha') }}
@if(!empty($schoolProfile->address)){{ $schoolProfile->address }}
@endifStaff Attendance Details Report | Period: {{ $fromDate->format('d M, Y') }} to {{ $toDate->format('d M, Y') }}
{{ $emp->name }}
Primary ID: {{ $primaryId }} | Secondary ID: {{ $secondaryId }} | Post: {{ $post }}
Period: {{ $fromDate->format('d M, Y') }} - {{ $toDate->format('d M, Y') }}
{{-- Employee Information Table (Black text for print & web) --}}
{{-- Summary Statistics Table --}}
{{-- Daily Records Table --}}
| Employee Name: {{ $emp->name }} | Primary ID: {{ $primaryId }} | Secondary ID: {{ $secondaryId }} | Designation: {{ $post }} |
| Present Days | Absent Days | Leave Days | Off / Holiday | Total Worked | Total Late |
|---|---|---|---|---|---|
| {{ $data['present_days'] }} | {{ $data['absent_days'] }} | {{ $data['leave_days'] }} | {{ $data['off_days'] + $data['holiday_days'] }} | {{ $data['total_worked_hours'] }} | {{ $data['total_late_minutes'] }}m |
| Date | Day | Morning Shift | Day Shift | Total Hours | Status | ||||
|---|---|---|---|---|---|---|---|---|---|
| In | Out | Late | In | Out | Late | ||||
| {{ \Carbon\Carbon::parse($record['date'])->format('d-m-Y') }} | {{ $record['day_name'] }} | {{-- MORNING --}}{{ $record['morning_in'] ? \Carbon\Carbon::parse($record['morning_in'])->format('h:i A') : '-' }} | {{ $record['morning_out'] ? \Carbon\Carbon::parse($record['morning_out'])->format('h:i A') : '-' }} | @if(!empty($record['morning_late'])) {{ $record['morning_late'] }} @else - @endif | {{-- DAY --}}{{ $record['day_in'] ? \Carbon\Carbon::parse($record['day_in'])->format('h:i A') : '-' }} | {{ $record['day_out'] ? \Carbon\Carbon::parse($record['day_out'])->format('h:i A') : '-' }} | @if(!empty($record['day_late'])) {{ $record['day_late'] }} @else - @endif | {{ $record['worked_hours'] }} | {{ strtoupper($record['status']) }} |
No attendance data found for the selected period.
@endif