[jsr-314-open] DRY and form with JSF 2

Dan Allen dan.j.allen at gmail.com
Mon Sep 14 13:08:10 EDT 2009


Any votes? Once some votes come in, we can convert this into a feature
request in the Issue Tracker. Counter proposals are also welcome.

-Dan

On Mon, Sep 14, 2009 at 1:03 PM, <damien.gouyette at gmail.com> wrote:

> i think that could be a good enhancement.
>
> Le 14 sept. 2009 à 18:39, Dan Allen <dan.j.allen at gmail.com> a écrit :
>
> I've run into the same problem every time I get to polishing a JSF
> application. My thought is that there should be a new positional replacement
> value in message templates that allows you to plug in the value of the
> correlated output label. (If there are multiple, the first would be
> selected).
>
> In general, the position replacements are:
>
> 0 = invalid value
> 1 = example value (sometimes this applicable, in which case the positional
> parameters shift)
> 2 = client id
>
> We could add
>
> 3 = label value
>
> It's debatable whether the HTML should be stripped from the value.
>
> javax.faces.converter.DateTimeConverter.DATE={3}: ''{0}'' could not be
> understood as a date. Example: {1}
>
> -Dan
>
> On Sat, Sep 12, 2009 at 9:24 AM, Damien Gouyette <<damien.gouyette at gmail.com>
> damien.gouyette at gmail.com> wrote:
>
>> Hello,
>> I have a lot of forms to do and i don't understand a point
>>
>> <h:outputLabel value="*client's birthdate*" for="birthDateField"/>
>>
>> <h:inputText id="birthDateField" label="client's birthdate"/>
>>
>> <h:message for="birthDateField"/>
>>
>> if i don't set label on inputText, i have an error message like :
>>
>> *formNew:birthDate: 'a' could not be understood as a date. Example:
>> 12/09/2009 instead of *
>>
>> *client's birthdate *: 'a' could not be understood as a date. Example:
>> 12/09/2009
>>
>> Can you reuse outputLabel value if exists ?
>>
>> Just for information, this message is the french error message when i set
>> a dateConverter on my inputText. (little bug)
>>
>>
>> Damien GOUYETTE
>>
>
> --
> Dan Allen
> Senior Software Engineer, Red Hat | Author of Seam in Action
> Registered Linux User #231597
>
> <http://mojavelinux.com>http://mojavelinux.com
> <http://mojavelinux.com/seaminaction>http://mojavelinux.com/seaminaction
> <http://www.google.com/profiles/dan.j.allen>
> http://www.google.com/profiles/dan.j.allen
>
>


-- 
Dan Allen
Senior Software Engineer, Red Hat | Author of Seam in Action
Registered Linux User #231597

http://mojavelinux.com
http://mojavelinux.com/seaminaction
http://in.relation.to/Bloggers/Dan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jsr-314-open-mirror/attachments/20090914/e4a011d4/attachment.html 


More information about the jsr-314-open-mirror mailing list