@extends('front.layout.app') @section('content') @if (count($product->productGalleryImages()) > 0) @forelse($product->productGalleryImages() as $galleryImg) @empty @endforelse @endif @if (count($product->productGalleryImages()) > 0) @forelse($product->productGalleryImages() as $galleryImg) @empty @endforelse @else Sorry! No gallery available. @endif {{ $product->brand ?? '' }} {{ $product->strainType->name ?? '' }} {{ $product->name }} $ {{ $product->price ?? '' }} {{-- Up to 40% off --}} @csrf {{-- @if ($product->variation()->count() > 0) Size @php $addedSizes = []; @endphp Select size @forelse($product->variation() as $variation) @if ($variation->size() && !in_array($variation->size()->id, $addedSizes)) {{ $variation->size()->name }} @php $addedSizes[] = $variation->size()->id; @endphp @endif @empty No sizes available @endforelse @endif --}} {{-- @if ($product->variation()->count() > 0) --}} @if ($product->variations()->count() > 0) Size @php $addedSizes = []; @endphp Select size @forelse($product->variations as $variation) @php $isCustom = is_null($variation->size_id); $sizeIdentifier = $isCustom ? $variation->custom_size : $variation->size?->id; $sizeLabel = $isCustom ? $variation->custom_size : $variation->size?->name; @endphp @if ($sizeIdentifier && !in_array($sizeIdentifier, $addedSizes)) {{-- {{ $sizeLabel }} --}} {{ $sizeLabel }} @php $addedSizes[] = $sizeIdentifier; @endphp @endif @empty No sizes available @endforelse @endif {{-- @if ($product->variations()->count() > 0) Color @php $addedColors = []; @endphp Select color @foreach($product->variations as $variation) @php $isCustomColor = is_null($variation->variation_color_id); $colorIdentifier = $isCustomColor ? $variation->custom_color : $variation->variation_color_id; $colorLabel = $isCustomColor ? $variation->custom_color : ($variation->variationColor->name ?? 'Unknown'); // Get image URL for this variation or fallback to product image $imageUrl = $variation->getFirstMediaUrl('variation_image') ?: $product->productImage(); // Check to avoid duplicate color options $alreadyAdded = in_array($colorIdentifier, $addedColors); @endphp @if ($colorIdentifier && !$alreadyAdded) {{ $colorLabel }} @php $addedColors[] = $colorIdentifier; @endphp @endif @endforeach @endif --}} Select Your State Select a state @foreach($states as $state) {{ $state->name }} @endforeach @if ($product->stock_quantity > 0) Quantity - {{-- stock_quantity > 0 ? '' : 'disabled' }} data-productStock="{{ $product->stock_quantity }}" name="quantity" id="quantity" value="1"> --}} + @endif @if (!auth()->check()) @elseif($product->stock_quantity == 0) Out Of Stock @endif Selected quantity exceeds available stock. {{-- Add to cart --}} external_link) ? 'data-external-link=' . $product->external_link : '' }} {{ !empty($product->external_link) ? '' : 'disabled' }}> Add to cart @if (!auth()->check()) @endif {{-- Build a bundle Up to 40% off Cresco, High Supply & FloraCal --}} {{-- Total THC{{ $product->thc_percentage ?? '0' }}% Visit Shop Total combined THC/THCa, CBD/CBDa values. Review product labels for exact percentages. @if (isset($product->thc_percentage) && !is_null($product->thc_percentage)) THC{{ $product->thc_percentage ?? '0' }}% @endif @if (isset($product->thca_percentage) && !is_null($product->thca_percentage)) THCA{{ $product->thca_percentage ?? '0' }}% @endif @if (isset($product->cbd_percentage) && !is_null($product->cbd_percentage)) CBD{{ $product->cbd_percentage ?? '0' }}% @endif @if (isset($product->cbda_percentage) && !is_null($product->cbda_percentage)) CBDa{{ $product->cbda_percentage ?? '0' }}% @endif --}} {{-- About this Strain Terpenes @foreach ($product->terpenes as $terpen) {{ $terpen->name }} @endforeach --}} Product Details {!! $product->description ?? '' !!} Form {{ $product->Category->name ?? '' }} Related Products @forelse($related_product as $related_product) {{ $related_product->Category->name ?? '' }} {{ $related_product->name ?? '' }} ${{ $related_product->price ?? '' }} THC: {{ $related_product->thc_percentage ?? '0' }}% @empty No related products found! @endforelse Other Ways to Enjoy This Strain @forelse($related_product_strain as $strain_product) {{ $strain_product->Category->name ?? '' }} {{ $strain_product->name ?? '' }} ${{ $strain_product->price ?? '' }} THC: {{ $strain_product->thc_percentage ?? '0' }}% @empty No strain related products found! @endforelse @endsection @section('script') @endsection
Sorry! No gallery available.
Selected quantity exceeds available stock.
Total combined THC/THCa, CBD/CBDa values. Review product labels for exact percentages.
{!! $product->description ?? '' !!}
No related products found!
No strain related products found!