feat: Restrict TrashedFilter visibility to the Developer role across multiple Filament resources and apply minor code formatting adjustments.
This commit is contained in:
parent
2d3d001ea4
commit
974d8ac92b
@ -163,7 +163,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditJournalistAction::make('edit'),
|
EditJournalistAction::make('edit'),
|
||||||
|
|||||||
@ -306,7 +306,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
ViewAction::make(),
|
ViewAction::make(),
|
||||||
|
|||||||
@ -81,7 +81,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -83,7 +83,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -93,7 +93,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -83,7 +83,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -103,7 +103,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -99,7 +99,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -83,7 +83,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -148,7 +148,8 @@ public static function table(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()
|
EditAction::make()
|
||||||
|
|||||||
@ -54,7 +54,8 @@ public static function configure(Table $table): Table
|
|||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
TrashedFilter::make()
|
TrashedFilter::make()
|
||||||
->native(false),
|
->native(false)
|
||||||
|
->visible(fn () => auth()->user()?->hasRole('Developer')),
|
||||||
|
|
||||||
SelectFilter::make('issue')
|
SelectFilter::make('issue')
|
||||||
->label('Filter Isu')
|
->label('Filter Isu')
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user