@foreach($products as $key => $cat) @if (isset($zones) && $zones) @if (!isset($products[$key - 1]))
@endif @if (!isset($products[$key - 1]) || (isset($products[$key - 1]) && $products[$key - 1]->zone_id != $cat->zone_id))
@endif @if (!isset($products[$key - 1]) || (isset($products[$key - 1]) && $products[$key - 1]->zone_id != $cat->zone_id))
@if ($cat->zone_id == -1)

@t('No zone categories')

@else

@t('Zone:') {{ $zones->{$cat->zone_id}->name }}

{!! Form::label('data[Order][extra][zone_start_time]['.$cat->zone_id.']', t('Start Time')) !!} {!! Form::select( 'data[Order][extra][zone_start_time]['.$cat->zone_id.']', array_merge( ['' => ''], array_combine( (isset($settings->times) && $settings->times ? $settings->times : times(['step' => 5])), (isset($settings->times) && $settings->times ? $settings->times : times(['step' => 5])) ) ), ( isset($data->Order->extra->zone_start_time->{$cat->zone_id}) ? $data->Order->extra->zone_start_time->{$cat->zone_id} : null ), [ 'class' => 'form-control', 'empty' => true, 'times' ] ) !!}
{!! Form::label('data[Order][extra][zone_people][' . $cat->zone_id. ']', t('People')) !!} {!! Form::number( 'data[Order][extra][zone_people][' . $cat->zone_id. ']', ( isset($data->Order->extra->zone_people->{$cat->zone_id}) ? $data->Order->extra->zone_people->{$cat->zone_id} : null ), [ 'min' => 0, 'step' => '1', 'class' => 'form-control' ] ) !!}
@endif

@endif @endif @if ( isset($cat->Products) && count($cat->Products) > 0 )

{{ $cat->name }} @if (isset($stats) && $stats) ( sold {{ $stats->{$cat->id}->sold}} @if ( isset($stats->{$cat->id}->overall_qty) && $stats->{$cat->id}->overall_qty > 0 ) / {{ $stats->{$cat->id}->overall_qty}} @elseif (isset($stats->{$cat->id}->qty) && $stats->{$cat->id}->qty) / {{ $stats->{$cat->id}->qty}} @endif ) @endif

@php $tiers = []; foreach ($cat->Products as $k => $v) { $tiers[$v->tier][] = $v; } @endphp
@if ( isset($settings->content->group_by_tier) && $settings->content->group_by_tier && count($tiers) > 1 )
@foreach ($tiers as $tier_id => $products)

{{ isset($settings->content->tier_names->{$tier_id}) && $settings->content->tier_names->{$tier_id} ? $settings->content->tier_names->{$tier_id} : $tier_id }}

@include( 'Plugins/Payment/Views/Elements/Order/category_contents', [ 'cat' => $cat, 'categories' => $categories, 'products' => $products ] )
@endforeach
@else @include( 'Plugins/Payment/Views/Elements/Order/category_contents', [ 'cat' => $cat, 'categories' => $categories, 'products' => $cat->Products ] ) @endif
{{--
@foreach ($cat->Products as $product) @php /* fix for orders which has matching event, but order items use booking type products. Since those products are not loaded in the event form, we are taking them from the OrdersItem node and replacing the default product attached to the event */ if (isset($data->Order->OrdersItem->{$product->parent_id})) { $product = $data->Order->OrdersItem->{$product->parent_id}->Product; } @endphp @include( 'Plugins/Payment/Views/Elements/Order/product_row', [ 'category' => $categories->{$cat->id}, 'product' => $product ] ) @endif
@t('Product') @if ( isset($categories->{$cat->id}->extra->deposit) && $categories->{$cat->id}->extra->deposit == 1 ) @t('Total Price') @endif @if ($categories->{$cat->id}->extra->priced == 1) @if ( isset($categories->{$cat->id}->extra->deposit) && $categories->{$cat->id}->extra->deposit == 1 ) @t('To pay now') @else @t('Price') @endif @endif @t('Qty')
--}}
@endif @if (isset($zones) && $zones) @if (!isset($products[$key + 1]))
@endif @endif @endforeach