feat: Enable edit, delete, force delete, and restore actions for all user roles.

This commit is contained in:
Yoga Pangestu 2026-03-12 11:59:53 +07:00
parent 427805ebd1
commit 28ca845adb

View File

@ -153,17 +153,13 @@ public static function table(Table $table): Table
]) ])
->recordActions([ ->recordActions([
EditAction::make() EditAction::make()
->modalWidth(Width::Large) ->modalWidth(Width::Large),
->hidden(fn (User $record): bool => $record->hasRole(RoleEnum::PERUSAHAAN->value)),
DeleteAction::make() DeleteAction::make(),
->hidden(fn (User $record): bool => $record->hasRole(RoleEnum::PERUSAHAAN->value)),
ForceDeleteAction::make() ForceDeleteAction::make(),
->hidden(fn (User $record): bool => $record->hasRole(RoleEnum::PERUSAHAAN->value)),
RestoreAction::make() RestoreAction::make(),
->hidden(fn (User $record): bool => $record->hasRole(RoleEnum::PERUSAHAAN->value)),
ChangePasswordAction::make('changePassword'), ChangePasswordAction::make('changePassword'),
]) ])