@extends('layouts.app') @section('title', 'Payroll & HR') @php $qparams = request()->only(['q','status','employment_type','project_id','sort','direction','per_page']); $att = (float) ($stats['attendance_rate'] ?? 0); $attClass = $att >= 85 ? 'text-emerald-600' : ($att >= 60 ? 'text-amber-600' : 'text-red-600'); $hasFilters = ($filters['q'] ?? '') !== '' || ($filters['status'] ?? 'all') !== 'all' || ($filters['employment_type'] ?? 'all') !== 'all' || ($filters['project_id'] ?? '') !== ''; @endphp @section('content')
Please fix the following:
Import summary
Created: {{ $sum['created'] ?? 0 }} · Updated: {{ $sum['updated'] ?? 0 }} · Skipped: {{ $sum['skipped'] ?? 0 }}
@if (!empty($sum['errors']))Total Employees
{{ $stats['total_employees'] }}
Monthly Payroll
{{ \App\Support\Format::mwk($stats['monthly_payroll']) }}
Attendance Rate
{{ number_format($att, 1) }}%
On Leave
{{ $stats['on_leave'] }}
Employee Directory
| Name | Role | Project | Salary | Type | Status | Action |
|---|---|---|---|---|---|---|
|
{{ $e->initials }}
{{ $e->name }} @if($e->email || $e->phone){{ $e->email }}{{ $e->email && $e->phone ? ' · ' : '' }}{{ $e->phone }} @endif |
{{ $e->job_title }}
@if($e->department)
{{ $e->department }} @endif |
@if($e->project_id) {{ $e->project?->name }} @else Unassigned @endif | {{ \App\Support\Format::mwk($e->basic_salary) }} @if($e->employment_type === 'Daily')/day@endif | {{ $e->employment_type }} | {{ $e->status }} | |
|
@if($hasFilters)
No employees match your filters Clear Filters @elseNo employees found Add your first employee or import employees from Excel. |
||||||
Recent Payroll Runs
| Period | Employees | Gross | Deductions | Net | Status | Action |
|---|---|---|---|---|---|---|
| {{ $r->period_start->format('M j') }} – {{ $r->period_end->format('M j, Y') }} | {{ $r->items_count }} | {{ \App\Support\Format::mwkDecimal($r->total_gross) }} | {{ \App\Support\Format::mwkDecimal($r->total_deductions) }} | {{ \App\Support\Format::mwkDecimal($r->total_net) }} | {{ $r->status }} | View PDF @if($r->status === 'Approved') Mark Paid @endif |
| No payroll runs yet. Generate a payroll to get started. | ||||||
Add Employee
Edit Employee