@extends('layouts.admin') @section('title', 'Dashboard') @section('content') @php // [label, value, icon, target text, met?] $kpis = [ ['Verified users', indian_number($verifiedUsers), 'person-check', 'O1 · OTP + profile complete', null], ['Listings published', indian_number($listings['published']), 'shop', 'O2 · enquiry rate '.($listings['enquiry_rate'] ?? '—').'% (target ≥ 40%)', $listings['enquiry_rate'] === null ? null : $listings['enquiry_rate'] >= 40], ['Bookings confirmed', indian_number($bookings['confirmed']), 'truck', 'O3 · completion '.($bookings['completion_rate'] ?? '—').'% (≥ 90%) · on-time '.($bookings['on_time_rate'] ?? '—').'% (≥ 85%)', $bookings['completion_rate'] === null ? null : ($bookings['completion_rate'] >= 90 && ($bookings['on_time_rate'] ?? 100) >= 85)], ['Average rating', $trust['rating'] ? $trust['rating'].' / 5' : '—', 'star', 'O5 · target ≥ 4.2 · complaints '.($trust['complaints_per_100'] ?? '—').' per 100 (≤ 2)', $trust['rating'] === null ? null : ($trust['rating'] >= 4.2 && ($trust['complaints_per_100'] ?? 0) <= 2)], ['Service-fee revenue', inr($revenue), 'cash-stack', 'O6 · completed transport bookings', null], ['Marathi users', $marathiShare === null ? '—' : $marathiShare.'%', 'translate', 'O7 · share of users with Marathi as app language', null], ]; @endphp
This month · {{ now(config('jaykisan.display_timezone'))->format('F Y') }}

Business objectives

@foreach ($kpis as [$label, $value, $icon, $sub, $met])
{{ $label }}
{{ $value }}
@if ($met === true) @elseif ($met === false)@endif {{ $sub }}
@endforeach
New sign-ups · last 30 days
Users by role
@foreach ($usersByRole as $r) @endforeach
RoleActivePending
{{ $r->name }}{{ indian_number($r->active) }} @if ($r->pending){{ $r->pending }}@else 0 @endif

Work queues

@can('role.approve')
Roles awaiting approval View all
@forelse ($pendingRoles as $ur) {{ $ur->user->displayName() }} wants {{ $ur->role->name }} {{ ist($ur->created_at, 'd M') }} @empty
Nothing waiting
@endforelse
@endcan @can('listing.moderate')
@endcan
@can('support.manage')
@endcan
Bookings by status
@if ($bookingStatus)@else
No bookings yet
@endif
Listings by marketplace
@if ($listingTypes)@else
No listings yet
@endif
@endsection @push('scripts') @endpush