From a5258f1aa81c8736dc387fbc4d684bfe08ae2dc0 Mon Sep 17 00:00:00 2001 From: qianming Date: Fri, 14 Jan 2022 10:25:51 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=BB=E5=B8=83=E5=8A=A8=E6=80=81=E5=8F=AF?= =?UTF-8?q?=E8=A7=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../bigscreenDesigner/designer/index.vue | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/report-ui/src/views/bigscreenDesigner/designer/index.vue b/report-ui/src/views/bigscreenDesigner/designer/index.vue index 9313166c..53365880 100644 --- a/report-ui/src/views/bigscreenDesigner/designer/index.vue +++ b/report-ui/src/views/bigscreenDesigner/designer/index.vue @@ -461,6 +461,8 @@ export default { const screenData = this.handleBigScreen(data.dashboard); this.widgets = processData; this.dashboard = screenData; + this.bigscreenWidth = this.dashboard.width; + this.bigscreenHeight = this.dashboard.height; }, handleBigScreen(data) { const optionScreen = getToolByCode("screen").options; @@ -771,7 +773,23 @@ export default { // 将当前选中的组件,右侧属性值更新 widgetValueChanged(key, val) { if (this.screenCode == "screen") { + let newSetup = new Array(); this.dashboard = this.deepClone(val); + if(this.bigscreenWidth != this.dashboard.width){ + this.bigscreenWidth = this.dashboard.width + } + if(this.bigscreenHeight != this.dashboard.height){ + this.bigscreenHeight = this.dashboard.height + } + this.widgetOptions.setup.forEach(el => { + if(el.name == 'width'){ + el.value = this.bigscreenWidth + }else if(el.name == 'height'){ + el.value = this.bigscreenHeight + } + newSetup.push(el) + }); + this.widgetOptions.setup = newSetup } else { for (let i = 0; i < this.widgets.length; i++) { if (this.widgetIndex == i) { @@ -946,6 +964,8 @@ export default { border: 1px solid #3a4659; background: #282a30; } + .tools-item-text{ + } } }