Created
December 10, 2018 07:18
-
-
Save wullemsb/05f59cf01a29fbea552a59ff04db6c96 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RuleFor(x => x.FastDelivery) | |
.NotEmpty() | |
.WithState(x => new ValidationState() { | |
Code = "FastDelivery.empty", | |
Keys = { ValidationKeys.Delivery } | |
}); | |
RuleFor(x => x.DeliveryDate) | |
.NotEmpty() | |
.WithState(x => new ValidationState() | |
{ | |
Code = "DeliveryDate.empty", | |
Keys = { ValidationKeys.Delivery } | |
}) | |
.When(x=> x.FastDelivery == true); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment