From ac11af35dfe9dbbbdf04fe8e80ece7f89ac68445 Mon Sep 17 00:00:00 2001 From: sjl <1716605279@qq.com> Date: Wed, 22 Oct 2025 10:51:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E7=BB=93=E6=9E=9C=E5=B7=A6?= =?UTF-8?q?=E4=BE=A7=E6=A0=91=E9=A2=9C=E8=89=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/api/check/interface/index.ts | 1 + ...eDataCheckSingleChannelSingleTestPopup.vue | 58 ++++++++++++++++--- 2 files changed, 52 insertions(+), 7 deletions(-) diff --git a/frontend/src/api/check/interface/index.ts b/frontend/src/api/check/interface/index.ts index d99d99d..4932b23 100644 --- a/frontend/src/api/check/interface/index.ts +++ b/frontend/src/api/check/interface/index.ts @@ -142,6 +142,7 @@ export namespace CheckData { id: string code: string scriptName: string + resultFlag: number } // 用来描述 检测数据-左侧树结构 diff --git a/frontend/src/views/home/components/compareDataCheckSingleChannelSingleTestPopup.vue b/frontend/src/views/home/components/compareDataCheckSingleChannelSingleTestPopup.vue index 52fb4e8..31f005d 100644 --- a/frontend/src/views/home/components/compareDataCheckSingleChannelSingleTestPopup.vue +++ b/frontend/src/views/home/components/compareDataCheckSingleChannelSingleTestPopup.vue @@ -72,7 +72,17 @@ node-key="id" ref="treeRef" @node-click="handleNodeClick" - > + class="custom-tree" + > + + +
@@ -90,7 +100,13 @@ :key="item.value" :label="item.label" :value="item.value" - /> + > +
+ {{ item.label }} + {{ item.label }} + {{ item.label }} +
+ {{ rowList.scriptName }} @@ -122,6 +138,7 @@ :label="item.replace(/\.0$/, '')" :value="item" /> +
@@ -200,7 +217,7 @@ const selectedScriptName = ref('') const pattern = ref('') // 添加以下内容 const isWaveData = ref(false) -const scriptNameOptions = ref<{ label: string; value: string }[]>([]) +const scriptNameOptions = ref<{ label: string; value: string;resultFlag:number }[]>([]) // 表单数据 const formContent = reactive({ @@ -280,7 +297,8 @@ const initGetResult = async () => { // 设置录波数据相关的选项 scriptNameOptions.value = selectScript.value.map(item => ({ label: item.scriptName, - value: item.scriptName + value: item.scriptName, + resultFlag: item.resultFlag })) // 默认选中第一个选项 @@ -311,7 +329,7 @@ const initScriptData = async () => { let temp = response.data.map((item: any) => { return { ...item, - scriptName: item.scriptName + scriptName: item.scriptName } }) @@ -327,7 +345,8 @@ const initScriptData = async () => { temp2 = luoboItem.subItems.map((item: any) => { return { ...item, - scriptName: item.scriptName + scriptName: item.scriptName, + resultFlag: item.resultFlag ?? 0 // 假设默认值为 0 } }) } @@ -502,6 +521,7 @@ const getResults = async (code: any) => { } currentCheckItem.value = list[0] tesList.value = list + console.log('checkResultData:', tesList.value) checkResultData.value = res.data.resultMap rawTableData.value = res.data.rawDataMap }) @@ -573,6 +593,30 @@ defineExpose({