@extends('layouts.app') @section('title', 'Officer Caseload - Reports') @section('content')

Officer Caseload

Back
@if($unassigned > 0)
{{ $unassigned }} case(s) are not yet allocated to any officer.
@endif
Caseload by Officer
@php $shown = collect($types)->filter(fn ($l, $k) => $officers->sum(fn ($o) => $o->by_type[$k] ?? 0) > 0); @endphp
@foreach($shown as $k => $l)@endforeach @forelse($officers as $o) @foreach($shown as $k => $l)@endforeach @empty @endforelse
Officer{{ $l }}Total Active Breached Completed
{{ $o->officer }}{{ $o->by_type[$k] ?? 0 }}{{ $o->total }} {{ $o->active }} @if($o->breached){{ $o->breached }}@else 0 @endif {{ $o->completed }}
No allocated cases yet.
@endsection