Crisis2k
Form builder - general validation error?
Yes I see what you mean, but I think this doesn't help my case of, when 6 fields, that's a lot of red with a long "one of [...] fields needs filling", so I'm not sure it's the best, I would have preferred a global status message around the form or next to the save button. I think the only way to achieve this would be with custom views. Alternatively, a notification is a bit easier but I think not as clear.
21 replies
Form builder - general validation error?
The logic is correct, but how would that message be thrown and where would it appear? I feel like there isn't anything in Filament to manage this? Unless I make a custom view, but that's really getting complicated for not much really.
21 replies
Form builder - general validation error?
Oh, I can custom validate a group? That sounds like a decent solution.
I meant 'random' in the sense I have multiple forms with random fields, one form could be 2 fields (which would be ok with
->requiredWithoutAll(...)
), one could be 6 fields (which seems like a lot, would prefer a single error message than 6 red fields, if that makes sense), etc.21 replies
Form builder - general validation error?
Thank you for your reply 👍 The situation is I have a random amount of fields, and I need to make sure at least one is filled, so they're not all required. I could be thinking this wrong though, open to suggestions. I was expecting some kind of global error management possibility because errors not linked to specific fields can happen sometimes? (I did just manage something via
->beforeCreate()
sending a notification + ->halt()
which works but, I don't know, seems long winded).21 replies