Hello,
I have the following problem.
I have an struts form with an Collection getter and want to let set
struts the input values of an submit.
public class UserForm extends ActionForm {
// returns a collection of user beans
Collection getUsers(){
...
}
}
public class User {
Integer age;
public Integer getAge(){
return age;
}
public void setAge(Integer age){
this.age=age;
}
}
In the jsp- Page I use layout:collection with layout:text to show the
input fields in a table.
<layout:form action="/save">
<layout:collection property="users" indexId="index">
<layout:collectionItem title="Age" >
<layout:text property="users[${index}].age"
layout="false"/>
</layout:collectionItem>
</layout:collection>
</layout:form>
On submit struts fill also all values in the user bean, but struts set
"0" into the age-Field and not "null" if the value is empty.
How can I modify this?
Regards
Tom
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]