- 首页
@php
$top_ids =[];
if (isset($parent)) {
if (!is_array($parent)) {
$top_ids = [$parent->id];
}else{
$top_ids = $parent;
}
}
@endphp
@foreach ($all_categorys as $cate)
- id,$top_ids)) class="active" @endif>
{{ $cate->title }}
@if ($cate->childrens->isNotEmpty())
@endif
@endforeach