@extends('pages.layouts.app') @section('content')
| {{ __('Order ID') }} | {{ __('Order Date') }} | {{ __('Total Amount') }} | {{ __('Status') }} | {{ __('Address') }} | {{ __('Items') }} | {{ __('Actions') }} |
|---|---|---|---|---|---|---|
| {{ $order->id }} | {{ $order->created_at->format('M d, Y') }} | ${{ number_format($order->total_amount, 2) }} | {{ ucfirst(str_replace('_', ' ', __($order->status))) }} | {{ $order->address ? $order->address->city->name . ', ' . $order->address->address : 'N/A' }} |
@foreach($order->orderItems as $item)
{{ $item->product->name }} (x{{ $item->quantity }}) @if ($item->color) {{ app()->getLocale() === 'ar' ? $item->color->name_ar : $item->color->name }} @endif |
@if($order->status == 'pending') {{ __('Complete Your Order') }} @else {{ __('Order') . ' '. __($order->status) }} @endif |