diff options
author | xue <> | 2006-07-29 14:43:53 +0000 |
---|---|---|
committer | xue <> | 2006-07-29 14:43:53 +0000 |
commit | e0c9de073cce5b5c9975694c03e2dbe63788bd66 (patch) | |
tree | 0c04506594635064d9f3f62eb45c8aad5c3be685 /framework/Web/Javascripts/prado | |
parent | 6385105e7793509de726b2941d038840c04195c1 (diff) |
Merge from 3.0 branch till 1305.
Diffstat (limited to 'framework/Web/Javascripts/prado')
-rw-r--r-- | framework/Web/Javascripts/prado/validation3.js | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/framework/Web/Javascripts/prado/validation3.js b/framework/Web/Javascripts/prado/validation3.js index 9535f8c5..1dba23da 100644 --- a/framework/Web/Javascripts/prado/validation3.js +++ b/framework/Web/Javascripts/prado/validation3.js @@ -1113,11 +1113,20 @@ Prado.WebUI.TRangeValidator = Class.extend(Prado.WebUI.TBaseValidator, return true;
if(typeof(this.options.DataType) == "undefined")
this.options.DataType = "String";
-
- var min = this.convert(this.options.DataType, this.options.MinValue || null);
- var max = this.convert(this.options.DataType, this.options.MaxValue || null);
- value = this.convert(this.options.DataType, value);
-
+
+ if(this.options.DataType != "StringLength")
+ {
+ var min = this.convert(this.options.DataType, this.options.MinValue || null);
+ var max = this.convert(this.options.DataType, this.options.MaxValue || null);
+ value = this.convert(this.options.DataType, value);
+ }
+ else
+ {
+ var min = this.options.MinValue || 0;
+ var max = this.options.MaxValue || Number.POSITIVE_INFINITY;
+ value = value.length;
+ }
+
if(value == null)
return false;
|