@if ($data->list_type == 'custom')
{!! $children !!}
@else
@php
$args = [
'@withCategories' => true
];
if($data->list_type=='tagged'){
$args['id'] = $data->collection_tags?$data->collection_tags:[0];
}else{
$args['@sorttype'] = $data->sorttype;
$args['@limit'] = $data->limit && $data->limit > 0? $data->limit:4;
}
@endphp
@if (count($collections = $helper->getProductCollections($args)))
@foreach ($collections as $item)
@php
$url = route('web.products');
$url.="?collection=" . $item->id;
@endphp
@endforeach
@endif
@endif