You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a complex validation so I am using the Must() method on the FluentValidation call.
This may have an easy answer, but when I use , the error messages above each question do not show up. Is there a way to make the ValidationMessage component work with a whole object and not a property?
I have a Rule like
RuleFor( r => r).Must(ValidateObject).WithMessage("custom error messsage");
but not sure how to get that message to show up using the component. Do I need to create another property in my class that the ValidationMessage can use?
Thanks
The text was updated successfully, but these errors were encountered:
So, I got the validation to work restructuring how I setup the validations. Chained some When() calls to handle the different kinds of validation based on a property. I started creating dependant rules, but changed those to When().
I have a complex validation so I am using the Must() method on the FluentValidation call.
This may have an easy answer, but when I use , the error messages above each question do not show up. Is there a way to make the ValidationMessage component work with a whole object and not a property?
I have a Rule like
RuleFor( r => r).Must(ValidateObject).WithMessage("custom error messsage");
but not sure how to get that message to show up using the component. Do I need to create another property in my class that the ValidationMessage can use?
Thanks
The text was updated successfully, but these errors were encountered: