F
Filament7mo ago
Sydd

TextEntry roles badge translations

Dear all, please advice me, how to translate roles in TextEntry badges ..., I'm try but, it's dont work, returned values as stored in DB. TextEntry::make(('app.role.roles')) ->label(('app.role.roles')) ->badge() ->color('primary') ->separator(','),
Solution:
Solved:
Jump to solution
2 Replies
Solution
Sydd
Sydd7mo ago
Solved:
Sydd
SyddOP7mo ago
TextEntry::make('roles.name') ->label(('app.role.roles')) ->badge() ->separator(',') ->formatStateUsing(fn (string $state): string => ("app.role.{$state}")),
Want results from more Discord servers?
Add your server