From 8f4c519e7d33463c28f5af198f1914bb911728d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=98=89=E8=B1=AA?= <42510293+ziyujiahao@users.noreply.github.com> Date: Fri, 27 Feb 2026 12:33:47 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E4=BB=AA=E8=A1=A8=E6=9D=BF=E3=80=81?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=E6=9F=A5=E8=AF=A2?= =?UTF-8?q?=E7=BB=84=E4=BB=B6=E4=BF=AE=E6=94=B9PC=E7=AB=AF=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E5=80=BC=EF=BC=8C=E7=A7=BB=E5=8A=A8=E7=AB=AF=E4=B9=9F?= =?UTF-8?q?=E8=83=BD=E6=9B=B4=E6=96=B0=20#17895=20(#17985)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/core-frontend/package.json | 1 + .../src/store/modules/data-visualization/copy.ts | 1 - core/core-frontend/src/utils/canvasUtils.ts | 11 +++-------- .../src/views/dashboard/MobileConfigPanel.vue | 6 ------ core/core-frontend/src/views/mobile/panel/index.vue | 8 ++------ 5 files changed, 6 insertions(+), 21 deletions(-) diff --git a/core/core-frontend/package.json b/core/core-frontend/package.json index 25f77b832f..afe9d7a6f7 100644 --- a/core/core-frontend/package.json +++ b/core/core-frontend/package.json @@ -3,6 +3,7 @@ "private": true, "version": "0.0.0", "scripts": { + "dev:win": "set NODE_OPTIONS=--max_old_space_size=4096 && vite --mode dev --host 0.0.0.0", "dev": "NODE_OPTIONS=--max_old_space_size=4096 vite --mode dev --host 0.0.0.0", "build:flush": "cd ./flushbonading && rimraf ./demo.html && npm i && node ./index.js", "ts:check": "vue-tsc --noEmit", diff --git a/core/core-frontend/src/store/modules/data-visualization/copy.ts b/core/core-frontend/src/store/modules/data-visualization/copy.ts index e529f77249..777d4884ff 100644 --- a/core/core-frontend/src/store/modules/data-visualization/copy.ts +++ b/core/core-frontend/src/store/modules/data-visualization/copy.ts @@ -213,7 +213,6 @@ function deepCopyHelper(data, idMap) { result.inMobile = false delete result.mStyle delete result.mEvents - delete result.mPropValue delete result.mCommonBackground if (result.component === 'VQuery') { result.propValue?.forEach(queryItem => { diff --git a/core/core-frontend/src/utils/canvasUtils.ts b/core/core-frontend/src/utils/canvasUtils.ts index e1c6ffa0bd..7e7413cfab 100644 --- a/core/core-frontend/src/utils/canvasUtils.ts +++ b/core/core-frontend/src/utils/canvasUtils.ts @@ -488,17 +488,15 @@ export async function backCanvasData(dvId, mobileViewInfo, busiFlag, callBack) { componentData.value.forEach(ele => { ele.inMobile = componentDataId.includes(ele.id) if (ele.inMobile) { - const { mx, my, mSizeX, mSizeY, mPropValue, mEvents, mCommonBackground } = - componentDataCopy.find(itx => itx.id === ele.id) + const { mx, my, mSizeX, mSizeY, mEvents, mCommonBackground } = componentDataCopy.find( + itx => itx.id === ele.id + ) ele.mx = mx ele.my = my ele.mSizeX = mSizeX ele.mSizeY = mSizeY ele.mEvents = mEvents ele.mCommonBackground = mCommonBackground - if (ele.component === 'VQuery') { - ele.mPropValue = mPropValue - } } }) Object.keys(canvasViewInfoPreview).forEach(key => { @@ -541,7 +539,6 @@ export function initCanvasDataMobile(dvId, params, callBack) { mSizeX, mSizeY, mStyle, - mPropValue, mEvents, mCommonBackground, style, @@ -554,14 +551,12 @@ export function initCanvasDataMobile(dvId, params, callBack) { ele.sizeX = mSizeX ele.sizeY = mSizeY ele.style = mStyle || style - ele.propValue = mPropValue || propValue ele.events = mEvents || events ele.commonBackground = mCommonBackground || commonBackground if (ele.component === 'DeTabs') { ele.propValue?.forEach(tabItem => { tabItem.componentData?.forEach(tabComponent => { tabComponent.style = tabComponent.mStyle || tabComponent.style - tabComponent.propValue = tabComponent.mPropValue || tabComponent.propValue tabComponent.events = tabComponent.mEvents || tabComponent.events tabComponent.commonBackground = tabComponent.mCommonBackground || tabComponent.commonBackground diff --git a/core/core-frontend/src/views/dashboard/MobileConfigPanel.vue b/core/core-frontend/src/views/dashboard/MobileConfigPanel.vue index 1622faf7d5..eb9379b469 100644 --- a/core/core-frontend/src/views/dashboard/MobileConfigPanel.vue +++ b/core/core-frontend/src/views/dashboard/MobileConfigPanel.vue @@ -149,9 +149,6 @@ const hanedleMessage = event => { ele.mStyle = style ele.mEvents = events ele.mCommonBackground = commonBackground - if (ele.component === 'VQuery') { - ele.mPropValue = propValue - } if (ele.component === 'DeTabs') { ele.propValue.forEach(tabItem => { tabItem.componentData?.forEach(tabComponent => { @@ -164,9 +161,6 @@ const hanedleMessage = event => { tabComponent.mStyle = tStyle tabComponent.mEvents = tEvents tabComponent.mCommonBackground = tCommonBackground - if (tabComponent.component === 'VQuery') { - tabComponent.mPropValue = tPropValue - } }) }) } diff --git a/core/core-frontend/src/views/mobile/panel/index.vue b/core/core-frontend/src/views/mobile/panel/index.vue index e4b39546e6..a8c9a3fc58 100644 --- a/core/core-frontend/src/views/mobile/panel/index.vue +++ b/core/core-frontend/src/views/mobile/panel/index.vue @@ -23,7 +23,7 @@ const hanedleMessage = event => { if (event.data.type === 'panelInit') { const { componentData, canvasStyleData, dvInfo, canvasViewInfo, isEmbedded } = event.data.value componentData.forEach(ele => { - const { mx, my, mSizeX, mSizeY, mStyle, mCommonBackground, mEvents, mPropValue } = ele + const { mx, my, mSizeX, mSizeY, mStyle, mCommonBackground, mEvents } = ele ele.x = mx ele.y = my ele.sizeX = mSizeX @@ -31,9 +31,6 @@ const hanedleMessage = event => { ele.style = deepCopy(mStyle || ele.style) ele.commonBackground = deepCopy(mCommonBackground || ele.commonBackground) ele.events = deepCopy(mEvents || ele.events) - if (ele.component === 'VQuery') { - ele.propValue = deepCopy(mPropValue || ele.propValue) - } if (ele.component === 'DeTabs') { ele.propValue?.forEach(tabItem => { @@ -41,8 +38,7 @@ const hanedleMessage = event => { const { mStyle: tStyle, mCommonBackground: tCommonBackground, - mEvents: tEvents, - mPropValue: tPropValue + mEvents: tEvents } = tabComponent tabComponent.style = deepCopy(tStyle || tabComponent.style) tabComponent.commonBackground = deepCopy(