fix(仪表板): 数字区间过滤器空默认值无法替换编辑时填写的值

This commit is contained in:
fit2cloud-chenyw 2023-01-30 15:46:59 +08:00
parent 930c57ad2d
commit 59f9202605

View File

@ -152,11 +152,17 @@ export default {
},
resetDefaultValue(id) {
if (this.inDraw && this.manualModify && this.element.id === id) {
const values = this.element.options.value
this.form.min = values[0]
if (values.length > 1) {
this.form.max = values[1]
if (!this.element.options.value) {
this.form.min = null
this.form.max = null
} else {
const values = this.element.options.value
this.form.min = values[0]
if (values.length > 1) {
this.form.max = values[1]
}
}
this.search()
}
},