How to map View Model back to Domain Model in a POST action?

后端 未结 4 854
深忆病人
深忆病人 2020-12-04 04:55

Every article found in the Internet on using ViewModels and utilizing Automapper gives the guidelines of the \"Controller -> View\" direction mapping. You take a domain mod

4条回答
  •  被撕碎了的回忆
    2020-12-04 05:54

    You don't need mapping viewmodel to domain because your viewmodel may be created more than domain model. Viewmodels optimized for screen (ui) and different from domain model.

    http://lostechies.com/jimmybogard/2009/06/30/how-we-do-mvc-view-models/

提交回复
热议问题