| {{ $rowPrefix }}{{ ucwords(str_replace(['_', '-'], ' ', $r)) }} |
@foreach($cols as $c)
@php
$count = $grid[$r][$c] ?? 0;
if ($count === 0) {
$bg = '#f9fafb';
$opacity = 1;
$textColor = 'text-gray-400';
} else {
$intensity = $count >= 15 ? 'success' : ($count >= 8 ? 'warning' : 'info');
$bg = "var(--bs-{$intensity})";
$opacity = min(1, 0.2 + ($count / 30));
$textColor = $count >= 8 ? 'text-white' : 'text-dark';
}
$cellUrl = ($count > 0 && $filterRoute)
? route($filterRoute, [$rowParam => $r, $colParam => $c])
: null;
@endphp
@if($count > 0 && $cellUrl)
{{ $count }}
@elseif($count > 0)
{{ $count }}
@else
—
@endif
|
@endforeach
@endforeach