修复bug

This commit is contained in:
18942506660
2023-12-27 11:27:08 +08:00
parent e5ed7c1732
commit 865b737c6a

View File

@@ -211,7 +211,7 @@ namespace WMS.Web.Domain.Entitys
if (list.Where(w => w.Type != OutStockType.Sal).Any()) return Result.ReFailure(ResultCodes.MergeStatusError);
if (list.GroupBy(g => g.DeliveryOrgId).Count() > 1) return Result.ReFailure(ResultCodes.MergeStatusError);
if (list.GroupBy(g => g.ReceiptCustomerId).Count() > 1) return Result.ReFailure(ResultCodes.MergeStatusError);
var details = list.SelectMany(s => s.Details).ToList();
var details = list.SelectMany(s => s.Details).ToList().Clone();
if (list.GroupBy(g => g.StockCode).Count() > 1) return Result.ReFailure(ResultCodes.MergeStatusError);
List<OutStockTaskDetails> details_new = new List<OutStockTaskDetails>();
@@ -239,6 +239,9 @@ namespace WMS.Web.Domain.Entitys
this.OperatorId = creatorId;
this.OperateTime = DateTime.Now;
this.Status = OutStockStatus.Wait;
this.DeliveryOrgId = list.First().DeliveryOrgId;
this.ReceiptCustomerId = list.First().ReceiptCustomerId;
this.StockCode = list.First().StockCode;
this.Type = OutStockType.Sal;
this.Details = details_new;