From 045acfa061d7419e2ea675ecffbb3f3a6b026428 Mon Sep 17 00:00:00 2001 From: sjl <1716605279@qq.com> Date: Tue, 14 Oct 2025 20:54:35 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=A1=E5=88=92=E9=BB=98=E8=AE=A4=E4=B8=8D?= =?UTF-8?q?=E5=8B=BE=E9=80=89=E9=97=AA=E5=8F=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../plan/planList/components/planPopup.vue | 19 +++++++++++++------ frontend/src/views/plan/planList/index.vue | 3 ++- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/frontend/src/views/plan/planList/components/planPopup.vue b/frontend/src/views/plan/planList/components/planPopup.vue index 75aa7cc..4171467 100644 --- a/frontend/src/views/plan/planList/components/planPopup.vue +++ b/frontend/src/views/plan/planList/components/planPopup.vue @@ -752,7 +752,7 @@ const open = async (sign: string, data: Plan.ReqPlan, currentMode: string, plan: user_Result: any if (mode.value === '比对式') { - ;[ + [ PqErrSys_Result, pqDevList_Result, pqReportName_Result, @@ -792,7 +792,7 @@ const open = async (sign: string, data: Plan.ReqPlan, currentMode: string, plan: } } } else { - ;[pqSource_Result, PqScript_Result, PqErrSys_Result, pqDevList_Result, pqReportName_Result] = + [pqSource_Result, PqScript_Result, PqErrSys_Result, pqDevList_Result, pqReportName_Result] = await Promise.all([ getTestSourceList(data), getPqScriptList(data), @@ -825,7 +825,10 @@ const open = async (sign: string, data: Plan.ReqPlan, currentMode: string, plan: formContent.errorSysId = pqErrSysList.value[0]?.id ?? '' formContent.sourceIds = pqSourceList.value[0]?.id ?? '' const datasourceDicts = dictStore.getDictData('Datasource') - formContent.datasourceIds = [datasourceDicts[0]?.code] ?? [] + + formContent.datasourceIds = datasourceDicts + .filter(item => ['real', 'wave_data'].includes(item.code)) + .map(item => item.code) } else { //编辑时先给表单赋值(这会没接收被检设备),需要手动再给被检设备复制后整体表单赋值 @@ -902,7 +905,7 @@ const open = async (sign: string, data: Plan.ReqPlan, currentMode: string, plan: } } } else { - ;[ + [ pqSource_Result, PqScript_Result, PqErrSys_Result, @@ -1052,7 +1055,9 @@ const handleErrorSysChange = async (value: string) => { }) }) } - formContent.testItems = secondLevelOptions.map(option => option.value) + formContent.testItems = secondLevelOptions + .filter(option => option.label !== '闪变') + .map(option => option.value) } catch (error) { formContent.testItems = [] console.error('获取检测项失败:', error) @@ -1083,7 +1088,9 @@ const loadTestItemsForErrorSys = async (errorSysId: string) => { label: (res.data as Record)[key] }) }) - formContent.testItems = secondLevelOptions.map(option => option.value) + formContent.testItems = secondLevelOptions + .filter(option => option.label !== '闪变') + .map(option => option.value) } } catch (error) { console.error('获取检测项失败:', error) diff --git a/frontend/src/views/plan/planList/index.vue b/frontend/src/views/plan/planList/index.vue index 0ae6774..36f7cb2 100644 --- a/frontend/src/views/plan/planList/index.vue +++ b/frontend/src/views/plan/planList/index.vue @@ -43,6 +43,7 @@ v-auth.plan="'analysis'" icon="DataLine" :disabled="!scope.isSelected" + v-if=" modeStore.currentMode != '比对式'" @click="statisticalAnalysisMore(scope.selectedListIds, scope.selectedList)" > 统计分析 @@ -104,7 +105,7 @@ v-auth.plan="'analysis'" link icon="DataLine" - v-if="scope.row.testState == '2'" + v-if="scope.row.testState == '2' && modeStore.currentMode != '比对式'" @click="statisticalAnalysis(scope.row)" > 统计分析