Browse Source

Merge pull request #250 in ~GUY/fineui from ~WINDY/fineui:BI4.1 to BI4.1

* commit '78b775d5c1e20a38c3a1aefbe41deb6c2fb67b72':
  处理一下90.0这样的
es6
windy 7 years ago
parent
commit
4deba2da0e
  1. 7
      bi/widget.js
  2. 7
      dist/bundle.js
  3. 4
      dist/bundle.min.js
  4. 7
      dist/widget.js
  5. 7
      src/widget/intervalslider/intervalslider.js

7
bi/widget.js

@ -5911,14 +5911,19 @@ BI.IntervalSlider = BI.inherit(BI.Widget, {
_checkValidation: function (v) {
var o = this.options;
var valid = false;
//像90.这样的既不属于整数又不属于小数,是不合法的值
var dotText = (v + "").split(".")[1];
if (BI.isEmptyString(dotText)) {
}else{
if (BI.isNumeric(v) && !(BI.isNull(v) || v < this.min || v > this.max)) {
if(o.digit === false){
valid = true;
}else{
var dotText = (v + "").split(".")[1] || "";
dotText = dotText || "";
valid = (dotText.length === o.digit);
}
}
}
return valid;
},

7
dist/bundle.js vendored

@ -81154,14 +81154,19 @@ BI.IntervalSlider = BI.inherit(BI.Widget, {
_checkValidation: function (v) {
var o = this.options;
var valid = false;
//像90.这样的既不属于整数又不属于小数,是不合法的值
var dotText = (v + "").split(".")[1];
if (BI.isEmptyString(dotText)) {
}else{
if (BI.isNumeric(v) && !(BI.isNull(v) || v < this.min || v > this.max)) {
if(o.digit === false){
valid = true;
}else{
var dotText = (v + "").split(".")[1] || "";
dotText = dotText || "";
valid = (dotText.length === o.digit);
}
}
}
return valid;
},

4
dist/bundle.min.js vendored

File diff suppressed because one or more lines are too long

7
dist/widget.js vendored

@ -5911,14 +5911,19 @@ BI.IntervalSlider = BI.inherit(BI.Widget, {
_checkValidation: function (v) {
var o = this.options;
var valid = false;
//像90.这样的既不属于整数又不属于小数,是不合法的值
var dotText = (v + "").split(".")[1];
if (BI.isEmptyString(dotText)) {
}else{
if (BI.isNumeric(v) && !(BI.isNull(v) || v < this.min || v > this.max)) {
if(o.digit === false){
valid = true;
}else{
var dotText = (v + "").split(".")[1] || "";
dotText = dotText || "";
valid = (dotText.length === o.digit);
}
}
}
return valid;
},

7
src/widget/intervalslider/intervalslider.js

@ -295,14 +295,19 @@ BI.IntervalSlider = BI.inherit(BI.Widget, {
_checkValidation: function (v) {
var o = this.options;
var valid = false;
//像90.这样的既不属于整数又不属于小数,是不合法的值
var dotText = (v + "").split(".")[1];
if (BI.isEmptyString(dotText)) {
}else{
if (BI.isNumeric(v) && !(BI.isNull(v) || v < this.min || v > this.max)) {
if(o.digit === false){
valid = true;
}else{
var dotText = (v + "").split(".")[1] || "";
dotText = dotText || "";
valid = (dotText.length === o.digit);
}
}
}
return valid;
},

Loading…
Cancel
Save