forked from github/dataease
fix: 修复收藏tab切换至仪表板tab页面右侧没有内容显示
This commit is contained in:
parent
686edb3456
commit
63edb86766
@ -77,6 +77,11 @@ export default {
|
|||||||
if (newVal === 'PanelMain' && this.lastActiveNodeData) {
|
if (newVal === 'PanelMain' && this.lastActiveNodeData) {
|
||||||
this.activeNodeAndClickOnly(this.lastActiveNodeData)
|
this.activeNodeAndClickOnly(this.lastActiveNodeData)
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
activeName: function(newVal, oldVal) {
|
||||||
|
if (newVal !== 'PanelMain') {
|
||||||
|
this.clear()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@ -93,6 +98,15 @@ export default {
|
|||||||
// this.clear()
|
// this.clear()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
clear() {
|
||||||
|
// 清空
|
||||||
|
this.$store.dispatch('panel/setPanelInfo', {
|
||||||
|
id: null,
|
||||||
|
name: '',
|
||||||
|
preStyle: null
|
||||||
|
})
|
||||||
|
this.$store.dispatch('panel/setMainActiveName', 'PanelMain')
|
||||||
|
},
|
||||||
handleClick(tab, event) {
|
handleClick(tab, event) {
|
||||||
// 点击分析面板需要刷新分享内容
|
// 点击分析面板需要刷新分享内容
|
||||||
if (tab.name === 'panels_share') {
|
if (tab.name === 'panels_share') {
|
||||||
|
Loading…
Reference in New Issue
Block a user