From 9945a3e638775755209cab9de3d04cf98ee2569b Mon Sep 17 00:00:00 2001 From: zhang_li <2235006734@qqq.com> Date: Thu, 24 Oct 2024 15:37:25 +0800 Subject: [PATCH] =?UTF-8?q?YT-477=E8=A6=81=E8=B4=A7=E8=AE=A1=E5=88=92?= =?UTF-8?q?=E6=98=8E=E7=BB=86=E4=B8=AD=E7=89=A9=E6=96=99=E6=95=B0=E9=87=8F?= =?UTF-8?q?=E5=8F=AF=E4=BB=A5=E4=B8=BA0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../supplierdeliverBasicForm.vue | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue index c06b073d3..ee3d855cd 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/supplierdeliverBasicForm.vue @@ -338,7 +338,13 @@ const submitForm = async (formType, submitData) => { // if(!flag){ // return // } - data.subList = tableData.value // 拼接子表数据参数 + // data.subList = tableData.value // 拼接子表数据参数 + data.subList = [] + for (let item of tableData.value) { + if(item.qty>0){ + data.subList.push(item) // 拼接子表数据参数 + } + } let isHave = data.subList.some((item) => { console.log("CCCCC",item.expireDate) if(item.expireDate != null){ @@ -394,9 +400,9 @@ const submitForm = async (formType, submitData) => { return; } } - if(tableData.value.length <= 0){ - message.warning(`子表明细不能为空!`) - return; + if(data.subList.length == 0){ + message.error(t('ts.子列表数量不能空')) + return } formRef.value.formLoading = true await SupplierdeliverRequestMainApi.createSupplierdeliverRequestMain(data)