@php $salary = $salary ?? ['configured' => false]; $current = $salary['current'] ?? null; $onPayroll = (bool) ($employee->include_in_payroll ?? false); $canViewAmount = (bool) ($salary['can_view'] ?? false); $basicAmount = $current ? number_format((float) $current->basic_salary, 2) : null; @endphp @if (! ($salary['configured'] ?? false))
Salary master tables are not available in this environment.
@elseif (! ($salary['can_view'] ?? false))
You do not have permission to view salary master data.
@else

Salary master

@if ($onPayroll && $current) On payroll @elseif ($onPayroll) Included · no salary @else Not on payroll @endif
Basic pay
@if ($basicAmount && $canViewAmount) •••••• KES {{ $basicAmount }} @else — @endif
Active since
{{ $current?->effective_from?->format('M j, Y') ?? '—' }}
Status
{{ $current?->status ?? 'none' }}
History count
{{ (int) ($salary['history_count'] ?? 0) }}

Active allowances

@forelse ($current?->allowances_json ?? [] as $item)
{{ $item['label'] ?? $item['code'] ?? 'Allowance' }} · KES {{ number_format((float) ($item['amount'] ?? 0), 2) }}
@empty None @endforelse

Recurring deductions

@forelse ($current?->other_deductions_json ?? [] as $item)
{{ $item['label'] ?? $item['code'] ?? 'Deduction' }} · KES {{ number_format((float) ($item['amount'] ?? 0), 2) }}
@empty None @endforelse
Edit payroll on the employee record
@endif