@extends('frontend.layouts.app') @section('content')
{{ translate('Categories') }} {{ translate('See All') }} >
@php $num_todays_deal = count(filter_products(\App\Product::where('published', 1)->where('todays_deal', 1 ))->get()); $featured_categories = \App\Category::where(['featured'=>1, 'status'=>1])->get(); @endphp
@if (count($featured_categories) > 0) @endif
@if($num_todays_deal > 0) @endif
@foreach (\App\Banner::where('position', 1)->where('published', 1)->orderBy('ordering', 'desc')->get() as $key => $banner) @endforeach
@php $flash_deal = \App\FlashDeal::where('status', 1)->where('featured', 1)->first(); @endphp @if($flash_deal != null && strtotime(date('d-m-Y')) >= $flash_deal->start_date && strtotime(date('d-m-Y')) <= $flash_deal->end_date)

{{ translate('Flash Sale') }}

@endif
@if(\App\BusinessSetting::where('type', 'classified_product')->first()->value == 1) @php $customer_products = \App\CustomerProduct::where('status', '1')->where('published', '1')->take(10)->get(); @endphp @if (count($customer_products) > 0)

{{ translate('Classified Ads') }}

@endif @endif @if (\App\BusinessSetting::where('type', 'vendor_system_activation')->first()->value == 1)
@endif @if(count(\App\Category::where('top', 1)->get()) != null && count(\App\Brand::where('top', 1)->get()) != null)

{{translate('Top 10 Catogories')}}

@foreach (\App\Category::where('top', 1)->get() as $category) @endforeach

{{translate('Top 10 Brands')}}

@foreach (\App\Brand::where('top', 1)->get() as $brand) @endforeach
@endif @endsection @section('script') @endsection