@extends('garage.layouts.app')
@section('title', 'Payroll run')
@section('content')
@include('garage.hr.styles')
Payroll run
Month: {{ $run->month }}
@php
$payslipByEmployee = [];
foreach ($payslips as $ps) {
$payslipByEmployee[(int) $ps->garage_employee_id] = $ps;
}
@endphp
@php
$tBasic = 0; $tAllow = 0; $tBonus = 0; $tDed = 0; $tFine = 0; $tAdvance = 0; $tNet = 0; $tFixedEmpAllow = 0; $tVarEmpAllow = 0; $tEmpFund = 0;
foreach($payslips as $pp){
$tBasic += (float)($pp->basic_salary ?? 0);
$tAllow += (float)($pp->total_allowance ?? 0);
$tBonus += (float)($pp->total_bonus ?? 0);
$tDed += (float)($pp->total_deduction ?? 0);
$tFine += (float)($pp->total_fine ?? 0);
$tAdvance += (float)($pp->total_advance ?? 0);
$tNet += (float)($pp->net_pay ?? 0);
$tFixedEmpAllow += (float)($pp->employee_fixed_allowance ?? 0);
$tVarEmpAllow += (float)($pp->employee_variable_allowance ?? 0);
$tEmpFund += (float)($pp->employee_fund_deduction ?? 0);
}
@endphp
Click a summary card or a linked amount in the table to see line-by-line breakdown.
Basic
{{ number_format($tBasic, 2) }}
Allow
{{ number_format($tAllow,2) }}
F {{ number_format($tFixedEmpAllow, 0) }} · V {{ number_format($tVarEmpAllow, 0) }}
Bonus
{{ number_format($tBonus,2) }}
Ded
{{ number_format($tDed,2) }}
Adv {{ number_format($tAdvance, 0) }} · Fund {{ number_format($tEmpFund, 0) }}
Fine
{{ number_format($tFine, 2) }}
Net pay
{{ number_format($tNet, 2) }}
@include('garage.payroll._detail-modal')
@endsection
@push('styles')
@endpush
@push('scripts')
@endpush