@lang('global.order_details')

@lang('global.order_bill') @if ($order->store_bill) @lang('global.store_bill') @lang('global.store_bill_actual_amount') @endif @if (in_array($order->store_status->title, ['pending', 'preparing'])) @lang('global.rejected') @endif @if ($order->store_bill) @endif {{-- @lang('global.amount_collected') @lang('global.amount_not_collected') --}}
@if ($order->is_delivery) @endif @foreach ($order->items_pivot as $item) @if ($order->is_delivery) @endif @foreach ($item->details->options ?? [] as $option) @foreach ($option->choices as $choice) @if ($order->is_delivery) @endif @endforeach @endforeach @endforeach
@lang('global.service') @lang('global.section') @lang('global.quantity') @lang('global.unit_price') @lang('global.total_price') @lang('global.unit_delivery_markup') @lang('global.total_delivery_markup') @lang('global.total_amount')@lang('global.notes')
{{ $item->title }} {{ $item->section }} {{ $item->quantity }} {{ $item->price - $item->delivery_markup }} {{ ($item->price - $item->delivery_markup) * $item->quantity }} {{ $item->delivery_markup }} {{ $item->delivery_markup * $item->quantity }} {{ $item->price * $item->quantity }} {{ $item->notes ?? __('global.not_exists') }}
{{ $choice->title->$locale }} {{ $option->title->$locale }} {{ $choice->quantity ?? '--' }} {{ $choice->price - $choice->delivery_markup }} {{ ($choice->price - $choice->delivery_markup) * ($choice->quantity ?? 1) }} {{ $choice->delivery_markup }} {{ $choice->delivery_markup * ($choice->quantity ?? 1) }} {{ $choice->price * ($choice->quantity ?? 1) }} @lang('global.choice_total_times_product_quantity') : {{ $choice->price * ($choice->quantity ?? 1) * $item->quantity }}

@lang('global.store_title')

{{ $order->branch->service->title }}

@lang('validation.attributes.created_at')

{{ $order->created_at }}

@lang('global.order_number')

{{ $order->number }}

@if ($order->notes)

@lang('global.notes')

{!! $order->notes !!}

@endif @if ($order->cancellation_notes)

@lang('validation.attributes.cancellation_notes')

{!! $order->cancellation_notes !!}

@endif @if ($order->undone_notes)

@lang('validation.attributes.undone_notes')

{{ $order->undone_notes }}

@endif

@lang('global.order_status')

@switch($order->is_delivery ? $order->delivery_status->title : $order->store_status->title) @case('initiated') @lang('global.initiated') @break @case('undone') @lang('global.undone') @break @case('pending') @lang('global.pending') @break @case('preparing') @lang('global.accepted') @break @case('ready') @lang('global.ready') @break @case('delivering') @lang('global.delivering') @break @case('done') @lang('global.done') @break @case('cancelled') @lang('global.cancelled') @break @case('rejected') @lang('global.rejected') @if (in_array($order->transaction?->status, ['voided', 'refunded'])) - @lang('global.refunded') @endif @break @endswitch

@lang('global.payment_method')

@lang("global.payment_methods.$order->payment_method")

@if ($order->persons)

@lang('validation.attributes.persons')

{{ $order->persons }}

@endif @if ($order->rating)

@lang('global.rating')

@for ($i = 0; $i < $order->rating->stars; $i++) @endfor {!! $order->rating->review !!}

@endif {{--

@lang('global.amount_collected')

@if (is_null($order->delivery_fees_collected)) @lang('global.unknown') @elseif ($order->delivery_fees_collected) @lang('global.yes') @else @lang('global.no') @endif

--}}

@lang('global.financial_details')

@lang('global.total_products_price')

{{ $order->financial->products_price }}

@lang('global.delivery_markup')

{{ $order->financial->delivery_markup }}

@if ($order->financial->tip)

@lang('global.tip')

{{ $order->financial->tip }}

@endif @if ($order->financial->delivery_fees)

@lang('validation.attributes.delivery_fees')

{{ $order->financial->delivery_fees }}

@endif

@lang('global.paid_amount')

{{ $order->financial->products_price + $order->financial->delivery_markup + $order->financial->tip + $order->financial->delivery_fees }}


@lang('global.customer_details')

@if ($order->name)

@lang('validation.attributes.name')

{{ $order->name }}

@endif @if ($order->phone)

@lang('validation.attributes.phone')

{{ $order->phone }}

@endif @if ($order->metadata->hotel_branch_id ?? false)

@lang('global.hotel')

{{ $order->metadata->{'hotel_branch_' . app()->getLocale()} }}

@endif @if ($order->metadata->room_id ?? false)

@lang('global.room')

{{ $order->metadata->{'room_' . app()->getLocale()} }}

@endif @if ($order->captain)

@lang('global.captain_details')

@lang('global.captain_name')

{{ $order->captain->name }}

@lang('validation.attributes.phone')

{{ $order->captain->phone }}

@if ($order->rejection_notes)

@lang('validation.attributes.rejection_notes')

{!! $order->rejection_notes !!}

@endif @endif
@lang('global.order_log')
@foreach ($order->is_delivery ? $order->delivery_statuses : $order->store_statuses as $status) @endforeach
@lang('validation.attributes.description') @lang('validation.attributes.created_at')
@if ($status->title === 'preparing') @lang('global.accepted') @else @lang("global.$status->title") @endif @if ($status->creator) - {{ $status->creator instanceof \App\Models\Admin || $status->creator instanceof \App\Models\Captain ? 'Pro Solutions' : __('global.digital-center') }} @endif {{ $status->created_at }}