Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: Multiple Validation Rules with multiple error messages. #205

Open
AdamHess opened this issue Nov 8, 2016 · 0 comments
Open

Request: Multiple Validation Rules with multiple error messages. #205

AdamHess opened this issue Nov 8, 2016 · 0 comments

Comments

@AdamHess
Copy link

AdamHess commented Nov 8, 2016

Sometimes we need complex business rules for validating logic.

For example, I have a case where i need to do validation between three time fields.

The start time can be later than the end time, the lunch length time cannot be larger than the difference between the start and end time and finally if the the start and end time are larger than 5 hours the lunch time must be 30 minutes.

I want to relay those messages back to my users for each instance they make a mistake like that.

what I want abide to be able to do is:

  1. Specify a list of validators
  2. For each validator have a specific message associated with its failure
  3. show the messages for all validators that have returned false.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant