@php $invoice = \App\Support\InvoiceSettings::from($cachedSettings); $invoiceNumber = \App\Support\InvoiceSettings::number($invoice, $reservation->id) . '-P' . $payment->id; $paidBeforeThisPayment = max($reservation->paid_amount - (float) $payment->amount, 0); $remainingAfterPayment = max((float) $reservation->price - (float) $reservation->paid_amount, 0); @endphp فاتورة دفعة
{{ $invoice['company_name'] }}
@if ($invoice['subtitle'])
{{ $invoice['subtitle'] }}
@endif @if ($invoice['phone'])
{{ __('dashboard.phone') }}: {{ $invoice['phone'] }}
@endif
فاتورة دفعة
رقم الفاتورة: {{ $invoiceNumber }}
تاريخ الدفعة: {{ $payment->created_at->format('Y-m-d H:i') }}
رقم الحجز: {{ $reservation->id }}
العميل: {{ $reservation->customer?->name ?? '-' }}
{{ __('dashboard.phone') }}: {{ $reservation->customer?->phone ?? '-' }}
المنتج: {{ $reservation->product?->name ?? '-' }}
SKU: {{ $reservation->product?->sku ?? '-' }}
@if ($payment->payment_reference) @endif @if ($payment->notes) @endif
البيان القيمة
إجمالي الحجز {{ number_format($reservation->price, 2) }}
المدفوع قبل هذه الدفعة {{ number_format($paidBeforeThisPayment, 2) }}
قيمة هذه الدفعة {{ number_format($payment->amount, 2) }}
إجمالي المدفوع بعد الدفعة {{ number_format($reservation->paid_amount, 2) }}
المتبقي بعد الدفعة {{ number_format($remainingAfterPayment, 2) }}
طريقة الدفع {{ $payment->payment_method }}
مرجع الدفع {{ $payment->payment_reference }}
ملاحظات {{ $payment->notes }}