@section('page-title', __('Dashboard')) @php $baseCurrency = \App\Models\Currency::base(); $currencySymbol = $baseCurrency ? ($baseCurrency->to_currency ?? $baseCurrency->code) : 'TZS'; @endphp

{{ __('Total Employees') }}

{{ number_format($totalEmployees) }}

100%

{{ __('Monthly Payroll') }}

{{ $currencySymbol }} {{ number_format($currentMonthTotal / 1000, 0) }}K

@if($payrollTrend != 0) @if($payrollTrend >= 0) +{{ number_format(abs($payrollTrend), 0) }}% @else {{ number_format($payrollTrend, 0) }}% @endif @endif

{{ __('Gross Pay') }}

{{ $currencySymbol }} {{ number_format($currentMonthGross / 1000, 0) }}K

{{ __('Latest') }}

{{ __('Deductions') }}

{{ $currencySymbol }} {{ number_format($currentMonthDeductions / 1000, 0) }}K

{{ $currentMonthGross > 0 ? number_format(($currentMonthDeductions/$currentMonthGross)*100, 0) : 0 }}%

{{ __('Payroll Trends') }}

{{ __('Employee Categories') }}

{{ __('Current') }}
{{ __('Full Time') }} {{ $fullTime }}
{{ $totalEmployees > 0 ? number_format(($fullTime/$totalEmployees)*100, 0) : 0 }}%
{{ __('Part Time') }} {{ $partTime }}
{{ $totalEmployees > 0 ? number_format(($partTime/$totalEmployees)*100, 0) : 0 }}%
{{ __('Contract') }} {{ $contract }}
{{ $totalEmployees > 0 ? number_format(($contract/$totalEmployees)*100, 0) : 0 }}%

{{ __('New Hires') }}

{{ $recentEmployees->count() }}

{{ __('Expiring') }}

{{ $expiringContracts->count() }}

{{ __('Employee Growth') }}

{{ __('Payroll Breakdown') }}

{{ __('Latest') }}

{{ __('Gross Pay') }}

{{ $currencySymbol }} {{ number_format($currentMonthGross / 1000, 0) }}K

{{ __('Total Deductions') }}

{{ $currencySymbol }} {{ number_format($currentMonthDeductions / 1000, 0) }}K

{{ __('Net Pay') }}

{{ $currencySymbol }} {{ number_format($currentMonthTotal / 1000, 0) }}K

{{ __('Expiring Contracts') }}

{{ __('View All') }} →
@forelse($expiringContracts as $contract)
{{ strtoupper(substr($contract->employee->first_name, 0, 1) . substr($contract->employee->last_name, 0, 1)) }}

{{ $contract->employee->first_name }} {{ $contract->employee->last_name }}

{{ __('Expires') }}: {{ \Carbon\Carbon::parse($contract->end_date)->format('M d, Y') }}

{{ \Carbon\Carbon::parse($contract->end_date)->diffForHumans() }}
@empty

{{ __('No contracts expiring soon.') }}

@endforelse

{{ __('Recent Hires') }}

{{ __('View All') }} →
@forelse($recentEmployees as $employee)
{{ strtoupper(substr($employee->first_name, 0, 1) . substr($employee->last_name, 0, 1)) }}

{{ $employee->first_name }} {{ $employee->last_name }}

{{ $employee->department ? ucfirst($employee->department) : 'N/A' }}

{{ \Carbon\Carbon::parse($employee->join_date)->format('M d') }}
@empty

{{ __('No employees added recently.') }}

@endforelse