@extends('layouts.admin') @section('page-title', 'Order #' . $order->order_number) @section('content')
| Product | Warehouse | Fulfillment | Qty | Price | Subtotal |
|---|---|---|---|---|---|
| {{ $item->product_name ?? ($item->product?->name ?? 'Deleted') }} | @if(($item->warehouse ?? 'ghana') === 'china') 🇨🇳 China @else 🇬🇭 Ghana @endif |
@php
$fStatus = $item->fulfillment_status ?? 'pending';
$fBadge = match($fStatus) {
'pending' => 'bg-gray-100 text-gray-600',
'in_transit' => 'bg-blue-100 text-blue-700',
'arrived' => 'bg-amber-100 text-amber-700',
'shipped' => 'bg-purple-100 text-purple-700',
'delivered' => 'bg-green-100 text-green-700',
default => 'bg-gray-100 text-gray-600'
};
$fLabel = match($fStatus) {
'pending' => 'Pending',
'in_transit' => 'In Transit',
'arrived' => 'Arrived',
'shipped' => 'Shipped',
'delivered' => 'Delivered',
default => 'Pending'
};
@endphp
{{ $fLabel }}
@if($item->expected_arrival && $fStatus === 'pending')
ETA: {{ $item->expected_arrival->format('M d, Y') }} @endif |
{{ $item->quantity }} | ${{ number_format($item->price, 2) }} | ${{ number_format($item->subtotal, 2) }} |
⚠️ Mixed warehouse order
Ghana items can ship immediately. China items need freight processing first.
Subtotal: ${{ number_format($order->subtotal, 2) }}
@if($order->shipping_cost > 0)Shipping: ${{ number_format($order->shipping_cost, 2) }}
@endif @if($order->discount > 0)Discount: -${{ number_format($order->discount, 2) }}
@endif @if($order->tax > 0)Tax: ${{ number_format($order->tax, 2) }}
@endifTotal: ${{ number_format($order->total, 2) }}
Carrier: {{ $shipment->carrier }}
@endif @if($shipment->notes){{ $shipment->notes }}
@endif{{ $order->notes }}
{{ $order->customer->name }}
{{ $order->customer->email }}
{{ $order->customer->phone ?: 'N/A' }}
@if($order->customer->phone) Call @endif{{ $addr['first_name'] }} {{ $addr['last_name'] }}
{{ $addr['address_line1'] }}
@if(!empty($addr['address_line2'])){{ $addr['address_line2'] }}
@endif{{ $addr['city'] }}, {{ $addr['state'] }} {{ $addr['postal_code'] }}
{{ $addr['country'] }}
@if(!empty($addr['phone']))Phone: {{ $addr['phone'] }}
@endif @elseNo shipping address available
@endifComplete payment for this order