@php $version = $basicInfo->theme_version; @endphp @extends('frontend.layout') @section('pageHeading') {{ __('Home') }} @endsection @section('metaKeywords') @if (!empty($seoInfo)) {{ $seoInfo->meta_keyword_home }} @endif @endsection @section('metaDescription') @if (!empty($seoInfo)) {{ $seoInfo->meta_description_home }} @endif @endsection @section('content')
@if (count($after_hero) > 0) @foreach ($after_hero as $cusHero) @if (isset($homecusSec[$cusHero->id])) @if ($homecusSec[$cusHero->id] == 1) @php $cusHeroContent = App\Models\CustomSectionContent::where('custom_section_id', $cusHero->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusHeroContent]) @endif @endif @endforeach @endif @if ($secInfo->category_section_status == 1)

{{ !empty($sectionContent->category_section_title) ? $sectionContent->category_section_title : 'Most Popular Categories' }}

@if (count($categories) == 0)

{{ __('NO CATEGORIES FOUND') }}!

@else
@foreach ($categories as $category)

{{ $category->name }}

@if ($category->service_count > 1) {{ $category->service_count }} {{ __('Services Available') }} @elseif($category->service_count == 1) {{ $category->service_count }} {{ __('Service Available') }} @endif
@endforeach
@endif
@endif @if (count($after_category) > 0) @foreach ($after_category as $cusCategory) @if (isset($homecusSec[$cusCategory->id])) @if ($homecusSec[$cusCategory->id] == 1) @php $cusCategoryContent = App\Models\CustomSectionContent::where('custom_section_id', $cusCategory->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusCategoryContent]) @endif @endif @endforeach @endif @if ($secInfo->work_process_section_status == 1)

{{ !empty($sectionContent->workprocess_section_title) ? $sectionContent->workprocess_section_title : 'How the Appointment Booking System Works ' }}

@foreach ($processes as $processe)
Image

{{ $processe->title }}

0{{ $loop->iteration }}
@endforeach
@endif @if (count($after_work_process) > 0) @foreach ($after_work_process as $work_process) @if (isset($homecusSec[$work_process->id])) @if ($homecusSec[$work_process->id] == 1) @php $work_processContent = App\Models\CustomSectionContent::where('custom_section_id', $work_process->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $work_processContent]) @endif @endif @endforeach @endif @if ($secInfo->feature_section_status == 1)

{{ !empty($sectionContent->featured_service_section_title) ? $sectionContent->featured_service_section_title : 'Our Top Featured Services' }}

@if ($featured_services->count() > 4)
@endif
@if ($featured_services->count() == 0)

{{ __('NO SERVICE FOUND') . '!' }}

@else
@foreach ($featured_services as $service)
Service
{{ $service->categoryName }} @if (Auth::guard('web')->check()) @php $user_id = Auth::guard('web')->user()->id; $checkWishList = checkWishList($service->id, $user_id); @endphp @else @php $checkWishList = false; @endphp @endif
{{ truncateString($service->name, 60) }}
@if ($service->vendor_id != 0) @if ($service->vendor->photo != null) Image @else Vendor @endif {{ __('By') }} {{ $service->vendor->username }} @else Vendor {{ __('By') }} {{ $admin->username }} @endif
@if (!empty($service->address)) {{ truncateString($service->address, 30) }} @endif @if ($service->zoom_meeting == 1) {{ __('Online') }} @endif
{{ symbolPrice($service->price) }} {{ $service->prev_price ? symbolPrice($service->prev_price) : '' }}
{{ __('Book Now') }}
@endforeach
@endif
@endif @if (count($after_featured_service) > 0) @foreach ($after_featured_service as $cusFeature) @if (isset($homecusSec[$cusFeature->id])) @if ($homecusSec[$cusFeature->id] == 1) @php $cusFeatureContent = App\Models\CustomSectionContent::where('custom_section_id', $cusFeature->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusFeatureContent]) @endif @endif @endforeach @endif @if ($secInfo->banner_section == 1) @endif @if (count($after_banner) > 0) @foreach ($after_banner as $cusBanner) @if (isset($homecusSec[$cusBanner->id])) @if ($homecusSec[$cusBanner->id] == 1) @php $cusBannerContent = App\Models\CustomSectionContent::where('custom_section_id', $cusBanner->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusBannerContent]) @endif @endif @endforeach @endif @if ($secInfo->latest_service_section_status == 1)

{{ !empty($sectionContent->featured_service_section_title) ? $sectionContent->featured_service_section_title : 'Most Popular Booking Services We Offer' }}

@if (count($categories) > 0)
@endif
@if (count($services) == 0)

{{ __('NO SERVICE FOUND') }}!

