->extraModalFooterActions(fn (Action $action): array => [
// TODO: Get argument to be received by action to identify when modal should be reloaded
$action->makeModalSubmitAction('createAnother', arguments: ['another' => true]),
])
->action(function (array $arguments) {
if ($arguments['another'] ?? false) {
// Reset the form and don't close the modal
dd('another');
}
// ... other form logic
});
->extraModalFooterActions(fn (Action $action): array => [
// TODO: Get argument to be received by action to identify when modal should be reloaded
$action->makeModalSubmitAction('createAnother', arguments: ['another' => true]),
])
->action(function (array $arguments) {
if ($arguments['another'] ?? false) {
// Reset the form and don't close the modal
dd('another');
}
// ... other form logic
});