You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Jesse Kuhnert (JIRA)" <ta...@jakarta.apache.org> on 2006/12/09 23:49:21 UTC
[jira] Resolved: (TAPESTRY-1170) Problem with
dojo.validate.isInRange(), desired flexibility in Tapestry validators
[ http://issues.apache.org/jira/browse/TAPESTRY-1170?page=all ]
Jesse Kuhnert resolved TAPESTRY-1170.
-------------------------------------
Resolution: Fixed
Fixed as logged here http://trac.dojotoolkit.org/changeset/6865 . Dojo updated in tapestry now as well.
> Problem with dojo.validate.isInRange(), desired flexibility in Tapestry validators
> ----------------------------------------------------------------------------------
>
> Key: TAPESTRY-1170
> URL: http://issues.apache.org/jira/browse/TAPESTRY-1170
> Project: Tapestry
> Issue Type: Bug
> Components: Framework, JavaScript
> Affects Versions: 4.1.1
> Reporter: Greg Woolsey
> Assigned To: Jesse Kuhnert
> Fix For: 4.1.1
>
>
> The bug is really in dojo.validate.isInRange(), but it can be worked around with a change in the validator call.
> I have a custom validator that allows numeric values with comma separators. It uses dojo.validate.isInteger() with the separator parameter.
> This should work with dojo.validate.isInRange(), but it has a bug:
> value = value.replace(dojo.lang.has(flags,'separator')?flags.separator:',', '', 'g').
> replace(dojo.lang.has(flags,'symbol')?flags.symbol:'$', '');
> the default if flags does not have the separator property (which it won't from Min and Max) should be
> /,/g
> instead of ','. String.replace() doesn't take 3 parameters in IE 6, it takes 2, and the first one is a regular expression.
> I can redefine this function for now, but I'd like to see the Tapestry validators allow for configuration of separators too.
--
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: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org