From bab90b94f8931a61015eef80dd994be9c69b0680 Mon Sep 17 00:00:00 2001 From: 18942506660 <18942506660@A18942506660> Date: Fri, 17 Nov 2023 17:12:53 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/WMS.Web.Domain/Entitys/OutStock.cs | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/WMS.Web.Domain/Entitys/OutStock.cs b/src/WMS.Web.Domain/Entitys/OutStock.cs index 445afe7b..a8af87ed 100644 --- a/src/WMS.Web.Domain/Entitys/OutStock.cs +++ b/src/WMS.Web.Domain/Entitys/OutStock.cs @@ -97,8 +97,16 @@ namespace WMS.Web.Domain.Entitys this.ReceiptCustomerId = task.ReceiptCustomerId; this.CreatorId = creatorId; this.CreateTime = DateTime.Now; - this.SuccessSync = false; - this.SuccessSyncFail = this.Details.SelectMany(s => s.ErpDetails).GroupBy(g => g.SourceBillNo).Select(s=>s.Key).ToList(); + if (task.Type == OutStockType.Sal) + { + //只有销售出库才需要同步金蝶 + this.SuccessSync = false; + this.SuccessSyncFail = this.Details.SelectMany(s => s.ErpDetails).GroupBy(g => g.SourceBillNo).Select(s => s.Key).ToList(); + }else + { + this.SuccessSync = true; + this.SuccessSyncFail = new List(); + } } /// /// 同步金蝶(成功)