@extends('layouts.app') @section('title', $product->name . ' - ' . config('app.name')) @section('content')
{{ $product->name }}

{{ $product->brand?->name ?? 'Unknown Brand' }}

{{ $product->name }}

SKU: {{ $product->sku }}

(42 reviews)

{{ \App\Support\Currency::symbol() }}{{ number_format($product->price, 2) }}

@if($product->isOnSale()) {{ \App\Support\Currency::symbol() }}{{ number_format($product->compare_at_price, 2) }} Save {{ $product->discount_percent }}% @endif
@if($product->inventory && $product->inventory->quantity > 0) In Stock {{ $product->inventory->quantity }} items available @else Out of Stock @endif
@if($product->description)
Description

{{ $product->description }}

@endif @if($product->inventory && $product->inventory->quantity > 0)
@csrf
@else @endif
Product Code

{{ $product->product_code ?? 'N/A' }}

Availability

{{ $product->created_at->format('M d, Y') }}

@if($relatedProducts->count() > 0)

Related Products

@foreach($relatedProducts->take(4) as $related)
{{ $related->name }}
{{ Str::limit($related->name, 30) }}

{{ \App\Support\Currency::symbol() }}{{ number_format($related->price, 2) }}

@endforeach
@endif
@endsection