|
@ -148,37 +148,38 @@ |
|
|
Message.error("请求失败,请稍后再试"); |
|
|
Message.error("请求失败,请稍后再试"); |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
validateInput(value) { |
|
|
// validateInput(value) { |
|
|
const intValue = parseInt(value, 10); |
|
|
// const intValue = parseInt(value, 10); |
|
|
const limits = this.rangeLimits[this.controlObject]; |
|
|
// const limits = this.rangeLimits[this.controlObject]; |
|
|
if (isNaN(intValue) || intValue < limits.min || intValue > limits.max) { |
|
|
// if (isNaN(intValue) || intValue < limits.min || intValue > limits.max) { |
|
|
this.errorMessage = `请输入 ${limits.min}-${limits.max} 之间的数字`; |
|
|
// this.errorMessage = `请输入 ${limits.min}-${limits.max} 之间的数字`; |
|
|
if(this.controlObject=='000D'&&this.OOODValue!=''){ |
|
|
// if(this.controlObject=='000D'&&this.OOODValue!=''){ |
|
|
this.errorMessage += ` 当前值为:`+this.OOODValue; |
|
|
// this.errorMessage += ` 当前值为:`+this.OOODValue; |
|
|
this.openingPoint = this.OOODValue; |
|
|
// this.openingPoint = this.OOODValue; |
|
|
}else if(this.controlObject=='000E'&&this.OOOEValue!=''){ |
|
|
// }else if(this.controlObject=='000E'&&this.OOOEValue!=''){ |
|
|
this.errorMessage += ` 当前值为:`+this.OOOEValue; |
|
|
// this.errorMessage += ` 当前值为:`+this.OOOEValue; |
|
|
this.openingPoint = this.OOOEValue; |
|
|
// this.openingPoint = this.OOOEValue; |
|
|
}else if(this.controlObject=='000F'&&this.OOOFValue!=''){ |
|
|
// }else if(this.controlObject=='000F'&&this.OOOFValue!=''){ |
|
|
this.errorMessage += ` 当前值为:`+this.OOOFValue; |
|
|
// this.errorMessage += ` 当前值为:`+this.OOOFValue; |
|
|
this.openingPoint = this.OOOFValue; |
|
|
// this.openingPoint = this.OOOFValue; |
|
|
}else if(this.controlObject=='0010'&&this.OO1OValue!=''){ |
|
|
// }else if(this.controlObject=='0010'&&this.OO1OValue!=''){ |
|
|
this.errorMessage += ` 当前值为:`+this.OO1OValue; |
|
|
// this.errorMessage += ` 当前值为:`+this.OO1OValue; |
|
|
this.openingPoint = this.OO1OValue; |
|
|
// this.openingPoint = this.OO1OValue; |
|
|
} |
|
|
// } |
|
|
} else { |
|
|
// } else { |
|
|
this.errorMessage = ''; |
|
|
// this.errorMessage = ''; |
|
|
this.openingPoint = ''; |
|
|
// this.openingPoint = ''; |
|
|
} |
|
|
// } |
|
|
}, |
|
|
// }, |
|
|
onControlObjectChange(value) { |
|
|
onControlObjectChange(value) { |
|
|
console.log(value) |
|
|
console.log(value) |
|
|
// 当选择变化时,检查当前输入值是否仍在新的范围内 |
|
|
// 当选择变化时,检查当前输入值是否仍在新的范围内 |
|
|
const inputValue = parseInt(this.openingPoint, 10); |
|
|
const inputValue = parseInt(this.openingPoint, 10); |
|
|
const limits = this.rangeLimits[value]; |
|
|
const limits = this.rangeLimits[value]; |
|
|
|
|
|
|
|
|
if (isNaN(inputValue) || inputValue < limits.min || inputValue > limits.max) { |
|
|
// if (isNaN(inputValue) || inputValue < limits.min || inputValue > limits.max) { |
|
|
this.errorMessage = `请选择 ${limits.min}-${limits.max} 之间的数字`; |
|
|
this.errorMessage = `请选择 ${limits.min}-${limits.max} 之间的数字`; |
|
|
|
|
|
console.log(this.OOOEValue) |
|
|
if(value=='000D'&&this.OOODValue!=''){ |
|
|
if(value=='000D'&&this.OOODValue!=''){ |
|
|
this.errorMessage += ` 当前值为:` |
|
|
this.errorMessage += ` 当前值为:` |
|
|
this.openingPoint = this.OOODValue; |
|
|
this.openingPoint = this.OOODValue; |
|
@ -192,7 +193,8 @@ |
|
|
this.errorMessage += ` 当前值为:` |
|
|
this.errorMessage += ` 当前值为:` |
|
|
this.openingPoint = this.OO1OValue; |
|
|
this.openingPoint = this.OO1OValue; |
|
|
} |
|
|
} |
|
|
} else { |
|
|
// } |
|
|
|
|
|
else { |
|
|
this.errorMessage = ''; |
|
|
this.errorMessage = ''; |
|
|
this.openingPoint = ''; |
|
|
this.openingPoint = ''; |
|
|
} |
|
|
} |
|
|