@extends('layouts.shop') @section('title', $product->meta_title ?? $product->name) @section('meta_description', $product->meta_description ?? \Illuminate\Support\Str::limit(strip_tags($product->short_description), 160)) @section('meta_keywords', $product->meta_keywords ?? '') @push('schema_markup') @if($product->schema_markup) {!! $product->schema_markup !!} @endif @endpush @section('content')
{{ $product->name }}
@if($product->images->count() > 1)
@foreach($product->images->sortBy('sort_order') as $image) @php $thumbPath = $image->image_path; @endphp @endforeach
@endif

{{ $product->name }}

@php $avgRating = $product->publishedReviews->avg('rating'); $reviewCount = $product->publishedReviews->count(); @endphp
@for($i = 1; $i <= 5; $i++) @endfor

{{ number_format($avgRating, 1) }} out of 5 stars

{{ $reviewCount }} reviews

Product information

Number of Units: {{ $product->number_of_units ?? 1 }} {{ $product->unit_type }}

Description

{!! $product->short_description !!}
@csrf @if($product->variations->count() > 0)

Select Option

    @foreach($product->variations as $variation)
  • @foreach($variation->options as $option) {{ $option->attribute_value }} @if(!$loop->last) / @endif @endforeach
    ₹{{ number_format($variation->sp, 0) }} @if($variation->stock <= 0) Sold Out @endif
  • @endforeach

@endif
Fast Shipping
Best Price
Secure Payment

Additional details

@if($product->long_description)

{!! $product->long_description !!}
@endif @if($product->warranty_details)

{!! $product->warranty_details !!}
@endif

@if($product->is_returnable)

Returnable within {{ $product->return_window_days ?? $settings->return_window_days ?? 7 }} days of delivery.

@if($product->return_policy_desc)

{!! nl2br(e($product->return_policy_desc)) !!}

@else

This product is eligible for returns under our general return policy conditions.

@endif @else

This product is not eligible for returns.

@endif

@if($product->publishedReviews->count() > 0)
@foreach($product->publishedReviews as $review)

{{ $review->user->name ?? 'Anonymous' }}

{{ $review->created_at->format('M d, Y') }}
@for($i = 1; $i <= 5; $i++) @endfor
@if($review->comment)

{{ $review->comment }}

@endif
@endforeach
@else

No reviews yet.

@endif
@if(isset($upsellProducts) && $upsellProducts->count() > 0)

You may also like

@foreach($upsellProducts as $relatedProduct)
@php $rMainImage = $relatedProduct->images->sortBy('sort_order')->first(); if ($rMainImage) { $rImagePath = $rMainImage->image_path; } else { $rVariationImage = $relatedProduct->variations->whereNotNull('image_path')->sortBy('sort_order')->first(); $rImagePath = $rVariationImage ? $rVariationImage->image_path : 'https://placehold.co/600x600?text=No+Image'; } @endphp {{ $relatedProduct->name }}

{{ $relatedProduct->name }}

@if($relatedProduct->variations->count() > 0) ₹{{ number_format($relatedProduct->variations->min('sp'), 2) }} @else N/A @endif

View details for {{ $relatedProduct->name }}
@endforeach
@endif
@endsection