How to make Fluent API configuration work with MVC client side validation?
问题 I prefer working with Fluent API configuration to DataAnnotation because I want to separate model from data access. I have tried in MVC, Fluent API does not work with client side validation. Shortly speaking, is there a simple way to make Fluent API works with client side validation as DataAnnotation can do? 回答1: No. Fluent API is just mapping - correct. Data annotations are both mapping and validation - wrong. Data annotations are one of the worst features of EF code first because when used