@extends('layouts.app') @section('title', 'Order Management - Admin') @section('content')
{{-- Page Header --}}

Order Management

Manage and oversee all orders on your marketplace platform

Export
{{-- Quick Stats --}} @include('admin.orders.partials.stats', ['stats' => $stats]) {{-- Order Status Tabs --}}
{{-- Filters --}}
{{-- Search --}}
{{-- Payment Status --}}
{{-- Buyer --}}
{{-- Seller --}}
{{-- Per Page --}}
{{-- Hidden sort/direction --}} {{-- Reset --}}
Reset
{{ $orders->total() }} orders found @if($orders->total() > 0) ({{ $orders->firstItem() }} - {{ $orders->lastItem() }}) @endif
{{-- Bulk Actions --}} @if($orders->count() > 0) @endif {{-- Orders Table --}}
@forelse($orders as $order) @empty @endforelse
Order # Buyer Total Items Payment Status Date Actions
#{{ $order->order_number }}
{{ $order->buyer?->username ?? 'Guest' }}
{{ $order->buyer?->email ?? 'No email' }}
@if($order->price_currency === 'NGN') {{ currency_symbol() }} @else {{ $order->price_currency ?? '' }} {{ currency_symbol() }} @endif {{ number_format($order->price_total, 2) }} {{ $order->items_count ?? 0 }}
{{ ucfirst(str_replace('_', ' ', $order->payment_status ?? 'N/A')) }}
{{ $order->payment_method ?? 'N/A' }}
@if($order->status == 0) Active @elseif($order->status == 1) Completed @elseif($order->status == 2) Cancelled @else Unknown @endif @if($order->status == 0 && $order->payment_status === 'payment_received') Processing @endif
{{ $order->created_at ? $order->created_at->format('M d, Y') : 'N/A' }}
{{ $order->created_at ? $order->created_at->diffForHumans() : '' }}
@if($order->invoice) @endif @if($order->status != 2 && $order->payment_status === 'pending') @endif
No orders found

Try adjusting your search or filter criteria

{{-- Pagination --}} @if($orders->hasPages()) @endif
{{-- Cancel Modal --}} {{-- Bulk Cancel Modal --}} {{-- Hidden Forms --}} @endsection @push('styles') @endpush @push('scripts') @endpush