Try adding a conversions.properties file to your action.
kris16 wrote:
Hi,
we have problems with setting HIDDEN values in an array list on a web page.
The problem code in the jsp page looks like this:
<s:submit method="addProducts" value="Lägg till" theme="simple"/>
<s:iterator value="existingProductOfferings" status="row">
<s:hidden name="existingProductOfferings[%{#row.index}].productOffering.id"
value="%{productOffering.id}"/>
<s:hidden
name="existingProductOfferings[%{#row.index}].productOffering.name"
value="%{productOffering.name}"/>
</s:iterator>
The problem seems to be that the object that are to be set is a list,
existingProductOfferings[%{#row.index}]
The error appeared when we upgraded the following libraries:
Struts2-core from 2.0.6 to 2.0.8
Struts-menu from 2.4.2 to 2.4.3
Struts2-spring-plugun 2.0.6 to 2.0.8
With the old libraries it works fine, but with the new libraries the HIDDEN
values are not set when we do a submit, and run the action method
addProducts.
When we do the submit we get the following error:
[ERROR,2007-06-15
14:44:54,482,interceptor.ParametersInterceptor,http-8383-Processor22]
ParametersInterceptor - [setParameters]: Unexpected Exception caught setting
'existingProductOfferings[0].productOffering.id' on 'class
com.teliasonera.serf.web.serviceprovider.AgreementAction: Error setting
expression 'existingProductOfferings[0].productOffering.id' with value
'[Ljava.lang.String;@1aa7a6a'
[ERROR,2007-06-15
14:44:54,482,interceptor.ParametersInterceptor,http-8383-Processor22]
ParametersInterceptor - [setParameters]: Unexpected Exception caught setting
'existingProductOfferings[0].productOffering.name' on 'class
com.teliasonera.serf.web.serviceprovider.AgreementAction: Error setting
expression 'existingProductOfferings[0].productOffering.name' with value
'[Ljava.lang.String;@14ae5cd'
Is this a bug in the new libraries ?
/Regards Krister
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]