改了入库
This commit is contained in:
@@ -207,7 +207,7 @@ namespace WMS.Web.Repositories
|
||||
//boxList = boxList.GroupBy(g => g.DetailId).Select(s => s.OrderByDescending(o => o.ReceiveTime).First()).ToList();
|
||||
|
||||
var boxIds = boxList.GroupBy(x => x.BoxId).Select(x => x.Key).ToList();
|
||||
if (entity.Type == InstockType.Purchase)
|
||||
if ((entity.Type == InstockType.Purchase||entity.Type==InstockType.ProduceSotck))
|
||||
{
|
||||
//左连接中 右表中的数据如果有多条,所以需要特殊处理
|
||||
var instockTaskBoxList = await _context.InstockTaskBox.Include(x => x.Details).Where(w => w.TaskId == entity.Id && boxIds.Contains(w.BoxId)).ToListAsync();
|
||||
@@ -251,7 +251,7 @@ namespace WMS.Web.Repositories
|
||||
|
||||
}
|
||||
|
||||
if (entity.Type == InstockType.Purchase)
|
||||
if ((entity.Type == InstockType.Purchase || entity.Type == InstockType.ProduceSotck))
|
||||
{
|
||||
var receiveBox = await _context.InStockTaskBoxDetails
|
||||
.GroupJoin(_context.InstockTaskBox, boxde => boxde.Fid, ts => ts.Id, (detail, ts) => new { detail, ts })
|
||||
|
||||
Reference in New Issue
Block a user