fix: 定时任务表达式校验 (#4325)
Co-authored-by: chenjianxing <jianxing.chen@fit2cloud.com>
This commit is contained in:
parent
ab0ca371c9
commit
1458e08924
|
@ -312,26 +312,12 @@ function checkListField(value, minimal, maximal ) {
|
|||
values[j] = st[j];
|
||||
}
|
||||
|
||||
var previousValue = -1;
|
||||
|
||||
for (var i= 0; i < values.length; i++) {
|
||||
var currentValue = values[i];
|
||||
|
||||
if (!checkIntValue(currentValue, minimal, maximal, true)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
try {
|
||||
var val = parseInt(currentValue, 10);
|
||||
|
||||
if (val <= previousValue) {
|
||||
return false;
|
||||
} else {
|
||||
previousValue = val;
|
||||
}
|
||||
} catch (e) {
|
||||
// we have always an int
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue