FluentValidation Call RuleSet and Common Rules

前端 未结 5 799
无人共我
无人共我 2021-02-08 04:24

I have the following class

public class ValidProjectHeader : AbstractValidator
    {
        public ValidProjectHeader()
        {         


        
5条回答
  •  北恋
    北恋 (楼主)
    2021-02-08 04:29

        Fluent validation 10+ onwards.
          using FluentValidation;
         var validationResult = await 
         validator.ValidateAsync(account,options=>options("nameOfRuleSet"));
    

提交回复
热议问题