Skip to content

Instantly share code, notes, and snippets.

Created August 3, 2014 13:58
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
Create Dto
public class TestPerson : DtoBase, IValidatableObject
public string Title { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public string Initials { get; set; }
public IEnumerable<ValidationResult> Validate(ValidationContext validationContext)
//if (Id == 0)
// CustomValidationErrors++;
// yield return new ValidationResult("Should have used a PUT");
return Enumerable.Empty<ValidationResult>();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment