{{ __('Product categories') }}

    @foreach (App\Models\Category::where('status', 1)->get() as $category)
  • {{ $category->name }} @if($category->subs->count() > 0)
      @foreach (App\Models\Subcategory::where('category_id', $category->id)->get() as $subcategory)
    • {{$subcategory->name}} @if($subcategory->childs->count() != 0)
        @foreach (DB::table('childcategories')->where('subcategory_id', $subcategory->id)->get() as $key => $childelement)
      • {{$childelement->name}}
      • @endforeach
      @endif
    • @endforeach
    @endif
  • @endforeach

{{ __('Filter by Price') }}

    {{ __('To') }}
@if ((!empty($cat) && !empty(json_decode($cat->attributes, true))) || (!empty($subcat) && !empty(json_decode($subcat->attributes, true))) || (!empty($childcat) && !empty(json_decode($childcat->attributes, true))))
@if (!empty($cat) && !empty(json_decode($cat->attributes, true))) @foreach ($cat->attributes as $key => $attr)

{{$attr->name}}

    @if (!empty($attr->attribute_options)) @foreach ($attr->attribute_options as $key => $option)
    @endforeach @endif
@endforeach @endif @if (!empty($subcat) && !empty(json_decode($subcat->attributes, true))) @foreach ($subcat->attributes as $key => $attr)

{{$attr->name}}

    @if (!empty($attr->attribute_options)) @foreach ($attr->attribute_options as $key => $option)
    @endforeach @endif
@endforeach @endif @if (!empty($childcat) && !empty(json_decode($childcat->attributes, true))) @foreach ($childcat->attributes as $key => $attr)

{{$attr->name}}

    @if (!empty($attr->attribute_options)) @foreach ($attr->attribute_options as $key => $option)
    @endforeach @endif
@endforeach @endif
@endif
{{ __('Recent Product') }}
@foreach (array_chunk($latest_products->toArray(), 3) as $item)
@foreach ($item as $prod)
Product Image
{{ __('Quick View') }}
{{ __('Wishlist') }}

{{ App\Models\Product::whereId($prod['id'])->first()->showName() }}

{{ App\Models\Product::whereId($prod['id'])->first()->showPrice() }} {{ App\Models\Product::whereId($prod['id'])->first()->showPreviousPrice() }}
{{ round(App\Models\Product::whereId($prod['id'])->first()->offPercentage())}}% off

{{ App\Models\Rating::ratings($prod['id']) }}

({{ App\Models\Rating::ratingCount($prod['id']) }})

@endforeach
@endforeach