@extends('layouts.app') @section('title', 'Locum Payroll | ' . $batch->batch_label) @section('content') {{-- Header --}}

{{ $batch->batch_label }}

Period: {{ $batch->period_from?->format('d M Y') }} – {{ $batch->period_to?->format('d M Y') }} · Prepared by {{ $batch->preparedBy->name ?? '-' }} · {{ $batch->created_at->format('d M Y H:i') }} @if($batch->approvedBy) · Approved by {{ $batch->approvedBy->name }} on {{ $batch->approved_at->format('d M Y') }}@endif

@php $sc = ['draft'=>'badge-gray','approved'=>'badge-success','paid'=>'badge-success','cancelled'=>'badge-danger']; @endphp {{ ucfirst($batch->status) }} @if($batch->status === 'draft')
@csrf @method('PUT')
@csrf @method('DELETE')
@endif ← Back
{{-- Summary --}}

Locums

{{ $batch->items->count() }}

Total Shifts

{{ $batch->items->sum('total_shifts') }}

Gross Pay

KES {{ number_format($batch->items->sum('gross_pay')) }}

WHT (5%)

KES {{ number_format($batch->items->sum('wht_amount')) }}

Net Pay

KES {{ number_format($batch->items->sum('net_pay')) }}

{{-- Payment Sheet --}}

CLARA ROSA HOSPITAL | LOCUM PAYMENT SHEET

{{ $batch->batch_label }} · Employment Act, 2007 | KRA WHT Compliance

@if($batch->status === 'draft')@endif @foreach($batch->items as $i => $item) @if($batch->status === 'draft') @endif @endforeach
S/No. Full Name ID No. KRA PIN Role Shifts Rate Gross (KES) WHT 5% Ded. Net Pay PaymentAdjust
{{ $i + 1 }} {{ $item->locum->full_name ?? '' }} {{ $item->locum->id_passport_no ?? '-' }} {{ $item->locum->kra_pin ?? '-' }} {{ $item->locum->role_designation ?? '-' }} {{ $item->total_shifts }} @if(($item->locum->rate_type ?? 'per_shift')==='percentage'){{ $item->rate_used }}%@else KES {{ number_format($item->rate_used) }}@endif {{ number_format($item->gross_pay) }} {{ number_format($item->wht_amount) }} {{ $item->other_deductions > 0 ? number_format($item->other_deductions) : '-' }} {{ number_format($item->net_pay) }} {{ ucfirst($item->payment_status) }}
TOTALS {{ $batch->items->sum('total_shifts') }} KES {{ number_format($batch->items->sum('gross_pay')) }} KES {{ number_format($batch->items->sum('wht_amount')) }} KES {{ number_format($batch->items->sum('other_deductions')) }} KES {{ number_format($batch->items->sum('net_pay')) }}
{{-- Deduction Modal --}} @if($batch->status === 'draft') @endif @endsection @section('scripts') @endsection