fix(仪表板): 修复画布中存在查询按钮时,设置联动初次查询时没有带过滤条件问题 #7061
This commit is contained in:
parent
e8e15a0d5e
commit
363a31dcfc
@ -367,7 +367,9 @@ export default {
|
|||||||
show: 0
|
show: 0
|
||||||
},
|
},
|
||||||
view: {},
|
view: {},
|
||||||
cancelTime: null
|
cancelTime: null,
|
||||||
|
// 外部查询按钮是否已经触发 用来检查画布中如果存在查询按钮 是否被首次点击过 默认true
|
||||||
|
searchButtonReady: true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -422,7 +424,7 @@ export default {
|
|||||||
},
|
},
|
||||||
filter() {
|
filter() {
|
||||||
const filter = {}
|
const filter = {}
|
||||||
filter.filter = this.initLoad && this.cfilters?.length === 0 ? this.filters : this.cfilters
|
filter.filter = (this.initLoad && this.cfilters?.length === 0) || !this.searchButtonReady ? this.filters : this.cfilters
|
||||||
filter.linkageFilters = this.element.linkageFilters
|
filter.linkageFilters = this.element.linkageFilters
|
||||||
filter.outerParamsFilters = this.element.outerParamsFilters
|
filter.outerParamsFilters = this.element.outerParamsFilters
|
||||||
filter.drill = this.drillClickDimensionList
|
filter.drill = this.drillClickDimensionList
|
||||||
@ -585,7 +587,13 @@ export default {
|
|||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
bus.$on('tab-canvas-change', this.tabSwitch)
|
bus.$on('tab-canvas-change', this.tabSwitch)
|
||||||
|
bus.$on('trigger-search-button', this.triggerSearchButton)
|
||||||
this.bindPluginEvent()
|
this.bindPluginEvent()
|
||||||
|
this.$nextTick(() => {
|
||||||
|
if (this.filters && this.filters.length > 0) {
|
||||||
|
this.searchButtonReady = false
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
@ -624,6 +632,9 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
triggerSearchButton() {
|
||||||
|
this.searchButtonReady = true
|
||||||
|
},
|
||||||
groupFilter(filters) {
|
groupFilter(filters) {
|
||||||
const result = {
|
const result = {
|
||||||
ready: [],
|
ready: [],
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user