开发者

What collection does excludeProperties parameter for TryUpdateModel refer to?

Does excludeProperties parameter in http://msdn.microsoft.com/en-us/library/dd492957.aspx exclude properties from the model or the values from the Request?

E.g.

If I wish to exclude Model.SomeProperty.SomeChildProperty which has a name attribute of "Model.SomeProperty.SomeChildProperty", should I pass

["SomeProperty"](name of the property on the model)

or

["Model.SomeProperty.SomeChildProperty"](name of the field in the Request form)开发者_JAVA百科

To exclude it from the udpate?


The DefaultModelBinder will look at PropertyDescriptor.Name when filtering properties during model binding. You should use the model property name.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