From 4f28f7e71857a981d55fc5b2ed362e6a9455d895 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=B9=E5=BA=B7?= <1787984719@qq.com> Date: Thu, 23 May 2024 18:31:04 +0800 Subject: [PATCH] =?UTF-8?q?modify=20=E4=B8=BA=E5=A4=A7=E5=B1=8F=E6=8A=A5?= =?UTF-8?q?=E8=A1=A8=E5=9B=BE=E5=B1=82=E6=96=B0=E5=A2=9E=E5=9B=BE=E5=B1=82?= =?UTF-8?q?=E7=AD=9B=E9=80=89=E5=8A=9F=E8=83=BD=20fix=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E5=A4=A7=E5=B1=8F=E6=8A=A5=E8=A1=A8=E5=8F=B3=E4=BE=A7=E5=8A=A8?= =?UTF-8?q?=E6=80=81=E6=95=B0=E6=8D=AE=E4=B8=AD=20=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E5=80=BC=E6=80=BB=E6=98=AF=E4=B8=BA=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E9=9B=86=E7=A4=BA=E4=BE=8B=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../designer/components/dynamicComponents.vue | 11 ++- .../bigscreenDesigner/designer/index.vue | 69 +++++++++++++++++-- 2 files changed, 75 insertions(+), 5 deletions(-) diff --git a/report-ui/src/views/bigscreenDesigner/designer/components/dynamicComponents.vue b/report-ui/src/views/bigscreenDesigner/designer/components/dynamicComponents.vue index 1fffe713..f0e20927 100644 --- a/report-ui/src/views/bigscreenDesigner/designer/components/dynamicComponents.vue +++ b/report-ui/src/views/bigscreenDesigner/designer/components/dynamicComponents.vue @@ -148,7 +148,16 @@ export default { echoDynamicData(val) { const chartProperties = this.deepClone(val.chartProperties); this.chartProperties = chartProperties; - if (this.userNameList.length > 0) { + let defaultData + if (this.userNameList.length > 0 && (defaultData = Object.keys(this.formData.contextData)).length) { + for(let key of defaultData) { + for(let user of this.userNameList) { + if(user.paramName === key) { + user.sampleItem = this.formData.contextData[key] + break + } + } + } } if (this.setParamList.length > 0) { for (let i = 0; i < this.setParamList.length; i++) { diff --git a/report-ui/src/views/bigscreenDesigner/designer/index.vue b/report-ui/src/views/bigscreenDesigner/designer/index.vue index bc2a36f7..a636fcd0 100644 --- a/report-ui/src/views/bigscreenDesigner/designer/index.vue +++ b/report-ui/src/views/bigscreenDesigner/designer/index.vue @@ -43,18 +43,32 @@ + + + + + + + + + + + -
@@ -416,6 +430,10 @@ export default { currentSizeRangeIndex: -1, // 当前是哪个缩放比分比, currentWidgetTotal: 0, widgetParamsConfig: [], // 各组件动态数据集的参数配置情况 + layerFilter: { + layerName: '', + layerType: '' + } }; }, computed: { @@ -454,6 +472,24 @@ export default { this.getPXUnderScale(this.bigscreenHeight) + this.widthPaddingTools ); }, + layerWidgetType() { + return [...new Set(this.layerWidget.map(({code}) => code))].map(code => ({label: code.split('widget-').filter(item => item)[0], code})) + }, + layerFilterChange() { + let list = [] + for (let index = 0; index < this.layerWidget.length; index++) { + let item = JSON.parse(JSON.stringify(this.layerWidget[index])) + if(this.layerFilter.layerName && !item.label.includes(this.layerFilter.layerName)) { + continue + } + if(this.layerFilter.layerType && !(item.code === this.layerFilter.layerType)) { + continue + } + item._$index = index + list.push(item) + } + return list + } }, watch: { widgets: { @@ -740,4 +776,29 @@ export default { -- Gitee