This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Spring and the fly likes Spring MVC binding with List of Objects Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "Spring MVC binding with List of Objects" Watch "Spring MVC binding with List of Objects" New topic
Author

Spring MVC binding with List of Objects

mark xu
Greenhorn

Joined: Sep 22, 2006
Posts: 4
I'm having problem to get spring binding work with list of objects, here is the situation, I have a class:

The JSP that show the list of apps is like this:


My controller method that populate the objects (to JSP) and handle the post request is this


The problem is that the JSP show up with all the information correctly. However, when I click submit button, in the controller, the UserApp object I got only contain the usrId, the other property apps is empty. What did I do wrong? Thanks for reading
mark xu
Greenhorn

Joined: Sep 22, 2006
Posts: 4
I figured it out. It's a bug in spring 3.01. Upgrade to 3.02 everything works now.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Spring MVC binding with List of Objects