@extends('layouts.backend') @section('title', 'Leave Reports') @section('content')

{{ __('Leave Reports') }}

{{ __('Export Excel (CSV)') }}
@include('partials.flash')
{{ __('Reset') }}
@forelse($applications as $application) @php($empName = trim(($application->employee?->first_name ?? '').' '.($application->employee?->last_name ?? ''))) @empty @endforelse
{{ __('Applied At') }} {{ __('Employee') }} {{ __('Employee Code') }} {{ __('Salary Grade') }} {{ __('Category') }} {{ __('Date Range') }} {{ __('Days') }} {{ __('Status') }} {{ __('Approver') }}
{{ $application->created_at?->format('Y-m-d H:i') }} {{ $empName !== '' ? $empName : '-' }} {{ $application->employee?->employee_code ?? '-' }} {{ $application->employee?->salaryGrade?->grade_name ?? '-' }} {{ $application->leaveCategory?->name ?? '-' }} {{ $application->start_date }} to {{ $application->end_date }} {{ number_format((float) $application->total_days, 2) }} {{ __(ucfirst($application->status)) }} {{ $application->approver?->name ?? '-' }}
{{ __('No leave records found for selected filters.') }}
{{ $applications->links('pagination::bootstrap-5') }}
@endsection @push('scripts') @endpush