Is it possible to reuse the DataAnnotations in ViewModel?
问题 In my MVC application, I defined the DataAnnotations in the domain models. Although the DataAnnotations properties as Display, etc. can be retrieved when using Domain model, they cannot be retrieved when using the same properties on ViewModel and using this ViewModel. I think it is not seem to good to define the DataAnnotations in ViewModel again. So, is it possible or which way should I follow? Domain Model: public class Issue { [Key] public int ID { get; set; } [Required(ErrorMessage =