How MVC Update Model works with incomplete objects?
I have a view that is bound to an object called "开发者_C百科Requisition" On this view we are only modifying is child records.
My question is: When I submit the form I have the object requisitionForm, and this object is only partially complete.
How do I save just the new changes?
Should I take the requisitionForm (incomplete) and merge it with requisition (complete) ?
thanks!
Remove the requisitionForm
parameter, and call UpdateModel(requisition)
Is this what you want? http://www.joe-stevens.com/2010/02/17/asp-net-mvc-using-controller-updatemodel-when-using-a-viewmodel/
精彩评论