@extends('layouts.app', ['title' => 'Performance']) @section('content') @php($cur = $currentAccount->currency)

Performance

Team activity and results · {{ $rangeLabel }}. AI agent activity is counted separately.

@foreach ([ ['Verified revenue', money_format_short($totals['revenue'], $cur), 'bi-currency-rupee', '#1c7c45'], ['Total actions', number_format($totals['actions']), 'bi-lightning', '#027a7a'], ['Calls made', number_format($totals['calls']), 'bi-telephone', 'var(--bz-primary)'], ['Avg first response', \App\Services\PerformanceService::responseLabel($totals['response']), 'bi-stopwatch', '#9a5b00'], ['Active now', $totals['online'].' / '.$totals['members'], 'bi-people', '#1c7c45'], ] as [$label, $value, $icon, $color])
{{ $label }}
{{ $value }}
@endforeach
Leaderboard · {{ $rangeLabel }}
@foreach (['revenue' => 'Revenue', 'engagement' => 'Engagement', 'calls' => 'Calls', 'response' => 'Response'] as $k => $v) {{ $v }} @endforeach
@php($maxScore = max(1, $allRows->max('score'))) @forelse ($rows as $i => $row)
{{ $view === 'team' ? $i + 1 : '' }}
{{ $row['user']->initials }} @if ($row['online'])@endif
{{ $row['user']->name }} {{ $row['level']['name'] }}
{{ $row['actions'] }}   {{ $row['messages'] }}   {{ $row['tasks'] }}   {{ $row['calls'] }}   {{ $row['meetings'] }}
{{ \App\Services\PerformanceService::responseLabel($row['response_minutes']) }}
Response
{{ money_format_short($row['revenue'], $cur) }}
{{ $row['sales'] }} {{ \Illuminate\Support\Str::plural('sale', $row['sales']) }}
@if ($row['earned'] > 0 && ($canManageIncentives || $row['user']->is(auth()->user())))
Incentive {{ money_format_short($row['earned'], $cur) }}
@endif
@empty
No team members yet.
@endforelse

Score = actions + 2 × calls + 3 × meetings + 10 × sales. Levels: Bronze, Silver (75), Gold (200), Platinum (400).

@if ($canManageIncentives)
Incentive settingsAdmin only
@csrf
@foreach ($allRows as $row) @php($inc = $row['incentive']) @php($uid = $row['user']->id) @endforeach
StaffOnTypeRateMonthly target
{{ $row['user']->name }}
enabled)>
@endif @endsection