Files
fewo-stommer/app/Enums/UserRole.php
T
Lars StommerandClaude Opus 5.5 27ea12901e Benutzerrollen (Administrator, Vermietung, Inhalte) und Benutzerverwaltung
- Rollenbasierte Policies, Navigationsgruppen
- Media Library (Spatie) für die kommende Bildverwaltung installiert

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 10:13:55 +02:00

32 lines
814 B
PHP

<?php
namespace App\Enums;
use Filament\Support\Contracts\HasDescription;
use Filament\Support\Contracts\HasLabel;
enum UserRole: string implements HasDescription, HasLabel
{
case Admin = 'admin';
case Rentals = 'rentals';
case Content = 'content';
public function getLabel(): string
{
return match ($this) {
self::Admin => 'Administrator',
self::Rentals => 'Vermietung',
self::Content => 'Inhalte',
};
}
public function getDescription(): string
{
return match ($this) {
self::Admin => 'Alles, inklusive Benutzerverwaltung',
self::Rentals => 'Buchungen, Gäste, Preise, Angebote und Bewertungen',
self::Content => 'Bilder, Texte, FAQ, Hinweise und Bewertungen',
};
}
}