@extends('layout.frontend.master') @php use App\Models\Area; use App\Models\Timeslot; $title = (app()->currentLocale()=='en')?$product->name_en:$product->name_ar; $gallery = ($product->gallery)?explode(',', $product->gallery):''; $weights = json_decode($product->measurements, true); $price = json_decode($product->price, true); $sale_price = json_decode($product->sale_price, true); $quantity = json_decode($product->quantity, true); $dbranch = ''; foreach($pickups as $pickup){ if(session('sel-branch') && session('sel-branch')==$pickup->id){ $bname = $pickup->name; } } if(session('sel-area')){ $selarea = Area::find(session('sel-area')); $selareaname = (app()->currentLocale()=='en')?$selarea->name_en:$selarea->name_ar; } if(session('sel-slot')){ $selslot = Timeslot::find(session('sel-slot')); } @endphp @section('meta-title', 'LEREVE - '.$title) @push('asset-top') @endpush @section('content')

{{$title}}

{!! app()->currentLocale()=='en'?substr($product->description_en, 0,20):substr($product->description_ar, 0,20) !!}

{{-- @if($sale_price[$weights[0]]) @else @endif --}} @if($sale_price[$weights[0]]&&$sale_price[$weights[0]] < $price[$weights[0]])
{{$sale_price[$weights[0]]}} KWD{{$price[$weights[0]]}} KWD
@else
{{$price[$weights[0]]}} KWD
@endif {{--
{{$price[$weights[0]]}} {{__('KWD')}}
--}}
{{(app()->getLocale() == 'en') ? ($quantity[$weights[0]] > 0 ? __('Stock') : __('Out of Stock')) : ($quantity[$weights[0]] > 0 ? __('المخزون') : __('غير متوفر في المخزون'))}}
@csrf

{{ app()->currentLocale() == 'en' ? $category->name_en : $category->name_ar}} {{__('Weight')}}

@error('weight')
{{$message}}
@enderror

{!! app()->currentLocale()=='en'?$product->description_en:$product->description_ar !!}

{{__('You Might Also Like')}}

@foreach($recommended as $product) @if($product->dsale_price) @php $percent = (($product->dprice-$product->dsale_price)/$product->dprice) * 100; $percent = ceil($percent); @endphp @endif @php $percent = (($product->dprice-$product->dsale_price)/$product->dprice) * 100; $percent = ceil($percent); $weights = json_decode($product->measurements, true); @endphp
@if($percent)
{{$percent}}% {{__('OFF')}}
@endif product

{{ (app()->getlocale()=='en') ? $product->name_en : $product->name_ar }}

@if($product->dsale_price < $product->dprice)
{{$product->dsale_price}} {{__('KWD')}} {{$product->dprice}} {{__('KWD')}}
@else
{{$product->dprice}} {{__('KWD')}}
@endif {{--
@if(count($weights)>1) {{__('Select Options')}} @else {{__('Add To Cart')}} @endif
--}}
@endforeach

{{__('Keep Browsing')}}

@if(Auth::check())

{{__('Rate this ')}}{{(app()->currentLocale()=='en')?$product->name_en:$product->name_ar}}

@csrf
@endif
@endsection @push('asset-bottom') @endpush