fix:【仪表板】跳转至系统内仪表板时,出现先提示空白仪表板,再加载仪表板的情况
This commit is contained in:
parent
71365c4ba7
commit
12f73ef9a1
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div class="bg">
|
||||
<Preview />
|
||||
<div v-loading="dataLoading" class="bg">
|
||||
<Preview v-show="!dataLoading" />
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
@ -12,14 +12,21 @@ import { queryPanelJumpInfo, queryTargetPanelJumpInfo } from '@/api/panel/linkJu
|
||||
|
||||
export default {
|
||||
components: { Preview },
|
||||
data() {
|
||||
return {
|
||||
dataLoading: false
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
this.restore()
|
||||
},
|
||||
methods: {
|
||||
restore() {
|
||||
this.dataLoading = true
|
||||
this.panelId = this.$route.path.split('/')[2]
|
||||
// 加载视图数据
|
||||
findOne(this.panelId).then(response => {
|
||||
this.dataLoading = false
|
||||
this.$store.commit('setComponentData', this.resetID(JSON.parse(response.data.panelData)))
|
||||
this.$store.commit('setCanvasStyle', JSON.parse(response.data.panelStyle))
|
||||
const data = {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user