Transaction History
{{ $employee->name ?? 'Employee' }} - {{ $employee->e_id ?? '-' }}
@forelse($transactions as $index => $payment) @php $salary = $payment->salary; $salaryMonth = optional($salary?->month)->format('F Y') ?? '-'; $paidAmount = (float) $payment->paid_amount; $isCancelled = !empty($payment->cancelled_at); $isPartial = !$isCancelled && $salary && (float) $salary->due_amount > 0; $paymentType = $isCancelled ? 'Cancelled Salary Payment' : ($isPartial ? 'Partial Salary Payment' : 'Full Salary Payment'); $statusLabel = $isCancelled ? 'Cancelled' : ($isPartial ? 'Partial' : 'Paid'); $statusClass = $isCancelled ? 'danger' : ($isPartial ? 'warning text-dark' : 'success'); $referenceId = $payment->payment_no ?: ($payment->transaction_id ? 'TXN-' . $payment->transaction_id : '-'); $paymentMethod = $payment->paymentMethod->name ?? $payment->transaction?->paymentMethod?->name ?? '-'; $note = $payment->note ?? $payment->transaction?->description ?? '-'; $recordedBy = optional($payment->creator)->name ?? optional($payment->transaction?->creator)->name ?? '-'; $paymentDate = optional($payment->payment_date ?? $payment->created_at)->format('d M Y, h:i A') ?? '-'; @endphp @empty @endforelse
SL Payment Date Salary Month Payment Amount Payment Type Payment Method Transaction/Reference ID Payment Status Note Paid/Recorded By
{{ $transactions->firstItem() + $index }} {{ $paymentDate }} {{ $salaryMonth }} {{ number_format($paidAmount, 2) }} BDT {{ $paymentType }} {{ $paymentMethod }} {{ $referenceId }} {{ $statusLabel }} {{ $note }} {{ $recordedBy }}
No payment transactions found for this employee.
@if($transactions->hasPages())
{{ $transactions->withQueryString()->links() }}
@endif