@guest
LOGIN
/
REGISTER
@else
Welcome {{ Auth::User()->name }}
My Account
My Account
My Orders
My Reward Points
Wishlist
@csrf
Logout
@endguest
{{-- part of Header with logo --}}
{{-- logo part --}}
{{-- search and cart --}}
{{-- search main --}}
{{--
--}}
My cart
@php $cart = 0; if (Auth::guard('customer')->check()) { $user_id = Auth::guard('customer')->user()->id; $cart = DB::table('user_carts') ->where('user_id', $user_id) ->count(); } @endphp {{ $cart }}
item(s)
{{-- Shopping Cart --}}
{{-- Part of header with categories --}}
All Brands
Brands
Categories
Categories
...
@php $brands = DB::table('brands') ->where('status', '1') ->get(); @endphp @foreach ($brands as $brand)
{{ $brand->name }}
@php $cars = DB::table('cars') ->where('status', '1') ->where('brand_id', $brand->id) ->get(); @endphp @foreach ($cars as $car)
{{ $car->name }}
@endforeach
@endforeach
Categories
Car Part
@php $sub_cats = DB::table('sub_cat') ->where('status', '1') ->get(); @endphp @foreach ($sub_cats as $sub_cat)
{{ $sub_cat->sub_title }}
@endforeach
@php $cats = DB::table('cats') ->where('status', '1') ->limit(4) ->get(); @endphp @foreach ($cats as $cat)
{{ $cat->title }}
@endforeach
d