{{ __('Edit Payment') }}

← Back
@if($errors->any())
    @foreach($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif {{-- Trip Info (Read Only) --}}

Trip Details

{{ $payment->trip->location }}

{{ $payment->trip->date->format('d M Y') }} • {{ $payment->trip->vehicle->vehicle_number ?? 'N/A' }} • {{ $payment->trip->driver->driver_name ?? 'N/A' }}

Rent Amount

₹{{ number_format($payment->trip->rent_amount, 2) }}

@csrf @method('PUT')
{{-- Form Entry --}}

Update Payment Details

{{-- Live Balance Calculation --}}

Total Rent

₹{{ number_format($payment->trip->rent_amount, 2) }}

Total Paid

Final Balance

Status will be: Partial Status will be: Completed

{{-- Payment History --}} @if($paymentHistory->count() > 0)

Payment History

@foreach($paymentHistory as $history) @endforeach
Date Amount Method Status
{{ $history->date ? $history->date->format('d M Y') : $history->created_at->format('d M Y') }} @if($history->id == $payment->id) CURRENT EDIT @endif ₹{{ number_format($history->paid + $history->advance, 2) }} {{ $history->method ?? 'Cash' }} {{ $history->status }}
@endif
{{-- Save --}}