@php use Illuminate\Support\Str; use App\Services\CurrencyService; @endphp @inject('currencyService', 'App\Services\CurrencyService')
{{ __('dashboard.success.created') }} {{ __('dashboard.success.updated') }} {{ __('dashboard.error') ?? 'Something went wrong' }}

{{ __('dashboard.order') }} @if ($editingOrderId) #{{ $editingOrderId }} @endif

@if ($editingOrderId) {{ __('dashboard.new') }} @else {{ __('dashboard.clear_order') }} @endif {{ __('dashboard.table_orders') }} {{ $this->heldOrders->count() }} @if (count($orderItems) > 0) {{ __('dashboard.hold') }} (F4) @endif
@error('general')
{{ $message }}
@enderror
@if ($editingOrderId)

{{ __('dashboard.status') }}

{{ $this->currentStatusLabel }}
@if ($this->nextStatus) Move to {{ $this->nextStatus['label'] }} @endif
@if ($editLockReason)
{{ $editLockReason }}
@endif
@endif

{{ __('dashboard.cart_empty') }}

@foreach ($this->orderTypes as $typeKey => $label) @endforeach
@if ($orderType === 'dine_in')

{{ __('dashboard.table') }}

@if ($selectedTableId) {{ $this->selectedTable?->name ?? __('dashboard.unknown_table') }} @else {{ __('dashboard.select_table_modal_title') }} @endif

{{ $selectedTableId ? __('dashboard.change') : __('dashboard.select') }}
@error('table')

{{ $message }}

@enderror @endif
{{ __('dashboard.subtotal') }} {{ currency((float) $this->subtotal) }}
{{ __('dashboard.tax') }} ({{ $this->taxRate }}%)
{{ currency((float) $this->taxAmount) }}
{{ __('dashboard.discount') }}
-{{ currency((float) $this->discount) }}
{{ __('dashboard.total') }} {{ currency((float) $this->total) }}
@if (!$editingOrderId) {{ $editingOrderId ? __('dashboard.save') : __('dashboard.create_order') }} @endif @if (!$editLockReason) @if ($this->canSendToKitchen) {{ __('dashboard.send') }} @endif @if ($this->canCharge) {{ __('dashboard.pay') }} (F9) @endif {{ __('dashboard.print') }} @if ($this->isEditing && $this->canCancel) {{ __('dashboard.cancel') }} @endif @else
{{ $editLockReason }}
@endif
@if ($showOptionsModal)

{{ $this->modalItem?->name }} {{ __('dashboard.options') }}

@if ($this->modalItem) @foreach ($this->groupItemOptions($this->modalItem) as $groupId => $group)

{{ $group['name'] }} ({{ $group['type'] }})

@foreach ($group['options'] as $option) @endforeach
@endforeach @endif
{{ __('dashboard.cancel') }} {{ __('dashboard.add_item') }}
@endif @if ($showTableModal)

{{ __('dashboard.select_table_modal_title') }}

@foreach ($availableAreas as $area)

{{ $area->name }} {{ $area->tables->count() }} {{ __('dashboard.tables') }}

@foreach ($area->tables as $table) @endforeach
@endforeach
@endif @if ($showPaymentModal)

{{ __('dashboard.checkout') }}

Order Total: {{ currency((float) $this->total) }}

@foreach ($paymentMethods as $method) @endforeach
@foreach ($this->quickDenominations as $denom) @endforeach
{{ __('dashboard.total') }}: {{ currency((float) $this->total) }}
{{ __('dashboard.cancel') }} {{ __('dashboard.complete_payment') }}
@endif @if ($showHeldOrdersModal)

{{ __('dashboard.held_orders') }}

@forelse ($this->heldOrders as $held)

Order #{{ $held->id }}

{{ $held->created_at->diffForHumans() }} • {{ $held->items->count() }} {{ __('dashboard.items') }}

{{ currency((float) $held->total) }}
@empty

{{ __('dashboard.no_held_orders') }}

@endforelse
@endif @if ($showDeliveryAgentModal)

{{ __('dashboard.select_driver') }}

@forelse ($deliveryAgents as $agent)
{{ $agent->initials() }}

{{ $agent->name }}

{{ $agent->phone ?? 'No Phone' }}

@empty

{{ __('dashboard.no_drivers_found') }}

@endforelse
@endif @if ($showAdjustmentModal)

{{ __('dashboard.adjustments') }}

{{ __('dashboard.cancel') }} {{ __('dashboard.apply') }}
@endif @if ($showCancelModal)

{{ __('dashboard.cancel_order') }}

{{ __('dashboard.confirm_cancel') }}

@error('cancelReason') {{ $message }} @enderror
{{ __('dashboard.no') }} {{ __('dashboard.yes_cancel') }}
@endif