Merge pull request #4416 from dataease/pr@dev@fix_number_range_filter

fix(仪表板): 数字区间过滤器空默认值无法替换编辑时填写的值
This commit is contained in:
fit2cloud-chenyw 2023-01-30 15:53:19 +08:00 committed by GitHub
commit 1ef87e5950
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

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()
}
},