@extends('layouts.guest') @section('title', $business->name) @section('content')

0

{{$business->name}}

{{$business_location->name}}

{!! $business_location->location_address !!}

@foreach($products as $product_category)
@foreach($product_category as $product) @if($product->qty_available>0)
@php $discount = $discounts->firstWhere('brand_id', $product->brand_id); if(empty($discount)){ $discount = $discounts->firstWhere('category_id', $product->category_id); } @endphp @if(!empty($discount)) - {{@num_format($discount->discount_amount)}}% @endif @php $max_price = $product->variations->max('sell_price_inc_tax'); $min_price = $product->variations->min('sell_price_inc_tax'); $price_group_id=request()->get('price_group'); if($price_group_id > 0){ $min_price=$max_price = \DB::table('variation_group_prices')->where('price_group_id',$price_group_id)->where('variation_id',$product->variations[0]->id)->sum('price_inc_tax'); if($min_price==0){ $min_price=$max_price=$product->variations->min('sell_price_inc_tax'); } } @endphp

{{$product->name}}

@if($product->type == 'variable') @php $variations = $product->variations->groupBy('product_variation_id'); @endphp @foreach($variations as $product_variation) @endforeach @else @endif
@lang('lang_v1.price'): {{number_format($max_price, 2, '.', ' ')}} @if($max_price !== $min_price) - {{number_format($min_price, 2, '.', ' ')}} @endif
@lang('product.sku'): {{$product->sku}}
{{$product_variation->first()->product_variation->name}}:
@if($loop->iteration%4 == 0)
@endif @endif @endforeach
@endforeach
@stop @section('javascript') @endsection