F
Filament6mo ago
Pooja

Require confirmation modal on submit action

I want to add a confirmation popup on create form submit button.
6 Replies
LeandroFerreira
LeandroFerreira6mo ago
This works in v3, not sure about v2, but you can use the same approach
protected function getCreateFormAction(): Action
{
return parent::getCreateFormAction()
->submit(null)
->requiresConfirmation()
->action(function (Action $action) {
$this->closeActionModal();
$this->create();
});
}
protected function getCreateFormAction(): Action
{
return parent::getCreateFormAction()
->submit(null)
->requiresConfirmation()
->action(function (Action $action) {
$this->closeActionModal();
$this->create();
});
}
Pooja
PoojaOP6mo ago
Not working in v2
Umar Farooq
Umar Farooq6mo ago
how add confirmation modal inside the relation manager? confirmation modal the modal submit the form
->headerActions([
Tables\Actions\CreateAction::make()
->createAnother(false)
->label(__('request-builder.post_request.action_label'))
])
->headerActions([
Tables\Actions\CreateAction::make()
->createAnother(false)
->label(__('request-builder.post_request.action_label'))
])
LeandroFerreira
LeandroFerreira6mo ago
hum I don't know in v2
Pooja
PoojaOP6mo ago
I want apply in v2
Want results from more Discord servers?
Add your server