ASP.NET MVC Model Binder and postback BusinessListBase

ASP.NET MVC Model Binder and postback BusinessListBase

Old forum URL: forums.lhotka.net/forums/t/11333.aspx


wilfreds posted on Friday, April 27, 2012

Is there a problem with populating a model that contains a list?

How to reproduce:

In the ProjectTracker(4.3.10) sample I have added the rule:

BusinessRules.AddRule(new Csla.Rules.CommonRules.MaxLength(DescriptionProperty, 3));

to the ProjectEdit class.

 

When you edit a project you have "Project name" and "Description". An under the Save button you have a list of resources.

When you click Save it will not save and you get an error because of the broken rule. That is correct.

But, the list of resources that is connected to the project is now empty.

 

Regards,

Wilfred

Copyright (c) Marimer LLC