Yes, that was the problem. Now I have another problem:
My interceptor stack is as follows:
<interceptor-ref name="exception"/>
<interceptor-ref name="alias"/>
<interceptor-ref name="params"/>
<interceptor-ref name="servletConfig"/>
<interceptor-ref name="prepare"/>
<interceptor-ref name="i18n"/>
<interceptor-ref name="chain"/>
<interceptor-ref name="debugging"/>
<interceptor-ref name="profiling"/>
<interceptor-ref name="scopedModelDriven"/>
<interceptor-ref name="modelDriven"/>
<interceptor-ref name="fileUpload"/>
<interceptor-ref name="checkbox"/>
<interceptor-ref name="staticParams"/>
<interceptor-ref name="params">
dojo\..*
</interceptor-ref>
<interceptor-ref name="conversionError"/>
<interceptor-ref name="validation">
_edit, input, save
</interceptor-ref>
<interceptor-ref name="workflow">
_edit, save
</interceptor-ref>
The parameters interceptor is fired before validation as suggested by the
struts 2 defaultStack. So actually before the @CustomValidation on the model
is able to happen, params fires with error:
2008-07-11 13:51:55 ERROR xwork2.interceptor.ParametersInterceptor -
ParametersInterceptor - [setParameters]: Unexpected Exception caught setting
'modelMap[344344].lowPrice' on 'class xxx.action.ItemAction: Error setting
expression 'modelMap[344344].lowPrice' with value
'[Ljava.lang.String;@142d6a9'
Is there any way around this?
newton.dave wrote:
>
> --- On Fri, 7/11/08, tangy <[EMAIL PROTECTED]> wrote:
>> I have the validators.xml file in /WEB-INF/:
>
> AFAIK this file needs to be on the classpath.
>
> The validation documentation [1] points this out in the "Registering
> Validators" section, stating "The simplest way to do so is to add a file
> name validators.xml in the root of the classpath (/WEB-INF/classes) [...]"
>
> Dave
>
> [1] http://struts.apache.org/2.x/docs/validation.html
>
>
--
View this message in context:
http://www.nabble.com/%40CustomValidator-error-tp18407467p18410553.html
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]