2021-04-01 17:40:12 +08:00
|
|
|
<template>
|
|
|
|
<de-container>
|
|
|
|
<de-aside-container>
|
|
|
|
<el-tabs v-model="activeName" @tab-click="handleClick">
|
|
|
|
<el-tab-pane name="PanelList">
|
|
|
|
<span slot="label"><i class="el-icon-document" />列表</span>
|
|
|
|
<panel-list />
|
|
|
|
</el-tab-pane>
|
2021-04-20 14:19:10 +08:00
|
|
|
<el-tab-pane name="panels_star" :lazy="true">
|
2021-04-01 17:40:12 +08:00
|
|
|
<span slot="label"><i class="el-icon-star-off" />收藏</span>
|
2021-04-20 14:19:10 +08:00
|
|
|
<enshrine v-if="showEnshrine" />
|
2021-04-01 17:40:12 +08:00
|
|
|
</el-tab-pane>
|
|
|
|
<el-tab-pane name="panels_share" :lazy="true">
|
|
|
|
<span slot="label"><i class="el-icon-share" />分享</span>
|
|
|
|
<share-tree v-if="showShare" />
|
|
|
|
</el-tab-pane>
|
|
|
|
</el-tabs>
|
|
|
|
</de-aside-container>
|
|
|
|
<de-main-container>
|
|
|
|
<PanelViewShow />
|
|
|
|
</de-main-container>
|
|
|
|
</de-container>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
import DeMainContainer from '@/components/dataease/DeMainContainer'
|
|
|
|
import DeContainer from '@/components/dataease/DeContainer'
|
|
|
|
import DeAsideContainer from '@/components/dataease/DeAsideContainer'
|
|
|
|
import PanelList from '../list/PanelList'
|
|
|
|
import PanelViewShow from '../list/PanelViewShow'
|
|
|
|
import ShareTree from '../GrantAuth/shareTree'
|
2021-04-20 14:19:10 +08:00
|
|
|
import Enshrine from '../enshrine/index'
|
2021-04-01 17:40:12 +08:00
|
|
|
|
|
|
|
export default {
|
|
|
|
name: 'PanelMain',
|
2021-04-20 14:19:10 +08:00
|
|
|
components: { DeMainContainer, DeContainer, DeAsideContainer, PanelList, PanelViewShow, ShareTree, Enshrine },
|
2021-04-01 17:40:12 +08:00
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
activeName: 'PanelList',
|
2021-04-20 14:19:10 +08:00
|
|
|
showShare: false,
|
|
|
|
showEnshrine: false
|
2021-04-01 17:40:12 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
handleClick(tab, event) {
|
|
|
|
// 点击分析面板需要刷新分享内容
|
|
|
|
if (tab.name === 'panels_share') {
|
|
|
|
this.refreshShare()
|
|
|
|
}
|
2021-04-20 14:19:10 +08:00
|
|
|
if (tab.name === 'panels_star') {
|
|
|
|
this.refreshEnshrine()
|
|
|
|
}
|
2021-04-01 17:40:12 +08:00
|
|
|
},
|
|
|
|
refreshShare() {
|
|
|
|
this.showShare = false
|
|
|
|
this.$nextTick(() => (this.showShare = true))
|
2021-04-20 14:19:10 +08:00
|
|
|
},
|
|
|
|
refreshEnshrine() {
|
|
|
|
this.showEnshrine = false
|
|
|
|
this.$nextTick(() => (this.showEnshrine = true))
|
2021-04-01 17:40:12 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<style scoped>
|
|
|
|
.ms-aside-container {
|
|
|
|
height: calc(100vh - 56px);
|
2021-04-08 16:54:37 +08:00
|
|
|
padding: 0px;
|
2021-04-01 17:40:12 +08:00
|
|
|
min-width: 260px;
|
|
|
|
max-width: 460px;
|
|
|
|
}
|
|
|
|
.ms-main-container {
|
|
|
|
height: calc(100vh - 56px);
|
2021-04-08 16:54:37 +08:00
|
|
|
padding: 0px;
|
2021-04-01 17:40:12 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
</style>
|