Update Payment
@csrf
@error('payment_date') {{ $message }} @enderror
@error('amount') {{ $message }} @enderror
@error('payment_type') {{ $message }} @enderror
{{-- Payments Tab --}}
@php $cumulativeTotal = 0; @endphp @forelse ($paymentsForProduct->whereNotIn('type', ['refund','loss']) as $payment) @php $cumulativeTotal += $payment->paid_amount; @endphp @empty @endforelse @if($cumulativeTotal > 0) @endif
Product Payment Date Amount Payment Method

{{ $payment->product_dtls->name }} / {{ $payment->product_dtls->code }}

{{ \Carbon\Carbon::parse($payment->payment_date)->format('d/m/Y') }}

{{ $payment->paid_amount }}

{{ $payment->payment_type ?? 'Unknown' }}

No Payments found.

Total Amount: {{ $cumulativeTotal }}
{{-- Refunds Tab --}}
@php $cumulativeTotal = 0; @endphp @forelse ($paymentsForProduct->whereIn('type', ['refund']) as $payment) @php $cumulativeTotal += $payment->paid_amount; @endphp @empty @endforelse @if($cumulativeTotal > 0) @endif
Product Payment Date Amount Payment Method

{{ $payment->product_dtls->name }} / {{ $payment->product_dtls->code }}

{{ \Carbon\Carbon::parse($payment->payment_date)->format('d/m/Y') }}

{{ $payment->paid_amount }}

{{ $payment->payment_type ?? 'Unknown' }}

No Payments found for Returns.

Total Amount: {{ $cumulativeTotal }}
{{-- Loss Tab --}}
@php $cumulativeTotal = 0; @endphp @forelse ($paymentsForProduct->whereIn('type', ['loss']) as $payment) @php $cumulativeTotal += $payment->paid_amount; @endphp @empty @endforelse @if($cumulativeTotal > 0) @endif
Product Payment Date Amount Payment Method

{{ $payment->product_dtls->name }} / {{ $payment->product_dtls->code }}

{{ \Carbon\Carbon::parse($payment->payment_date)->format('d/m/Y') }}

{{ $payment->paid_amount }}

{{ $payment->payment_type ?? 'Unknown' }}

No Payments found for Non-Returnables.

Total Amount: {{ $cumulativeTotal }}
Cancel