fix(admin-products): status stats use light active class

This commit is contained in:
萝卜
2026-03-16 15:20:20 +08:00
parent f0198841a9
commit 496b4652c6
2 changed files with 36 additions and 2 deletions

View File

@@ -161,9 +161,9 @@
];
@endphp
<div class="grid-4">
<a href="{{ '/admin/products?' . http_build_query(array_filter($productBaseQuery, fn ($value) => $value !== null && $value !== '')) }}" class="status-link {{ $filters['status'] === '' ? 'is-active-dark' : '' }}"><div class="muted">全部</div><strong class="num-md">{{ $statusStats['all'] ?? 0 }}</strong></a>
<a href="{{ '/admin/products?' . http_build_query(array_filter($productBaseQuery, fn ($value) => $value !== null && $value !== '')) }}" class="status-link {{ $filters['status'] === '' ? 'is-active-light' : '' }}"><div class="muted">全部</div><strong class="num-md">{{ $statusStats['all'] ?? 0 }}</strong></a>
@foreach($filterOptions['statuses'] as $status)
<a href="{{ '/admin/products?' . http_build_query(array_filter(array_merge($productBaseQuery, ['status' => $status]), fn ($value) => $value !== null && $value !== '')) }}" class="status-link {{ $filters['status'] === $status ? 'is-active-dark' : '' }}"><div class="muted">{{ $statusLabels[$status] ?? $status }}</div><strong class="num-md">{{ $statusStats[$status] ?? 0 }}</strong></a>
<a href="{{ '/admin/products?' . http_build_query(array_filter(array_merge($productBaseQuery, ['status' => $status]), fn ($value) => $value !== null && $value !== '')) }}" class="status-link {{ $filters['status'] === $status ? 'is-active-light' : '' }}"><div class="muted">{{ $statusLabels[$status] ?? $status }}</div><strong class="num-md">{{ $statusStats[$status] ?? 0 }}</strong></a>
@endforeach
</div>
</div>