Merge pull request #3958 from dataease/pr@dev@fix_gauge

fix(数据集): 修复仪表盘阈值不支持小数的问题
This commit is contained in:
dataeaseShu 2022-11-30 14:31:00 +08:00 committed by GitHub
commit 96afec967d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -369,7 +369,7 @@ export default {
const arr = this.thresholdForm.gaugeThreshold.split(',')
for (let i = 0; i < arr.length; i++) {
const ele = arr[i]
if (parseFloat(ele).toString() === 'NaN' || parseFloat(ele) < 1 || parseFloat(ele) > 99) {
if (parseFloat(ele).toString() === 'NaN' || parseFloat(ele) <= 0 || parseFloat(ele) >= 100) {
this.$message({
message: this.$t('chart.gauge_threshold_format_error'),
type: 'error',