[jboss-user] [JBoss Seam] - DataModelSelection initialized to first item in ListDataMode

carloszaniolo do-not-reply at jboss.com
Thu Mar 15 16:50:47 EDT 2007


DataModelSelection is initialized to the first item in ListDataModel. Ok, no problem. 

But in my case, I have a single-page facelets ajax CRUD registration form. I have one container with DataModel and another container with DataModelSelection. The DataModelSelection container is only rendered when the user selects one item in the DataModel. This container hava rendered="false" before the user selects any item.

The problem is, because the DataModelSelection is initialized to the first item in ListDataModel, all the LAZY entities that depend the first item are fetched before the user selects an item!!!

In the seam source code, to init the DataModelSelection to null I need only to change the constructor of ListDataModel and init the rowIndex with -1.
Could I do this? Does this have any major implications?

It does not make sense to me that datamodelSELECTION comes selected before any selection...

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4028540#4028540

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4028540



More information about the jboss-user mailing list