@extends('layouts.admin') @section('page-title', 'Dashboard') @section('content') {{-- KPI ROW --}}
Revenue This Month
${{ number_format($pnlSummary['revenue'], 2) }}
Confirmed & delivered orders
Gross Profit
${{ number_format($pnlSummary['grossProfit'], 2) }}
{{ $pnlSummary['margin'] }}% margin
Low Stock SKUs
{{ $invSummary['low_stock'] + $invSummary['out_of_stock'] }}
{{ $invSummary['out_of_stock'] }} out of stock
Total SKUs
{{ $invSummary['total'] }}
{{ $invSummary['in_stock'] }} healthy stock
{{-- ALERTS --}} @if($outOfStockProducts->isNotEmpty())
🚨
{{ $outOfStockProducts->count() }} product(s) are out of stock: {{ $outOfStockProducts->map(fn($p) => $p->emoji.' '.$p->name)->join(', ') }} View →
@endif @if($lowStockProducts->isNotEmpty())
⚠️
{{ $lowStockProducts->count() }} product(s) are running low: {{ $lowStockProducts->map(fn($p) => $p->emoji.' '.$p->name.' ('.$p->stock.')')->join(', ') }} View →
@endif
{{-- RECENT ORDERS --}}
📦 Recent Orders View All
@if($recentOrders->isEmpty())

No orders yet.

@else @foreach($recentOrders as $order) @endforeach
Ref Customer Total Status
{{ $order->reference }} {{ $order->customer_name }} ${{ number_format($order->total, 2) }} {{ ucfirst($order->status) }}
@endif
{{-- QUICK LINKS --}}
🚀 Quick Actions
📊  View Profit & Loss Report 🗃️  Manage Inventory & Restock ➕  Add New Product ⬆️  Bulk Upload Products / Images 📦  Manage Orders 🏪  View Storefront
@endsection