Is it possible to only accept post back values from a nested view model?
For example, I would like to post only the 'Address':
@Html.TextBoxFor(p => p.User.Account.Address.Street)
@Html.ValidationMessageFor(p => p.User.Account.Address.Street)
To this controller action:
[HttpPost]
public ActionResult SaveAddress(Address address) {
// save to db here
}
Currently the values only post back if I pass the Address to it's own partial view so that the properties look like:@Html.TextBoxFor(p => p.Street)
@Html.ValidationMessageFor(p => p.Street)