@extends('admin.layouts.app') @section('page-title', 'Payments') @section('page-description', 'Manage and monitor all payment transactions') @section('content') @push('styles') @endpush

Payment Management

View online payments and record manual client payments.

Total Payments
{{ $totalPayments ?? 0 }}
All payment transactions
Successful
{{ $successfulPayments ?? 0 }}
Completed payments
Pending
{{ $pendingPayments ?? 0 }}
Awaiting payment
Failed
{{ $failedPayments ?? 0 }}
Failed or cancelled
Total Successful Payment Amount
{{ money((float)($totalPaymentAmount ?? $totalAmount ?? 0)) }}
💰
Search & Filter Payments
Reset

Payment Transactions

Online and manually recorded payments

@if($payments->count())
@foreach($payments as $payment) @php $loan = $payment->loan; $installment = $payment->installment; @endphp @endforeach
Client Loan / EMI Payment ID Amount Method Status Date Action
{{ $payment->user->name ?? 'Unknown' }}
{{ $payment->user->mobile ?? ($payment->user->email ?? '—') }}
@if($loan)
{{ $loan->loan_number ?? 'Loan #'.$loan->id }}
@if($installment)
EMI #{{ $installment->installment_number }}
@else
Loan balance payment
@endif @else @endif
{{ $payment->payment_id ?? '—' }}
{{ $payment->order_id ?? '' }}
{{ money((float)($payment->amount ?? 0)) }} @if($payment->payment_method) {{ str_replace('_',' ', $payment->payment_method) }} @elseif($payment->is_manual) Manual @else Online @endif @if($payment->status === 'paid') ● Paid @elseif(in_array($payment->status,['pending','created'],true)) ● {{ ucfirst($payment->status) }} @elseif(in_array($payment->status,['failed','cancelled','cancelled_by_user'],true)) ● {{ ucfirst(str_replace('_',' ',$payment->status)) }} @else ● {{ ucfirst($payment->status ?? 'Unknown') }} @endif {{ $payment->paid_at?->format('d M Y, h:i A') ?? $payment->created_at?->format('d M Y, h:i A') ?? '—' }} View @if($loan) Loan @endif
@else
💳 No payment transactions found.
@endif
@if($payments->hasPages())
Page {{ $payments->currentPage() }} of {{ $payments->lastPage() }}
@endif
@endsection