@extends('layouts.app') @section('content')
| # | Type | Invoice No | Customer | Method | Received | By | Time | Action |
|---|---|---|---|---|---|---|---|---|
| {{ $payments->firstItem() + $i }} | @if($p->payment_type === 'due') Due @else Sale @endif |
@if(!empty($p->invoice_id))
{{ $p->invoice_number }}
@else
{{ $p->invoice_numbers ?: '-' }}
@endif
Payment ID: {{ $p->payment_id }}
|
{{ $p->customer_name ?? 'Walk-in Customer' }}
@if(!empty($p->customer_pin))
PIN: {{ $p->customer_pin }}
@endif
|
{{ strtoupper($p->method ?? '-') }} |
{{ number_format((float)($p->received ?? 0), 2) }}
@if($p->payment_type === 'due')
Applied: {{ number_format((float)($p->applied ?? 0), 2) }}
@if((float)($p->change_amount ?? 0) > 0.0001)
| Change: {{ number_format((float)($p->change_amount ?? 0), 2) }}
@endif
@endif
|
{{ $p->user_name ?? '-' }} | {{ $p->paid_at ? \Carbon\Carbon::parse($p->paid_at)->format('Y-m-d h:i A') : '-' }} | @php $rowAmount = number_format((float)($p->received ?? 0), 2, '.', ''); $rowMethod = strtolower($p->method ?? ''); $rowPaidAt = $p->paid_at ? \Carbon\Carbon::parse($p->paid_at)->format('Y-m-d\\TH:i') : ''; @endphp |