Might be a stupid question.
But doesn’t specifying the caption in the model using the Display attribute violate the separation of concerns principle? Shouldn’t the caption belong in the view?
If it does not, could somebody explain why it belongs in the model?
The MVC framework allows you to put the
DataAnnotationsin a model, but strictly talkingDataAnnotationsshould be placed in a ViewModel and not in a Model mapped to the database.