@if ($receiptSettings->show_restaurant_logo) @endif {{ restaurant()->name }}
{{ branch()->address }}
@lang('modules.customer.phone'): {{ restaurant()->phone_number }}
@if ($receiptSettings->show_tax) @foreach ($taxDetails as $taxDetail)
{{ $taxDetail->tax_name }}: {{ $taxDetail->tax_id }}
@endforeach @endif
@lang('modules.order.orderNumber') #{{ $order->order_number }} {{ $order->date_time->timezone(timezone())->translatedFormat('d M Y H:i') }}
@if ($receiptSettings->show_table_number && $order->table && $order->table->table_code) @lang('modules.settings.tableNumber') :{{ $order->table->table_code }} @endif @if ($receiptSettings->show_total_guest && $order->number_of_pax) @lang('modules.order.noOfPax') :{{ $order->number_of_pax }} @endif
@if ($receiptSettings->show_waiter && $order->waiter && $order->waiter->name) @lang('modules.order.waiter') :{{ $order->waiter->name }} @endif
@if ($receiptSettings->show_customer_name && $order->customer && $order->customer->name) @lang('modules.customer.customer') :{{ $order->customer->name }} @endif
@if ($receiptSettings->show_customer_address && $order->customer && $order->customer->delivery_address)
@lang('modules.customer.customerAddress') :{{ $order->customer->delivery_address }}
@endif
@foreach ($order->items as $item) @endforeach
@lang('modules.order.qty') @lang('modules.menu.itemName') @lang('modules.order.price') @lang('modules.order.amount')
{{ $item->quantity }} {{ $item->menuItem->item_name }} @if (isset($item->menuItemVariation))
({{ $item->menuItemVariation->variation }}) @endif @foreach ($item->modifierOptions as $modifier)
• {{ $modifier->name }} (+{{ currency_format($modifier->price, restaurant()->currency_id) }})
@endforeach
{{ currency_format($item->price, restaurant()->currency_id) }} {{ currency_format($item->amount, restaurant()->currency_id) }}
@lang('modules.order.subTotal'): {{ currency_format($order->sub_total, restaurant()->currency_id) }}
@if (!is_null($order->discount_amount))
@lang('modules.order.discount') @if ($order->discount_type == 'percent') ({{ rtrim(rtrim($order->discount_value, '0'), '.') }}%) @endif -{{ currency_format($order->discount_amount, restaurant()->currency_id) }}
@endif @foreach ($order->charges as $item)
{{ $item->charge->charge_name }} @if ($item->charge->charge_type == 'percent') ({{ $item->charge->charge_value }}%) @endif: {{ currency_format(($item->charge->getAmount($order->sub_total - ($order->discount_amount ?? 0))), restaurant()->currency_id) }}
@endforeach @if ($order->tip_amount > 0)
@lang('modules.order.tip'): {{ currency_format($order->tip_amount, restaurant()->currency_id) }}
@endif @if ($order->order_type === 'delivery' && !is_null($order->delivery_fee))
@lang('modules.delivery.deliveryFee') @if($order->delivery_fee > 0) {{ currency_format($order->delivery_fee, restaurant()->currency_id) }} @else @lang('modules.delivery.freeDelivery') @endif
@endif @if ($taxMode == 'order') @foreach ($order->taxes as $item)
{{ $item->tax->tax_name }} ({{ $item->tax->tax_percent }}%): {{ currency_format(($item->tax->tax_percent / 100) * ($order->sub_total - ($order->discount_amount ?? 0)), restaurant()->currency_id) }}
@endforeach @else @if($order->total_tax_amount > 0) @php $taxTotals = []; $totalTax = 0; foreach ($order->items as $item) { $qty = $item->quantity ?? 1; $taxBreakdown = is_array($item->tax_breakup) ? $item->tax_breakup : (json_decode($item->tax_breakup, true) ?? []); foreach ($taxBreakdown as $taxName => $taxInfo) { if (!isset($taxTotals[$taxName])) { $taxTotals[$taxName] = [ 'percent' => $taxInfo['percent'] ?? 0, 'amount' => ($taxInfo['amount'] ?? 0) * $qty ]; } else { $taxTotals[$taxName]['amount'] += ($taxInfo['amount'] ?? 0) * $qty; } } $totalTax += $item->tax_amount ?? 0; } @endphp
@foreach ($taxTotals as $taxName => $taxInfo)
{{ $taxName }} ({{ $taxInfo['percent'] }}%) {{ currency_format($taxInfo['amount'], restaurant()->currency_id) }}
@endforeach
@lang('modules.order.totalTax'): {{ currency_format($totalTax, restaurant()->currency_id) }}
@endif @endif @if ($payment)
@lang('modules.order.balanceReturn'): {{ currency_format($payment->balance, restaurant()->currency_id) }}
@endif
@lang('modules.order.total'): {{ currency_format($order->total, restaurant()->currency_id) }}
{{-- --}}