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)