From 7f2daa04dfc2d9605212c2c455279a51a97d5810 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Fri, 13 Aug 2021 15:45:43 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=E4=BC=98=E5=8C=96=E4=B8=8B=E9=92=BB?= =?UTF-8?q?=EF=BC=8C=E8=81=94=E5=8A=A8=E5=BC=B9=E5=87=BA=E7=AA=97=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/canvas/components/Editor/PreviewEject.vue | 6 ++++++ frontend/src/views/link/view/index.vue | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/frontend/src/components/canvas/components/Editor/PreviewEject.vue b/frontend/src/components/canvas/components/Editor/PreviewEject.vue index b290d689bd..d79ca08a0e 100644 --- a/frontend/src/components/canvas/components/Editor/PreviewEject.vue +++ b/frontend/src/components/canvas/components/Editor/PreviewEject.vue @@ -7,6 +7,8 @@ import Preview from './Preview' import { uuid } from 'vue-uuid' import { findOne } from '@/api/panel/panel' +import { getPanelAllLinkageInfo } from '@/api/panel/linkage' + export default { components: { Preview }, @@ -24,6 +26,10 @@ export default { id: response.data.id, name: response.data.name } + // 刷新联动信息 + getPanelAllLinkageInfo(this.panelId).then(rsp => { + this.$store.commit('setNowPanelTrackInfo', rsp.data) + }) this.$store.dispatch('panel/setPanelInfo', data) }) }, diff --git a/frontend/src/views/link/view/index.vue b/frontend/src/views/link/view/index.vue index c92b5fc478..b2b1a1cbf4 100644 --- a/frontend/src/views/link/view/index.vue +++ b/frontend/src/views/link/view/index.vue @@ -8,6 +8,8 @@ import { loadResource } from '@/api/link' import { uuid } from 'vue-uuid' import Preview from '@/components/canvas/components/Editor/Preview' +import { getPanelAllLinkageInfo } from '@/api/panel/linkage' + export default { name: 'LinkView', components: { Preview }, @@ -29,6 +31,10 @@ export default { methods: { setPanelInfo() { loadResource(this.resourceId).then(res => { + // 刷新联动信息 + getPanelAllLinkageInfo(this.resourceId).then(rsp => { + this.$store.commit('setNowPanelTrackInfo', rsp.data) + }) this.$store.commit('setComponentData', this.resetID(JSON.parse(res.data.panelData))) // this.$store.commit('setComponentData', JSON.parse(res.data.panelData)) this.$store.commit('setCanvasStyle', JSON.parse(res.data.panelStyle))