From 74c1d2b249de41f2230a4bbfdc09ad7f34f3dbf8 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Mon, 29 Aug 2022 17:59:41 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E4=BB=AA=E8=A1=A8=E6=9D=BF):=20?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=87=AA=E5=8A=A8=E7=BC=93=E5=AD=98=E7=9A=84?= =?UTF-8?q?=E9=99=84=E5=8A=A0=E4=BF=A1=E6=81=AF=EF=BC=8C=E9=98=B2=E6=AD=A2?= =?UTF-8?q?=E7=BC=96=E8=BE=91=E7=95=8C=E9=9D=A2=E6=B2=A1=E6=9C=89=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/canvas/components/Toolbar.vue | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/frontend/src/components/canvas/components/Toolbar.vue b/frontend/src/components/canvas/components/Toolbar.vue index f8438a7f96..ba47aeebba 100644 --- a/frontend/src/components/canvas/components/Toolbar.vue +++ b/frontend/src/components/canvas/components/Toolbar.vue @@ -337,7 +337,11 @@ export default { const _this = this _this.timer = setInterval(() => { if (_this.$store.state.cacheStyleChangeTimes > 0) { - const cacheRequest = _this.savePrepare() + const requestInfo = _this.savePrepare() + const cacheRequest ={ + ...this.panelInfo, + ...requestInfo + } saveCache(cacheRequest) _this.$store.state.cacheStyleChangeTimes = 0 } @@ -346,8 +350,7 @@ export default { savePrepare() { // 保存到数据库 const requestInfo = { - ... - this.panelInfo, + id: this.panelInfo.id, panelStyle: JSON.stringify(this.canvasStyleData), panelData: JSON.stringify(this.componentData) }