4 Replies
Why not a field validation? If the form contains errors, you can't submit it
It's not what I need
I have a toggle field in my form the default value is false and only display on edit. If you set this value to true I don't want to edit the form again
Do you mean hiding the Edit action on the table view for any records that have that field set to true?
If so, you can use either the
visible()
, hidden()
or disabled()
method on the EditAction
. You can pass it a closure that accepts the $record
, and return the state of that field:
thanks you
it works