@foreach ($asideMenu as $section)
  • {{ $section->title }}
  • @foreach ($section->items as $item) @if ($item->children->isNotEmpty())
  • {{ $item->menu }}
      @foreach ($item->children as $child)
    • {{ $child->menu }} @if ($child->custom_code) {!! Blade::render($child->custom_code, compact('pendingValidationCount', 'pendingApprovalCount')) !!} @endif
    • @endforeach
  • @else @php $activePattern = str_contains($item->route, '.') ? explode('.', $item->route)[0] . '.*' : $item->route; @endphp
  • {{ $item->menu }}
  • @endif @endforeach @endforeach