Limiting validation rules
I have a single form with multiple sections. I declare the validation rules for each field via the
->rules()
method. I would like to only process the validation rules for the section that the action button was pressed in. I have reasons for using ->rules()
instead of Filaments helper methods like ->string()
.
In the following code, when the personal_action
button is pressed, I want to validate name
but not company_name
. Or, when the business_action
is pressed, I want to validate company_name
but not name
.
Is there a way to accomplish with Filament?
1 Reply
Resolved it with
and