[richfaces-issues] [JBoss JIRA] (RF-12511) using f:validateDoubleRange but default message not the validatorMessage is displayed
Luca Nardelli (JIRA)
jira-events at lists.jboss.org
Tue Oct 30 15:08:01 EDT 2012
[ https://issues.jboss.org/browse/RF-12511?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12730190#comment-12730190 ]
Luca Nardelli commented on RF-12511:
------------------------------------
The insertion of "XX" raises a ConverterException and happens before validation. You need to define a converterMessage on your field. Try:
{code}
<h:panelGrid columns="3">
<h:outputText value="#{labels.decimal}:"/>
<h:inputText id="decimal" validatorMessage="#{msgs.NaDecimal}" converterMessage="#{msgs.NaDecimal}" value="#{myBean.decimal}">
<f:validateDoubleRange/>
<f:validateRequired/>
<rich:validator event="blur"/>
</h:inputText>
<rich:message for="decimal"/>
...
{code}
> using f:validateDoubleRange but default message not the validatorMessage is displayed
> -------------------------------------------------------------------------------------
>
> Key: RF-12511
> URL: https://issues.jboss.org/browse/RF-12511
> Project: RichFaces
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Affects Versions: 4.2.0.Final
> Reporter: Radim Hanus
> Fix For: 5-Tracking
>
>
> The validatorMessage is displayed when the input is left empty but when I insert wrong value for instance "XX" the the default validator message is displayed not the validatorMessage. The same behaviour if fallbacking to server side validation.
>
> facelet snippet:
> {code}
> <h:panelGrid columns="3">
> <h:outputText value="#{labels.decimal}:"/>
> <h:inputText id="decimal" validatorMessage="#{msgs.NaDecimal}" value="#{myBean.decimal}">
> <f:validateDoubleRange/>
> <f:validateRequired/>
> <rich:validator event="blur"/>
> </h:inputText>
> <rich:message for="decimal"/>
> ...
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the richfaces-issues
mailing list