@extends('layouts.app') @section('content') @if($displayCategory)

{{ $displayCategory->name }}

@if(!is_null($displayCategory->address))

{{ $displayCategory->address ?? 'N/A' }}

@endif
@if(!is_null($displayCategory->hours))
  • Rating {{ str_repeat('★', round($displayCategory->rating ?? 0)) . str_repeat('☆', 5 - round($displayCategory->rating ?? 0)) }}
  • Hours {{ $displayCategory->hours }}
  • @if($displayCategory->name === 'Dining')
  • Cuisine {{ $displayCategory->cuisine ?? 'N/A' }}
  • @endif
Book Now
@else @endif
@php // Fetch featured items $featuredItems = collect([]); // Include the current category if it is featured (applies to all levels) if ($displayCategory->featured_item) { $featuredItems->push($displayCategory); } // Determine the level of the current category using breadcrumbs $categoryLevel = count($breadcrumbs); // Level 1: Only include featured immediate children (Level 2 sub-categories) if ($categoryLevel === 1) { $subCategories = \App\Models\Category::where('parent_id', $displayCategory->id) ->where('active', 1) ->where('featured_item', 1) // Only fetch featured sub-categories ->get(); $featuredItems = $featuredItems->merge($subCategories); } // Level 2: Include featured immediate children (Level 3 sub-sub-categories) if ($categoryLevel === 2) { $subSubCategories = \App\Models\Category::where('parent_id', $displayCategory->id) ->where('active', 1) ->where('featured_item', 1) // Only fetch featured sub-sub-categories ->get(); $featuredItems = $featuredItems->merge($subSubCategories); } // Level 3: Include featured siblings (other Level 3 categories under the same parent) if ($categoryLevel === 3) { $parentSubCategory = $displayCategory->parent; if ($parentSubCategory) { $featuredItems = $featuredItems->merge( \App\Models\Category::where('parent_id', $parentSubCategory->id) ->where('featured_item', 1) ->where('id', '!=', $displayCategory->id) ->where('active', 1) ->orderBy('created_at', 'asc') ->get() ); } } // Order by created_at and take top 4 $featuredItems = $featuredItems->sortBy('created_at')->take(4); @endphp @if($featuredItems->isNotEmpty())

Most Popular {{ $displayCategory->name }} in Dallas

@foreach($featuredItems as $item) @php // Determine the correct URL based on the category level $itemUrl = []; if ($categoryLevel === 1) { // Level 1: Linking to Level 2 sub-categories (e.g., /dining/steakhouses) $itemUrl = [$displayCategory->slug, $item->slug]; } elseif ($categoryLevel === 2) { // Level 2: Linking to Level 3 sub-sub-categories (e.g., /dining/steakhouses/nuri) $parentCategory = $displayCategory->parent; $itemUrl = [$parentCategory->slug, $displayCategory->slug, $item->slug]; } elseif ($categoryLevel === 3) { // Level 3: Linking to sibling Level 3 categories (e.g., from /dining/steakhouses/nuri to /dining/steakhouses/nick-sams) $parentCategory = $displayCategory->parent->parent; $subCategory = $displayCategory->parent; $itemUrl = [$parentCategory->slug, $subCategory->slug, $item->slug]; } @endphp
{{ $item->name }}

{{ \Illuminate\Support\Str::limit(strip_tags($item->description), 80) }}

@endforeach
@endif @if($displayCategory->packages->isNotEmpty())

Available Packages

@foreach($displayCategory->packages as $package)
@if($package->image) {{ $package->name }} @else
{{ $package->name }} Thumbnail
@endif

{{ $package->name }}

{!! \Illuminate\Support\Str::limit(strip_tags($package->description), 100) !!}

{{ $package->is_call_for_pricing ? 'Call for Pricing' : '$' . number_format($package->price, 2) }}

@csrf @if(!$package->is_call_for_pricing) @endif
Inquire Now
@endforeach
@endif

Dallas {{ $displayCategory->name }}

