@extends('layouts.app') @section('title', $product->name) @section('subtitle', 'Product Details') @section('content')

{{ $product->name }}

Product details and management

@if($product->isRejected() && $product->rejection_reason)

Rejection Reason

{{ $product->rejection_reason }}

@endif

Product Images

Click on images to view larger version

@if($product->images && count($product->images) > 0)
@foreach($product->getImageUrls() as $index => $imageUrl)
{{ $product->name }} - Image {{ $index + 1 }} @if(count($product->images) > 1)
@csrf @method('DELETE')
@endif
Image {{ $index + 1 }}
@endforeach

{{ count($product->images) }} image(s) total @if(count($product->images) === 1) (Minimum 1 image required) @endif

@else

No images

This product doesn't have any images yet.

@endif

Add More Images

@csrf @method('PUT')

Select additional images to add to this product

Product Information

{{ ucfirst($product->status) }} @if($product->submitted_at) Submitted: {{ $product->submitted_at->format('M j, Y g:i A') }} @endif

${{ number_format($product->price, 2) }}

{{ $product->quantity }} units

{{ $product->category }}

{{ $product->description }}

{{ $product->created_at->format('M j, Y g:i A') }}

{{ $product->updated_at->format('M j, Y g:i A') }}

@if($product->isDraft())
@csrf
@endif @if($product->isRejected())
@csrf
@endif
@csrf @method('DELETE')
@endsection