feat: admin list filtering and search

This commit is contained in:
Björn Fromme
2026-08-06 10:57:36 +02:00
parent aa8fa5c1b2
commit dd658bf9d6
41 changed files with 1977 additions and 44 deletions
+31
View File
@@ -0,0 +1,31 @@
<?php
declare(strict_types=1);
namespace App\Model;
/**
* A single active filter, rendered as a chip above a list view.
*
* Chips exist so that a filtered list explains itself — especially when the filter was not
* chosen by the user but applied as a role-dependent default.
*/
final readonly class ListFilterChip
{
/**
* @param string[] $removeKeys Query keys dropped when the chip is dismissed. An empty list
* marks a chip the user is not allowed to remove, e.g. the
* manager scope a non-admin is pinned to.
*/
public function __construct(
public string $label,
public string $value,
public array $removeKeys = [],
) {
}
public function isRemovable(): bool
{
return [] !== $this->removeKeys;
}
}