@else
@foreach ($services as $service)
Service
{{ $service->categoryName }} @if (Auth::guard('web')->check()) @php $user_id = Auth::guard('web')->user()->id; $checkWishList = checkWishList($service->id, $user_id); @endphp @else @php $checkWishList = false; @endphp @endif
{{ truncateString($service->name, 60) }}
@if ($service->vendor_id != 0) @if ($service->vendor->photo != null) Image @else Vendor @endif {{ __('By') }} {{ $service->vendor->username }} @else Image {{ __('By') }} {{ $admin->username }} @endif
@if (!empty($service->address)) {{ truncateString($service->address, 30) }} @endif @if ($service->zoom_meeting == 1) {{ __('Online') }} @endif
{{ symbolPrice($service->price) }} {{ $service->prev_price ? symbolPrice($service->prev_price) : '' }}
{{ __('Book Now') }}
@endforeach
@foreach ($categories as $category) @php $vendorStatus = App\Models\Vendor::where('status', 1)->select('id')->get()->toArray(); $services = App\Models\Services\Services::join( 'service_contents', 'service_contents.service_id', '=', 'services.id', ) ->join('service_categories', 'service_categories.id', '=', 'service_contents.category_id') ->where('service_contents.language_id', $language->id) ->where('service_categories.language_id', $language->id) ->where('service_contents.category_id', $category->id) ->where(function ($query) use ($vendorStatus) { $query->whereIn('services.vendor_id', $vendorStatus)->orWhere('services.vendor_id', 0); }) ->when('services.vendor_id' != '0', function ($query) { return $query ->leftJoin('memberships', 'services.vendor_id', '=', 'memberships.vendor_id') ->where(function ($query) { $query ->where([ ['memberships.status', '=', 1], ['memberships.start_date', '<=', now()->format('Y-m-d')], ['memberships.expire_date', '>=', now()->format('Y-m-d')], ]) ->orWhere('services.vendor_id', '=', 0); }); }) ->select( 'services.*', 'service_contents.name', 'service_contents.address', 'service_contents.slug', ) ->paginate(8); @endphp @if (count($services) > 0)
@foreach ($services as $service)
Service
{{ $category->name }} @if (Auth::guard('web')->check()) @php $user_id = Auth::guard('web')->user()->id; $checkWishList = checkWishList($service->id, $user_id); @endphp @else @php $checkWishList = false; @endphp @endif
{{ truncateString($service->name, 60) }}
@if ($service->vendor_id != 0) @if ($service->vendor->photo) Image @else Vendor @endif {{ __('By') }} {{ $service->vendor->username }} @else Image {{ __('By') }} {{ $admin->username }} @endif
@if (!empty($service->address)) {{ truncateString($service->address, 30) }} @endif @if ($service->zoom_meeting == 1) {{ __('Online') }} @endif
{{ symbolPrice($service->price) }} {{ $service->prev_price ? symbolPrice($service->prev_price) : '' }}
{{ __('Book Now') }}
@endforeach
@endif @endforeach
@endif
@endif @if (count($after_latest_service) > 0) @foreach ($after_latest_service as $cusLatestServie) @if (isset($homecusSec[$cusLatestServie->id])) @if ($homecusSec[$cusLatestServie->id] == 1) @php $cusLatestServieContent = App\Models\CustomSectionContent::where('custom_section_id', $cusLatestServie->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusLatestServieContent]) @endif @endif @endforeach @endif @if ($secInfo->call_to_action_section_status == 1)

{{ !empty($sectionContent->call_to_action_section_title) ? $sectionContent->call_to_action_section_title : 'Now Get 50% Discount For First Booking' }}

{{ !empty($sectionContent->action_section_text) ? $sectionContent->action_section_text : 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim' }}

@if (!empty($sectionContent->call_to_action_url)) @endif
@endif @if (count($after_call_to_action) > 0) @foreach ($after_call_to_action as $cusAction) @if (isset($homecusSec[$cusAction->id])) @if ($homecusSec[$cusAction->id] == 1) @php $cusActionContent = App\Models\CustomSectionContent::where('custom_section_id', $cusAction->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusActionContent]) @endif @endif @endforeach @endif @if ($secInfo->vendor_featured_section_status == 1)

{{ !empty($sectionContent->vendor_section_title) ? $sectionContent->vendor_section_title : 'Our Top Featured Vendor' }}

@if ($vendors > 0) @if ($vendors > 1) {{ __('View All Vendors') }} @else {{ __('View All Vendor') }} @endif @endif
@if ($featuredVendors->count() == 0)

{{ __('NO VENDOR FOUND') . '!' }}

@else
@foreach ($featuredVendors as $vendor)
@if ($vendor->photo) Vendor @else Vendor @endif
@php $vendorInfo = App\Models\VendorInfo::where([ ['vendor_id', $vendor->vendorId], ['language_id', $language->id], ])->first(); @endphp
@if ($vendorInfo->name != null) {{ $vendorInfo->name }} @else {{ $vendor->username }} @endif
@if ($vendorInfo) @if ($vendorInfo->address != null) {{ truncateString($vendorInfo->address, 30) }} @endif @endif
{{ __('Visit Store') }} @php $total_service = App\Models\Services\Services::where('vendor_id', $vendor->vendorId) ->where('status', 1) ->count(); @endphp @if ($vendor->total_service > 1) {{ $vendor->total_service }} {{ __('Services Available') }} @elseif($vendor->total_service == 1) {{ $vendor->total_service }} {{ __('Services Available') }} @else {{ __('No Service Available') }} @endif
@endforeach
@endif
@endif @if (count($after_vendor) > 0) @foreach ($after_vendor as $cusVendor) @if (isset($homecusSec[$cusVendor->id])) @if ($homecusSec[$cusVendor->id] == 1) @php $cusVendorContent = App\Models\CustomSectionContent::where('custom_section_id', $cusVendor->id) ->where('language_id', $currentLanguageInfo->id) ->first(); @endphp @include('frontend.home.custom-section', ['data' => $cusVendorContent]) @endif @endif @endforeach @endif @endsection @section('script') @endsection