@extends('super-admin.layout') @section('title', 'User Details') @section('subtitle', "Viewing {$user->name}") @section('content')

{{ $user->name }}

{{ $user->email }}

{{ $user->phone ?? 'N/A' }}

{{ ($user->is_active ?? true) ? 'Active' : 'Inactive' }}
@forelse($user->roles as $role) {{ $role->name }} @empty Customer @endforelse

{{ $user->created_at->format('M d, Y') }}

{{ $user->updated_at->diffForHumans() }}

{{ $user->email_verified_at ? 'Verified' : 'Not Verified' }}
@if($user->orders->count() > 0)

Recent Orders

@foreach($user->orders as $order) @endforeach
Order ID Date Items Total Status
#{{ $order->id }} {{ $order->created_at->format('M d, Y') }} {{ $order->items->sum('quantity') }} items ₦{{ number_format($order->total_amount, 2) }} {{ ucfirst($order->status) }}
@else

No orders

This user hasn't placed any orders yet.

@endif
@endsection