@extends('digitalmenu::layouts.public') @section('title', ($product->name ?? 'Item') . ' — ' . ($shop->name ?? 'Shop')) @section('header-left') arrow_back @endsection @section('content')
@php $galleries = $product->productGalleries ?? collect(); $hasGallery = $galleries->count() > 0; $allImages = collect(array_merge([$product->picture_url], $galleries->pluck('picture_url')->toArray())); $discountPrice = $product->is_discount ? $product->getDiscountPrice($product->unit_price) : false; @endphp @if($hasGallery)
@foreach($allImages as $i => $imgSrc) @endforeach
@endif

{{ $product->name }}

@if($discountPrice !== false)
{{ $currencySymbol }}{{ number_format($discountPrice, 2) }} {{ $currencySymbol }}{{ number_format($product->unit_price, 2) }}
@else {{ $currencySymbol }}{{ number_format($product->unit_price, 2) }} @endif
@if(!empty($product->description) || !empty($product->short_description))

{!! nl2br(e($product->description ?: $product->short_description)) !!}

@endif
@if(!empty($categoryName))
category

Category

{{ $categoryName }}

@endif @if(!empty($product->sku))
qr_code

SKU

{{ $product->sku }}

@endif
@if($related->count() > 0)

You May Also Like

@endif
@endsection @section('scripts') @if($hasGallery) @endif @endsection