mirror of
https://github.com/ONLYOFFICE/web-apps.git
synced 2026-07-24 12:05:33 +08:00
[SSE] Bug 65923
This commit is contained in:
@ -305,16 +305,6 @@ define([
|
||||
},
|
||||
|
||||
getSettings: function () {
|
||||
if (this.isStepChanged) {
|
||||
var value = this.inputStep.getValue();
|
||||
(typeof value === 'string') && (value = value.replace(',','.'));
|
||||
this._changedProps.asc_setStepValue(value!=='' ? parseFloat(value) : null);
|
||||
}
|
||||
if (this.isStopChanged) {
|
||||
var value = this.inputStop.getValue();
|
||||
(typeof value === 'string') && (value = value.replace(',','.'));
|
||||
this._changedProps.asc_setStopValue(value!=='' ? parseFloat(value) : null);
|
||||
}
|
||||
return this._changedProps;
|
||||
},
|
||||
|
||||
@ -338,26 +328,25 @@ define([
|
||||
},
|
||||
|
||||
isValid: function() {
|
||||
var regstr = new RegExp('^\s*[+-]?([0-9]+([.][0-9]*)?|[.][0-9]+)\s*$');
|
||||
if (this.isStepChanged) {
|
||||
var value = this.inputStep.getValue();
|
||||
(typeof value === 'string') && (value = value.replace(',','.'));
|
||||
if (value!=='' && (!regstr.test(value.trim()) || isNaN(parseFloat(value)))) {
|
||||
var res = this._changedProps.asc_isValidStepValue(this.inputStep.getValue());
|
||||
if (res[0]!==Asc.c_oAscError.ID.No || res[1]===null) {
|
||||
this.inputStep.showError([this.txtErrorNumber]);
|
||||
this.inputStep.focus();
|
||||
this.isInputStepFirstChange = true;
|
||||
return false;
|
||||
}
|
||||
} else
|
||||
this._changedProps.asc_setStepValue(res[1]);
|
||||
}
|
||||
if (this.isStopChanged) {
|
||||
var value = this.inputStop.getValue();
|
||||
(typeof value === 'string') && (value = value.replace(',','.'));
|
||||
if (value!=='' && (!regstr.test(value.trim()) || isNaN(parseFloat(value)))) {
|
||||
var res = this._changedProps.asc_isValidStepValue(this.inputStop.getValue());
|
||||
if (res[0]!==Asc.c_oAscError.ID.No || res[1]===null) {
|
||||
this.inputStop.showError([this.txtErrorNumber]);
|
||||
this.inputStop.focus();
|
||||
this.isInputStopFirstChange = true;
|
||||
return false;
|
||||
}
|
||||
} else
|
||||
this._changedProps.asc_setStopValue(res[1]);
|
||||
}
|
||||
return true;
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user