| No | Name | Email/Phone | Billing Invoice | Car Plate | Location | Amount (RM) | Billing Status | LHDN Status | Receipt | Actions |
|---|---|---|---|---|---|---|---|---|---|---|
| {{ $loop->index + 1 }} | @if($canAmendRequests) {{ $item->name }} @else {{ $item->name }} @endif |
{{ $item->email ?? '-' }}
{{ $item->phone ?? '' }}
|
{{ $item->invoice_no }}
{{ optional($item->txn_date)->format('d/m/Y H:i') ?? '-' }}
|
{{ $item->car_plate ?? '-' }} | {{ $item->site->name ?? '-' }} | {{ $item->amount !== null ? number_format($item->amount, 2) : '-' }} |
{{ $item->invoice_status_label }}
@if($item->payment_date)
{{ optional($item->payment_date)->format('d/m/Y') }}
@endif
{{ $item->payment_stage_label }}
|
@if($item->status)
{!! implode(' ', explode(' ', $item->status_label)) !!} @endif {{ $item->lhdn_status ?: 'Not submitted' }}
|
@php $receiptUrl = $item->receipt_path ? Storage::url($item->receipt_path) : ''; if ($receiptUrl) { $host = parse_url($receiptUrl, PHP_URL_HOST); $path = parse_url($receiptUrl, PHP_URL_PATH) ?: $receiptUrl; if (!$host || $host === 'localhost') { $receiptUrl = request()->getSchemeAndHttpHost() . $path; } } @endphp @if($receiptUrl) View @else - @endif |
@php
$hasActions = ($canSubmitToLhdn && (
(($item->invoice_status ?? 'unpaid') === 'paid' && !$item->payment_approved_at) ||
($item->payment_approved_at && $item->customer_requested_at) ||
(($item->invoice_status ?? 'unpaid') === 'paid' && $item->payment_approved_at && !$item->customer_requested_at) ||
(($item->invoice_status ?? 'unpaid') === 'paid' && $item->customer_requested_at && !($item->payment_approved_at && $item->customer_requested_at))
)) || $canAmendRequests;
@endphp
@if($hasActions)
|
| No records. | ||||||||||