@extends('dashboard.layouts.app') @push('styles') @endpush @section('content') @include('components.alert')
@csrf @if($payment->exists) @method('PUT') @endif @if($errors->any())
Please complete the highlighted payment fields.
    @foreach($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif
{{ $payment->exists ? 'Edit Payment' : 'Create Payment' }}
Fill the payment data and review the journal entry before posting.
Parties / Beneficiaries
@error('party_type')
{{ $message }}
@enderror
@php $selectedPartyId = old('party_id', $payment->party_id); $selectedPartyLabel = old('party_name', $payment->party_name); $selectedPartyRef = old('party_ref', $payment->party_ref); $hasPrefilledInvoiceParty = $prefillInvoice && $selectedPartyId; $keepNativePartySelect = $selectedPartyId && ($errors->any() || $hasPrefilledInvoiceParty); @endphp @error('party_id')
{{ $message }}
@enderror
The list changes by party type. Company uses manual entry only.
@error('party_name')
{{ $message }}
@enderror
Company is type-only in this stage and does not use an entity row.
The list changes by party type. Company uses manual entry only.
Company is type-only in this stage and does not use an entity row.
Payment Setup
@error('payment_date')
{{ $message }}
@enderror
@error('direction')
{{ $message }}
@enderror
@error('amount')
{{ $message }}
@enderror
@error('payment_method')
{{ $message }}
@enderror
@error('cost_center_id')
{{ $message }}
@enderror
@error('from_account_id')
{{ $message }}
@enderror
@error('to_account_id')
{{ $message }}
@enderror
Journal Preview
Live Preview
Accounting journal entry that will be posted

This is the exact debit and credit structure created when you post the payment. The entry stays balanced as long as the amount and accounts are set.

Balanced
Party
{{ old('party_name', $payment->party_name) ?: 'Select a party first' }}
Direction / Source
{{ ucfirst(old('direction', $payment->direction ?? 'incoming')) }} / Manual
Journal Amount
{{ number_format((float) old('amount', $payment->amount ?? 0), 2) }} {{ old('currency', $payment->currency ?? 'EGP') }}
Account
Debit
Credit
0.00
-
-
0.00
Total
0.00
0.00
Debit and credit will match once an amount is entered.
Posting creates one journal entry with two lines.
Notes
Cancel
@endsection @push('scripts') @endpush