@extends('layouts.app') @section('title','Dashboard — BlueBando v3') @section('content')

Dashboard

Quick overview of your routers, vouchers, and sales today.
{{-- KPIs --}}
Routers
{{ number_format($stats['routers'] ?? 0) }}
Vouchers
{{ number_format($stats['vouchers'] ?? 0) }}
Sales Today ({{ config('bluebando.currency','TZS') }})
{{ number_format($stats['sales_today'] ?? 0) }}
Currency
{{ config('bluebando.currency','TZS') }}
{{-- Revenue sparkline --}}
Last 7 Days Revenue {{ config('bluebando.currency','TZS') }}
Hook to real data later (controller can sum paid orders by day).
{{-- Payment mix --}}
Payment Mix (Recent) Gateways
@php $mix = $mix ?? [ ['name'=>'AzamPay','val'=>48], ['name'=>'Selcom','val'=>22], ['name'=>'Flutterwave','val'=>14], ['name'=>'Pesapal','val'=>9], ['name'=>'ClickPesa','val'=>5], ['name'=>'ZenoPay','val'=>2], ]; @endphp @foreach($mix as $m)
{{ $m['name'] }}{{ $m['val'] }}%
@endforeach
{{-- Recent Orders --}}
Recent Orders View all
@php $orders = $orders ?? \App\Models\Order::latest()->take(8)->get(); @endphp @if ($orders->count()) @foreach($orders as $o) @php $status = strtolower($o->status); @endphp @endforeach
ReferenceGatewayAmountStatusDate
{{ $o->reference }} {{ strtoupper($o->gateway) }} {{ number_format($o->amount) }} {{ $o->currency }} {{ ucfirst($o->status) }} {{ $o->created_at->format('Y-m-d H:i') }}
@else
No orders yet.
@endif
@endsection