Coming from a Silverlight background, MVVM is solidly planted in my mind. Moving to MVC, although rewarding, has been something of a paradigm shift for me.
One of the questions I have is about using EditorForModel when the strongly typed view has been passed a ViewModel with the object to be editted as a property, rather than the POCO being directly passed in as the model, with no viewmodel encapsulated around it.
How can I use EditorForModel on a property of the model, rather than the whole model itself? I went looking for something akin to @HtmlHelper.EditorForModel(model.Customer), but coulndt find an overload. It seems you can only generate an editor for the whole model…
(where customer is a good ‘ol poco)
You could try –