From 010e51c0f6b378541b01162ca8e1dd95034a3c79 Mon Sep 17 00:00:00 2001 From: Melete Date: Thu, 16 Nov 2023 22:18:45 +0800 Subject: [PATCH] =?UTF-8?q?update=20=E5=B7=A5=E8=89=BA=E6=B5=81=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/ProcessBomList.vue | 31 +++++++++++++------ 1 file changed, 22 insertions(+), 9 deletions(-) diff --git a/src/views/extend/processFlowView/components/ProcessBomList.vue b/src/views/extend/processFlowView/components/ProcessBomList.vue index 904cb611..71183eee 100644 --- a/src/views/extend/processFlowView/components/ProcessBomList.vue +++ b/src/views/extend/processFlowView/components/ProcessBomList.vue @@ -67,7 +67,11 @@ @close="cancel" @cancel="cancel" @confirm="submitForm"> - + + + @@ -125,9 +129,9 @@ export default { }, }, methods: { - renderFn(h,option) { - console.log(option) - return 1 + renderFn(h, option) { + console.log(option); + return 1; }, async getEqList() { console.log('currentDet', this.currentDet); @@ -150,12 +154,21 @@ export default { { equipmentId: 6, equipmentName: '设备6' }, ]; // ].map((item) => ({ label: item.equipmentName, key: item.equipmentId })); - // 获取参数bom和物料bom - this.finalList = this.eqList.map((item) => { + // 需调用参数bom接口和 物料bom接口 + this.finalList = this.eqList.map((item) => { + item.sub = []; // key: equipmentId-参数bomId - item.push({ key: item.equipmentId + '-' + '101', label: '参数bom1' }); - item.push({ key: item.equipmentId + '-' + '201', label: '物料bom1' }); + item.sub.push({ + key: item.equipmentId + '-' + '101', + label: '参数bom1', + }); + item.sub.push({ + key: item.equipmentId + '-' + '201', + label: '物料bom1', + }); + + return item; }); } }, @@ -181,7 +194,7 @@ export default { data: method !== 'get' ? payload : null, }); }, - + submitForm() {}, async getList({ detId, detName, detDesc, flowId, sectionName } = {}) { console.log('get list', detId, detName, flowId); const { data, code } = await this.http(