From c8887e92ab3adb149d17234d5a150752f67f1be9 Mon Sep 17 00:00:00 2001 From: yufei_wang <2267742828@qq.com> Date: Mon, 21 Oct 2024 15:49:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=B6=E5=93=81=E5=AD=90=E4=BB=B6=E6=8A=A5?= =?UTF-8?q?=E5=BA=9F-=E7=BC=96=E8=BE=91=E5=BE=97=E6=97=B6=E5=80=99?= =?UTF-8?q?=EF=BC=8C=E5=AD=90=E8=A1=A8=E5=AD=97=E6=AE=B5=E4=B8=8D=E5=8F=AF?= =?UTF-8?q?=E7=BC=96=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../productscrapRequestMain/index.vue | 33 ++++++++----------- 1 file changed, 13 insertions(+), 20 deletions(-) diff --git a/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue b/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue index c974d9d8a..f5557cfc9 100644 --- a/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue +++ b/src/views/wms/productionManage/productscrap/productscrapRequestMain/index.vue @@ -776,36 +776,29 @@ const openForm =async (type: string, row?: number) => { defaultButtons.formCloseBtn(null) // 关闭 ] if(type == 'create'){ - ProductscrapRequestMain.allSchemas.formSchema.forEach((item) => { - if (item.field == 'workshopCode') { - item.componentProps.disabled = true - item.componentProps.isSearchList = true - } - if (item.field == 'scrappingReason'){ - item.value = '' - } if(item.field == 'productionLineCode'){ item.componentProps.disabled = false item.componentProps.enterSearch = true item.componentProps.isSearchList = true } + if(item.field == 'q3Number' || item.field == 'costCenterCode' || item.field == 'reasonCodeRequisition' || item.field == 'workshopCode' || item.field == 'productionLineCode'){ + // Q3通知单号 成本中心代码 原因代码 车间 生产线 + item.componentProps.enterSearch = true + item.componentProps.isSearchList = true + } + if (item.field == 'scrappingReason'){ // 报废原因 + item.value = '' + item.componentProps.disabled = false + } }) formRef.value.open(type, row) - } if(type == 'update'){ ProductscrapRequestMain.allSchemas.formSchema.forEach((item) => { - if (item.field == 'workshopCode') { - item.componentProps.disabled = true - item.componentProps.isSearchList = false - } - if(item.field == 'productionLineCode'){ - item.componentProps.enterSearch = true - item.componentProps.isSearchList = true - } - if(item.field == 'productionLineCode'){ - item.componentProps.disabled = true + item.componentProps.disabled = true + if(item.field == 'q3Number' || item.field == 'costCenterCode' || item.field == 'reasonCodeRequisition' || item.field == 'workshopCode' || item.field == 'productionLineCode'){ + // Q3通知单号 成本中心代码 原因代码 车间 生产线 item.componentProps.enterSearch = false item.componentProps.isSearchList = false } @@ -817,7 +810,7 @@ const openForm =async (type: string, row?: number) => { updateData['masterId'] = row['masterId'] tableData.value = updateData.subList||[] tableData.value.forEach(item=>{ - item['bomVersionInitOptions'] = item['bomList'].map(item1=>({ + item['bomVersionInitOptions'] = item['bomList']?.map(item1=>({ label:item1, value:item1 }))