@csrf
@if($order->table) ← Volver a la mesa @else @endif
@if(session('success'))
{{ session('success') }}
@endif @if(session('error'))
{{ session('error') }}
@endif
{{-- ENCABEZADO EMPRESA --}}
@php $logo = $settings['company_logo'] ?? null; @endphp @if($logo) @endif
{{ $settings['company_name'] ?? 'MI RESTAURANTE' }}
Pre-cuenta
#{{ str_pad($order->id, 6, '0', STR_PAD_LEFT) }}
{{-- DATOS --}} @if($order->table) @if($order->table->area) @endif @endif
Mesa{{ $order->table->name }}
Zona{{ $order->table->area->name }}
Atendido por{{ $order->user->name ?? 'Administrador' }}
Fecha{{ now()->format('d/m/Y H:i') }}
{{-- DETALLE DE PRODUCTOS --}} @foreach($order->details as $detail) @endforeach
Cant Producto Total
{{ $detail->quantity }}x {{ $detail->product->name ?? '' }} {{ number_format($detail->quantity * round((float)$detail->price, 2), 2) }}
{{-- TOTALES --}} @php $descuento = $order->discount ?? 0; $propina = $order->tip ?? 0; $subtotal = $order->total; $total = $subtotal + $propina - $descuento; @endphp
@if($descuento > 0) @endif @if($propina > 0) @endif
Subtotal{{ $settings['currency_symbol'] ?? 'S/' }} {{ number_format($subtotal, 2) }}
Descuento-{{ $settings['currency_symbol'] ?? 'S/' }} {{ number_format($descuento, 2) }}
Propina{{ $settings['currency_symbol'] ?? 'S/' }} {{ number_format($propina, 2) }}
TOTAL A PAGAR {{ $settings['currency_symbol'] ?? 'S/' }} {{ number_format($total, 2) }}