You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Howard M. Lewis Ship (JIRA)" <ta...@jakarta.apache.org> on 2005/08/02 01:48:36 UTC

[jira] Updated: (TAPESTRY-413) Allow access to component message catalog from validators: binding string

     [ http://issues.apache.org/jira/browse/TAPESTRY-413?page=all ]

Howard M. Lewis Ship updated TAPESTRY-413:
------------------------------------------

        Summary: Allow access to component message catalog from validators: binding string  (was: Simple change of standard validator messages)
           type: Improvement  (was: Wish)
    Description: 
It seems the new 'validators' is deprecating the old one. 
The new Validator format is very comfortable and easy to use and extend. 
However if one wishes to use one of the standard validators with a custom message, it requires one to abandon the elegant way validators are defined and create a List of beans "manually". 
It would be nice if one could integrate a custom message in the existing format.

Suggestions:
validators="minLength('hey, to short...')=5,...
or "minLength(field.password.to-short)=5,...
or "minLength(ognl:.../message:...)=5,...

or use a syntax that reference a bean instead of a validator:

validators="required,(myMinLength),..."










  was:
It seems the new 'validators' is deprecating the old one. 
The new Validator format is very comfortable and easy to use and extend. 
However if one wishes to use one of the standard validators with a custom message, it requires one to abandon the elegant way validators are defined and create a List of beans "manually". 
It would be nice if one could integrate a custom message in the existing format.

Suggestions:
validators="minLength('hey, to short...')=5,...
or "minLength(field.password.to-short)=5,...
or "minLength(ognl:.../message:...)=5,...

or use a syntax that reference a bean instead of a validator:

validators="required,(myMinLength),..."








        Version: 4.0
      Assign To: Howard M. Lewis Ship

My thought was to borrow from Eclipse syntax, i.e.

validators:required[%user-id-required]

To reference the user-id-required property of the catalog.

> Allow access to component message catalog from validators: binding string
> -------------------------------------------------------------------------
>
>          Key: TAPESTRY-413
>          URL: http://issues.apache.org/jira/browse/TAPESTRY-413
>      Project: Tapestry
>         Type: Improvement
>     Versions: 4.0
>     Reporter: Ron Piterman
>     Assignee: Howard M. Lewis Ship

>
> It seems the new 'validators' is deprecating the old one. 
> The new Validator format is very comfortable and easy to use and extend. 
> However if one wishes to use one of the standard validators with a custom message, it requires one to abandon the elegant way validators are defined and create a List of beans "manually". 
> It would be nice if one could integrate a custom message in the existing format.
> Suggestions:
> validators="minLength('hey, to short...')=5,...
> or "minLength(field.password.to-short)=5,...
> or "minLength(ognl:.../message:...)=5,...
> or use a syntax that reference a bean instead of a validator:
> validators="required,(myMinLength),..."

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


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-dev-help@jakarta.apache.org