@extends('storefront.layout') @section('title', $product->title . ' — Wholesale') @section('description', 'View current wholesale pricing and availability for ' . $product->title . '.') @push('head') @php $galleryUrls = collect($product->images ?? [])->pluck('src')->filter()->values(); @endphp @foreach ($galleryUrls as $imgUrl) @endforeach @endpush @section('content') @php $catalogPricePresenter = new \App\Services\Catalog\CatalogPricePresenter($priceResolver); $catalogStockPresenter = new \App\Services\Catalog\CatalogStockPresenter($stockResolver); @endphp
{{-- Gallery --}}
{{-- Main image + arrows wrapper --}}
{{-- Image container --}}
{{-- Prev / Next arrows — outside overflow-hidden, straddling the edge --}}
{{-- Thumbnail strip --}} @if ($colorVariants->isNotEmpty())

Available colors

See the other colors available for this product.

@foreach ($colorVariants as $variantProduct) {{ $variantProduct->title }} @endforeach
@endif {{-- Lightbox --}}
{{-- Info --}}
{{ $product->vendor ?? 'Vida Mansa' }}

{{ $product->title }}

@if ($product->product_type)
{{ $product->product_type }}
@endif
Factory-Direct Wholesale ${{ number_format($minimumOrder, 0) }} Minimum Order Free Shipping
@php $sortedVariants = $product->variants->sortBy('position'); $allVariantsOutOfStock = $sortedVariants->isNotEmpty() && $sortedVariants->every(fn ($variant): bool => $stockResolver->statusFor($variant) === \App\Enums\StockStatus::OutOfStock); @endphp @if ($allVariantsOutOfStock)

Out of stock

Unfortunately, all items have been sold.

This product is currently unavailable. Please return to the catalog and choose another item for your order.

Back to catalog
@else @foreach ($sortedVariants as $v) @php try { $price = $priceResolver->priceFor($v, $customer); $msrp = $priceResolver->compareAtFor($v, $customer); $grossMargin = $priceResolver->grossMarginFor($v, $customer); } catch (\App\Exceptions\WholesalePriceUnavailable) { $price = null; $msrp = null; $grossMargin = null; } $stock = $stockResolver->statusFor($v); $hasPrice = $price !== null; $isAvailable = $hasPrice && $stock !== \App\Enums\StockStatus::OutOfStock; @endphp
@csrf

Wholesale price

@if ($hasPrice) ${{ number_format($price, 2) }} @else Temporarily unavailable @endif
@if ($msrp !== null)
MSRP
${{ number_format($msrp, 2) }}
@if ($grossMargin !== null)
Gross margin
{{ $grossMargin }}%
@endif
@endif

SKU {{ $v->sku ?? 'N/A' }}

Availability

{{ $stock->label() }}
@endforeach @endif
@if ($product->body_html)
{!! $sanitizedDescription !!}
@endif
@if ($related->isNotEmpty())

More from {{ $product->vendor ?? 'this brand' }}

@foreach ($related as $r) @php $relatedPrice = $catalogPricePresenter->forProduct($r, $customer); $relatedStock = $catalogStockPresenter->forProduct($r); @endphp
@if ($r->image_url) {{ $r->title }} @endif @if ($relatedStock) {{ $relatedStock->label() }} @endif
{{ $r->vendor }}
{{ $r->title }}
{{ $relatedPrice?->from() ?? 'Price unavailable' }}
@endforeach
@endif

Keep building your Vida Mansa order.

Compare the full line, see current wholesale pricing, and reach the ${{ number_format($minimumOrder, 0) }} order minimum.

Free Shipping Across the U.S.

@endsection