[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-3438) Honor input's label attribute in ModelValidator message

Dan Allen (JIRA) jira-events at lists.jboss.org
Sat Sep 20 00:30:20 EDT 2008


Honor input's label attribute in ModelValidator message
-------------------------------------------------------

                 Key: JBSEAM-3438
                 URL: https://jira.jboss.org/jira/browse/JBSEAM-3438
             Project: Seam
          Issue Type: Feature Request
          Components: JSF Controls
    Affects Versions: 2.1.0.BETA1, 2.0.3.CR1
            Reporter: Dan Allen
            Assignee: Dan Allen
             Fix For: 2.0.3.CR2, 2.1.0.CR1


Currently, the ModelValidator behaves unlike the standard JSF validators in that it does not provide an indexed message parameter equivalent to the value of the input's label attribute. Such a value is essential when messages cannot be displayed adjacent to the input component on the page.

Here is an example of an input component that declares a label:

<h:inputText id="name" value="#{person.name}" label="Name:">
  <s:validate/>
</h:inputText>

Here is an example of a Hibernate Validator message key that uses this label:

validator.length={0} length must be between {min} and {max}

And here is what would be displayed had the validation failed:

Name: length must be between 0 and 20

Note that the label parameter would occupy the first and only indexed placeholder, {0}.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list