struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (WW-685) Generic error message - Type Conversion Error Handling
Date Fri, 16 Mar 2018 14:01:00 GMT

    [ https://issues.apache.org/jira/browse/WW-685?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16401943#comment-16401943
] 

Hudson commented on WW-685:
---------------------------

SUCCESS: Integrated in Jenkins build Struts-master-JDK7 #111 (See [https://builds.apache.org/job/Struts-master-JDK7/111/])
WW-685 Add class to hold conversion related data (amashchenko: rev 5b4ae03e7506c1a10640849ee21a4d79b57c4193)
* (edit) core/src/test/java/com/opensymphony/xwork2/interceptor/ConversionErrorInterceptorTest.java
* (edit) core/src/main/java/com/opensymphony/xwork2/validator/validators/ConversionErrorFieldValidator.java
* (edit) core/src/test/java/org/apache/struts2/interceptor/StrutsConversionErrorInterceptorTest.java
* (edit) core/src/test/java/com/opensymphony/xwork2/ActionSupportTest.java
* (edit) core/src/test/java/com/opensymphony/xwork2/ActionContextTest.java
* (add) core/src/main/java/com/opensymphony/xwork2/conversion/impl/ConversionData.java
* (edit) core/src/main/java/com/opensymphony/xwork2/ActionSupport.java
* (edit) core/src/test/java/com/opensymphony/xwork2/validator/ConversionErrorFieldValidatorTest.java
* (edit) core/src/test/java/com/opensymphony/xwork2/validator/RepopulateConversionErrorFieldValidatorSupportTest.java
* (edit) core/src/main/java/com/opensymphony/xwork2/interceptor/ConversionErrorInterceptor.java
* (edit) core/src/test/java/com/opensymphony/xwork2/conversion/impl/XWorkConverterTest.java
* (edit) core/src/main/java/com/opensymphony/xwork2/validator/validators/RepopulateConversionErrorFieldValidatorSupport.java
* (edit) core/src/test/java/com/opensymphony/xwork2/conversion/impl/AnnotationXWorkConverterTest.java
* (edit) core/src/test/java/com/opensymphony/xwork2/validator/VisitorFieldValidatorTest.java
* (edit) core/src/main/java/com/opensymphony/xwork2/ActionContext.java
WW-685 Add generic type conversion error message (amashchenko: rev 1b15cfdfc684cc9ff5027b6299e0b51fcbea516f)
* (edit) core/src/test/java/com/opensymphony/xwork2/conversion/impl/AnnotationXWorkConverterTest.java
* (edit) core/src/main/java/com/opensymphony/xwork2/interceptor/ConversionErrorInterceptor.java
* (edit) core/src/test/java/com/opensymphony/xwork2/conversion/impl/XWorkConverterTest.java
* (edit) core/src/main/java/com/opensymphony/xwork2/validator/validators/ConversionErrorFieldValidator.java
* (edit) core/src/main/java/com/opensymphony/xwork2/conversion/impl/XWorkConverter.java
WW-685 Add tests (amashchenko: rev 34979cf51e109173c91f03f20282108554938604)
* (edit) core/src/test/java/com/opensymphony/xwork2/conversion/impl/XWorkConverterTest.java
* (edit) core/src/test/resources/com/opensymphony/xwork2/SimpleAction.properties
WW-685 Fix getText expression (amashchenko: rev 1fcd1aeacfc96b9fd4abfb24ecf6b0a8938445a7)
* (edit) core/src/main/java/com/opensymphony/xwork2/conversion/impl/XWorkConverter.java


> Generic error message - Type Conversion Error Handling
> ------------------------------------------------------
>
>                 Key: WW-685
>                 URL: https://issues.apache.org/jira/browse/WW-685
>             Project: Struts 2
>          Issue Type: Improvement
>            Reporter: Ricardo Lecheta
>            Assignee: Aleksandr Mashchenko
>            Priority: Major
>             Fix For: 2.6
>
>
> To change the default message "invalid field value for field "xxx"", 
> you can put this line in the Action.properties
> > invalid.fieldvalue.[propertyName]
> But will be useful if there is a way to do a generic custom message to any type? For
example a custom message for Dates, double, boolean, etc:
> > invalid.fieldvalue.For_All_Dates=This is not a valid date.
> I don´t know how to implement it, but could be like this:
> > invalid.fieldvalue.java.lang.Integer=This is not a valid Number.
> > invalid.fieldvalue.java.util.Date=This is not a valid Date.
> -------------
> I tried the following examples, but them doesn´t work:
> invalid.fieldvalue.*=Invalid Date.
>  and
> invalid.fieldvalue.[*]=Invalid Date.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message