{!! $displayCategory->description !!}
@php $videos = []; // Check for child categories and their videos (only active children) if ($displayCategory->children->isNotEmpty()) { foreach ($displayCategory->children as $child) { if ($child->active && ($child->video || $child->youtube)) { $videos[] = [ 'source' => $child->youtube ?? $child->video, 'type' => $child->youtube ? 'youtube' : 'local', 'title' => $child->name, 'description' => \Illuminate\Support\Str::limit(strip_tags($child->description), 100), 'thumbnail' => $child->thumb ? asset('storage/' . $child->thumb) : 'https://picsum.photos/seed/' . rand(0, 100000) . '/800/800', ]; } } } // If no videos from children, check the parent category (if active) if (empty($videos) && $displayCategory->parent && $displayCategory->parent->active) { if ($displayCategory->parent->video || $displayCategory->parent->youtube) { $videos[] = [ 'source' => $displayCategory->parent->youtube ?? $displayCategory->parent->video, 'type' => $displayCategory->parent->youtube ? 'youtube' : 'local', 'title' => $displayCategory->parent->name, 'description' => \Illuminate\Support\Str::limit(strip_tags($displayCategory->parent->description), 100), 'thumbnail' => $displayCategory->parent->thumb ? asset('storage/' . $displayCategory->parent->thumb) : 'https://picsum.photos/seed/' . rand(0, 100000) . '/800/800', ]; } } // If still no videos, check the current category itself if (empty($videos) && ($displayCategory->video || $displayCategory->youtube)) { $videos[] = [ 'source' => $displayCategory->youtube ?? $displayCategory->video, 'type' => $displayCategory->youtube ? 'youtube' : 'local', 'title' => $displayCategory->name, 'description' => \Illuminate\Support\Str::limit(strip_tags($displayCategory->description), 100), 'thumbnail' => $displayCategory->thumb ? asset('storage/' . $displayCategory->thumb) : 'https://picsum.photos/seed/' . rand(0, 100000) . '/800/800', ]; } @endphp @if(!empty($videos))

Videos: {{ $displayCategory->name }}

@if(count($videos) === 1)

{{ $videos[0]['title'] }}

{{ $videos[0]['description'] }}

@if($videos[0]['type'] === 'youtube') @else @endif
@else
@foreach($videos as $index => $video) @endforeach

{{ $videos[0]['title'] }}

{{ $videos[0]['description'] }}

@if($videos[0]['type'] === 'youtube') @else @endif
@endif
@if(count($videos) > 1) @endif @endif @if($displayCategory->meta && $displayCategory->meta->images && is_array($displayCategory->meta->images) && count($displayCategory->meta->images) > 0)

Photos: {{ $displayCategory->name }}

@foreach($displayCategory->meta->images as $index => $image) @endforeach
{{ $displayCategory->name }} Main Image
@endif

Request a Quote

@include('categories.inquire-form')

@if($displayCategory->parent_id) Related {{ $displayCategory->parent->name }} Options @else Related {{ $displayCategory->name }} Options @endif

    @if($displayCategory->parent_id) @if($siblings->isNotEmpty()) @foreach($siblings as $sibling)
  • {{ $sibling->name }} Thumbnail
    {{ $sibling->name }}

    {{ \Illuminate\Support\Str::limit(strip_tags($sibling->description), 100) }}

    Book Now
  • @endforeach @else

    No sub-categories available for {{ $displayCategory->parent->name }}.

    @endif @else @if($displayCategory->children->where('active', 1)->isNotEmpty()) @foreach($displayCategory->children->where('active', 1) as $child)
  • {{ $child->name }} Thumbnail
    {{ $child->name }}

    {{ \Illuminate\Support\Str::limit(strip_tags($child->description), 100) }}

    Book Now
  • @endforeach @else

    No related options available for {{ $displayCategory->name }}.

    @endif @endif

Venues

@if($subSubCategoriesForVenues->isNotEmpty()) @php // Group sub-sub-categories by their parent (Level 2) sub-category $groupedVenues = $subSubCategoriesForVenues->groupBy('parent_id'); @endphp @if($groupedVenues->isNotEmpty())
    @foreach($groupedVenues as $parentId => $venues) @php $parentCategory = \App\Models\Category::find($parentId); if (!$parentCategory) continue; // Skip if parent not found @endphp
  • {{ $parentCategory->name }} Thumbnail
    {{ $parentCategory->name }}

    {{ \Illuminate\Support\Str::limit(strip_tags($parentCategory->description), 100) }}

    @foreach($venues as $subSubCategory)
    {{ $subSubCategory->name }} Thumbnail
    {{ $subSubCategory->name }}

    {{ \Illuminate\Support\Str::limit(strip_tags($subSubCategory->description), 80) }}

    Book Now
    @endforeach
  • @endforeach
@else

No venues available.

@endif @else

No venues available.

@endif

All Categories

    @php $parentCategories = \App\Models\Category::whereNull('parent_id') ->where('active', 1) ->get(); $previewCategories = $parentCategories->take(5); $remainingCategories = $parentCategories->slice(5); @endphp @if($previewCategories->isNotEmpty()) @foreach($previewCategories as $parent)
  • {{ $parent->name }} Thumbnail
    {{ $parent->name }}

    {{ \Illuminate\Support\Str::limit(strip_tags($parent->description), 100) }}

    Book Now
  • @endforeach @endif
    @if($remainingCategories->isNotEmpty()) @foreach($remainingCategories as $parent)
  • {{ $parent->name }} Thumbnail
    {{ $parent->name }}

    {{ \Illuminate\Support\Str::limit(strip_tags($parent->description), 100) }}

    Book Now
  • @endforeach @endif
    @if($remainingCategories->isNotEmpty())
    @endif
@else

Category Unavailable

The requested category and its related categories are currently unavailable. Please explore other services.

Return to Home
@endif @endsection