@extends('backend.partials.master') @section('title') {{ ___('admin.agent_reports_c36084') }} @endsection @section('maincontent') @include('backend.reports._filterbar') @php $laDonut = ['labels' => $byStatus->pluck('status')->map(fn($s) => ucfirst($s))->all(), 'series' => $byStatus->pluck('amount')->map(fn($v) => (float) $v)->all()]; $laTrend = ['type' => 'bar', 'labels' => $byStatus->pluck('status')->map(fn($s) => ucfirst($s))->all(), 'series' => [['name' => 'Records', 'data' => $byStatus->pluck('records')->map(fn($v) => (int) $v)->all()]]]; @endphp
{{ ___('admin.total_commission_4dd4fc') }}

{{ currency_symbol() }}{{ number_format($totalCommission) }}

{{ ___('admin.paid_dc9d45') }}

{{ currency_symbol() }}{{ number_format($paid) }}

{{ ___('admin.pending_96f608') }}

{{ currency_symbol() }}{{ number_format($pending) }}

{{ ___('admin.records_e51c55') }}

{{ number_format($records) }}

{{ ___('admin.by_status_555c76') }}

@foreach($byStatus as $s) {{ admin_label(ucfirst($s->status)) }} {{ number_format($s->records) }} {{ currency_symbol() }}{{ number_format($s->amount) }} @endforeach

{{ ___('admin.recent_commissions_fae195') }}

@foreach($recent as $r) {{ $r->reference }} {{ $r->customer_name }} {{ currency_symbol() }}{{ number_format($r->amount) }} {{ admin_label(ucfirst($r->status)) }} {{ optional($r->earned_on)->translatedFormat('d M Y') }} @endforeach
@endsection