{{-- ── CUSTOMER + ADDRESS GRID ─────────────────────────── --}}
{{-- Customer Info --}}
|
{{ __('invoice.customer_info') }}
| {{ __('invoice.customer_name') }} |
{{ $customerName }} |
| {{ __('invoice.customer_phone') }} |
{{ $customerPhone }} |
| {{ __('invoice.invoice_date') }} |
{{ $order->created_at->locale($locale)->isoFormat('LL') }} |
|
{{-- Address --}}
{{ __('invoice.delivery_address') }}
@if ($isPickup)
| {{ __('invoice.pickup') }} |
@else
@if ($city)
| {{ __('invoice.city') }} |
{{ $city }} |
@endif
| {{ __('invoice.street') }} |
{{ $street }} |
| {{ __('invoice.building') }} |
{{ $building }} |
| {{ __('invoice.floor') }} |
{{ $floor }} |
| {{ __('invoice.apartment') }} |
{{ $apartment }} |
@endif
|
{{-- ── ORDER ITEMS TABLE ────────────────────────────────── --}}
{{ __('invoice.items') }}
| # |
{{ __('invoice.product') }} |
{{ __('invoice.qty') }} |
{{ __('invoice.unit_price') }}
|
{{ __('invoice.discount') }}
|
{{ __('invoice.total') }} |
@foreach ($order->items as $index => $item)
@php
$productName = '—';
if ($item->product) {
try {
$productName = $item->product->getTranslation('name', $locale) ?: $item->product->name;
} catch (\Exception $e) {
$productName = $item->product->name ?? '—';
}
}
$variantName = null;
@endphp
| {{ $index + 1 }} |
{{ $productName }}
@if ($variantName)
{{ $variantName }}
@endif
|
{{ $item->quantity }} |
{{ number_format((float) $item->unit_price, 2) }} {{ $currency }} |
@if ($item->discount_amount > 0)
-{{ number_format((float) $item->discount_amount, 2) }}
{{ $currency }}
@else
—
@endif
|
{{ number_format((float) $item->total_price, 2) }} {{ $currency }} |
@endforeach
{{-- ── TOTALS ───────────────────────────────────────────── --}}
|
| {{ __('invoice.subtotal') }} |
{{ number_format((float) $order->subtotal, 2) }} {{ $currency }}
|
@if ($order->discount_amount > 0)
| {{ __('invoice.item_discount') }} |
-{{ number_format((float) $order->discount_amount, 2) }}
{{ $currency }} |
@endif
@if ($order->subtotal_after_discount && $order->discount_amount > 0)
| {{ __('invoice.subtotal_after_discount') }} |
{{ number_format((float) $order->subtotal_after_discount, 2) }}
{{ $currency }} |
@endif
@if ($order->coupon_discount_amount > 0)
| {{ __('invoice.coupon_discount') }} |
-{{ number_format((float) $order->coupon_discount_amount, 2) }}
{{ $currency }}
|
@endif
@if ($order->tax_amount > 0)
| {{ __('invoice.tax') }} |
{{ number_format((float) $order->tax_amount, 2) }}
{{ $currency }} |
@endif
| {{ __('invoice.delivery_fee') }} |
{{ number_format((float) $order->shipping_amount, 2) }}
{{ $currency }} |
| {{ __('invoice.total_amount') }} |
{{ number_format((float) $order->total_amount, 2) }}
{{ $currency }} |
|
{{-- ── NOTES ────────────────────────────────────────────── --}}
@if ($order->notes)
{{ __('invoice.notes') }}
{{ $order->notes }}
@endif
{{-- /.body-padding --}}
{{-- ── FOOTER ───────────────────────────────────────────────── --}}