Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Collection of bean input from form-problem

 
yash Vi
Ranch Hand
Posts: 41
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

The issue is like this.I am displaying a list of employee details in the page from
the database.Each employee has a appraisal field.The user inputs all the fields and
click save in one go.The next page displays the details and as saved.

As this is a prepopulated form,
1.My form bean has a collection
2.The collection gets populated with employeebean with the info from the database.
3.I use logic:iterate and display the info.

I am able to do till the prepopulated form and when they click the save button
the corresponding action class is triggered and the next page is rendered but the info is
not displayed.

Can you help me on where I am goin wrong and how to do it
 
Srilakshmi Vara
Ranch Hand
Posts: 169
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check your action mapping for this you might need to put your form in session scope.
 
yash Vi
Ranch Hand
Posts: 41
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess it is the prepopulated form which when submitted behaves as anyother form.

Anyway putting it in session scope dint help
 
Pranav Sharma
Ranch Hand
Posts: 258
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you will probably have to use the lazylist class in your form, so the form/collection is updated correctly

look at this link, great example how to use it.
 
yash Vi
Ranch Hand
Posts: 41
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much I hope this helps me
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic