Validate not triggering
Hi , I’m facing an issue where submitting the “Create ITRF” modal results in an internal server error whenever a required field (like
item_name
) is left empty.
Here's a simplified version of my setup:
* In the modal footer actions, I'm using:
* And inside the handler:
The problem seems to be that form validation isn’t triggering the handleItrfStageOneAction()
is executed, so the request goes straight to the database and fails on NOT NULL
constraints.
I’d appreciate any guidance on:
* Why the validation might be skipped in this context.
* Whether there’s a better way to trigger validation before the action logic runs.
* How to make Filament show inline field errors rather than crashing with SQL exceptions.
Thanks in advance for your help!1 Reply
Solution
workaround
i am using
->after(fn (Action $action) => $action->cancelParentActions())
so that the modal not getting closed when the user submit empty fields or if there's any fields errors.