F
Filament13mo ago
Bagus A

How to Use Custom Modal Content

Here I want to create an action button with custom confirmation message. Custom message is loaded, but the default description is not replaced.
Forms\Components\Actions\Action::make('change_status')->label('Update Status')
->icon('heroicon-o-arrow-uturn-up')
->color('success')
->modalContent(fn (Order $record): View => view(
'vendor.filament.pages.actions.confirmation',
['record' => $record],
))
->requiresConfirmation(),
Forms\Components\Actions\Action::make('change_status')->label('Update Status')
->icon('heroicon-o-arrow-uturn-up')
->color('success')
->modalContent(fn (Order $record): View => view(
'vendor.filament.pages.actions.confirmation',
['record' => $record],
))
->requiresConfirmation(),
No description
1 Reply
Bagus A
Bagus AOP13mo ago
It seems that I don't need to call ->requiresConfirmation() since it has it's own custom modal description.
Want results from more Discord servers?
Add your server