From d639581f29a7908b37638f13f937c441368aecdf Mon Sep 17 00:00:00 2001 From: wangyufei <2267742828@qq.com> Date: Mon, 24 Jun 2024 09:40:03 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=A1=E5=88=92=E5=A4=96=E5=87=BA=E5=85=A5?= =?UTF-8?q?=E5=BA=93=EF=BC=8C=E5=A4=87=E4=BB=B6=E9=A2=86=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../index.vue | 26 +++++++++++++ .../unplannedissueRequestMain/index.vue | 26 +++++++++++++ .../unplannedreceiptRequestMain/index.vue | 39 +++++++++++++++++++ 3 files changed, 91 insertions(+) diff --git a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue index 5f6cfd7b7..deda16647 100644 --- a/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue +++ b/src/views/wms/inventoryjobManage/sparepartsrequisition/sparepartsrequisitionRequestMain/index.vue @@ -331,6 +331,32 @@ const handleReAdd = async (id: number) => { /** 添加/修改操作 */ const formRef = ref() const openForm =async (type: string, row?: number) => { + UnplannedissueRequestMain.allSchemas.formSchema.forEach((item) => { + if(type == "update"){ + if (item.field == 'costCenterCode') { + //成本中心代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + if (item.field == 'reasonCodeRequisition') { + //领用原因代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + + }else{ + if (item.field == 'costCenterCode') { + //成本中心代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + if (item.field == 'reasonCodeRequisition') { + //领用原因代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + } + }) tableData.value = [] // 重置明细数据 formRef.value.open(type, row) } diff --git a/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue b/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue index 6356d6b13..1433448b5 100644 --- a/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue +++ b/src/views/wms/inventoryjobManage/unplannedissue/unplannedissueRequestMain/index.vue @@ -349,6 +349,32 @@ const handleReAdd = async (id: number) => { /** 添加/修改操作 */ const formRef = ref() const openForm =async (type: string, row?: number) => { + UnplannedissueRequestMain.allSchemas.formSchema.forEach((item) => { + if(type == "update"){ + if (item.field == 'costCenterCode') { + //成本中心代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + if (item.field == 'reasonCodeRequisition') { + //领用原因代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + + }else{ + if (item.field == 'costCenterCode') { + //成本中心代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + if (item.field == 'reasonCodeRequisition') { + //领用原因代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + } + }) tableData.value = [] // 重置明细数据 formRef.value.open(type, row) } diff --git a/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue b/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue index 7710b396a..99dc8fae0 100644 --- a/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue +++ b/src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue @@ -566,6 +566,45 @@ const handleHandle = async (id: number) => { /** 添加/修改操作 */ const formRef = ref() const openForm =async (type: string, row?: number) => { + + UnplannedreceiptRequestMain.allSchemas.formSchema.forEach((item) => { + if(type == "update"){ + if (item.field == 'costCenterCode') { + //成本中心代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + if (item.field == 'reasonCodeRequisition') { + //领用原因代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + if (item.field == 'toWarehouseCode') { + //到仓库代码 + item.componentProps.isSearchList = false + item.componentProps.disabled = true + } + + + }else{ + if (item.field == 'costCenterCode') { + //成本中心代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + if (item.field == 'reasonCodeRequisition') { + //领用原因代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + if (item.field == 'toWarehouseCode') { + //到仓库代码 + item.componentProps.isSearchList = true + item.componentProps.disabled = false + } + } + }) + tableData.value = [] // 重置明细数据 formRef.value.open(type, row) }