Productivity @php $fmtDuration = function (?float $seconds) { if ($seconds === null) { return '—'; } $hours = $seconds / 3600; if ($hours < 1) { return number_format($seconds / 60, 0) . 'm'; } if ($hours < 24) { return number_format($hours, 1) . 'h'; } return number_format($hours / 24, 1) . 'd'; }; $fmtCell = function (array $row) use ($fmtDuration) { $value = $row['value']; if ($value === null) { return ['—', 'text-muted']; } return match ($row['kind']) { 'pct' => [number_format($value, 1) . '%', 'text-dark'], 'days' => [number_format($value, 1) . 'd', 'text-dark'], 'duration' => [$fmtDuration($value), 'text-dark'], default => $value > 0 ? [number_format($value), 'text-dark'] : ['—', 'text-muted'], }; }; @endphp {{-- Controls --}}
{{ $fromLabel }} to {{ $toLabel }} ({{ number_format($days) }} {{ Str::plural('day', $days) }})
{{-- Live status snapshots --}}
@foreach ($report['snapshots'] as $snap)
{{ $snap['label'] }}
{{ number_format($snap['value']) }}
{{ $snap['note'] }}
@endforeach

Cards are live counts of where work sits right now. The tables below count what happened between the selected dates.

{{-- Funnel sections --}}
@foreach ($report['sections'] as $section)
{{ $section['title'] }}
@foreach ($section['rows'] as $row) @php [$text, $cls] = $fmtCell($row); @endphp @endforeach
{{ $row['label'] }} @if ($row['sub']) {{ $row['sub'] }} @endif {{ $text }}
@endforeach