@forelse($orders as $order)

#{{$order->invoice_no}}

@php $count_sell_line = count($order->sell_lines); $count_cooked = count($order->sell_lines->where('res_line_order_status', 'cooked')); $count_served = count($order->sell_lines->where('res_line_order_status', 'served')); $order_status = 'received'; if($count_cooked == $count_sell_line) { $order_status = 'cooked'; } else if($count_served == $count_sell_line) { $order_status = 'served'; } else if ($count_served > 0 && $count_served < $count_sell_line) { $order_status = 'partial_served'; } else if ($count_cooked > 0 && $count_cooked < $count_sell_line) { $order_status = 'partial_cooked'; } @endphp
@lang('restaurant.placed_at'){{@format_date($order->created_at)}} {{ @format_time($order->created_at)}}
@lang('restaurant.order_status')@lang('restaurant.order_statuses.' . $order_status)
@lang('contact.customer'){{$order->customer_name}}
@lang('restaurant.table'){{$order->table_name}}
@lang('sale.location'){{$order->business_location}}
@if($orders_for == 'kitchen') @lang('restaurant.mark_as_cooked') @elseif($orders_for == 'waiter' && $order->res_order_status != 'served') @lang('restaurant.mark_as_served') @else @endif @lang('restaurant.order_details')
@if($loop->iteration % 4 == 0) @endif @if($loop->iteration % 2 == 0)
@endif @empty

@lang('restaurant.no_orders_found')

@endforelse