This commit is contained in:
tongfei
2024-04-11 16:57:37 +08:00
3 changed files with 17 additions and 1 deletions

View File

@@ -54,6 +54,7 @@ namespace WMS.Web.Domain.Services
var entityList = await _serialNumbersRepositories.GetEntityList(serialNumbers);
var boxIds = changeBoxRecords.Select(s => s.DestBoxId).ToList();
var boxList = await _boxRepositories.GetEntityList(boxIds);
var boxInventorys = await _boxInventoryRepositories.GetList(boxIds);
var userName = _singleDataService.GetSingleData(SingleAction.Staffs, loginInfo.UserInfo.CompanyId, loginInfo.UserInfo.StaffId);
IDbContextTransaction _transaction = null;
if (isTransaction)
@@ -67,7 +68,8 @@ namespace WMS.Web.Domain.Services
var box = boxList.FirstOrDefault(f => f.Id == destBox.DestBoxId);
//修改序列号和箱绑定关系
entity.Bind(destBox.DestBoxId, box.CompleteCartonTime);
var boxInventory = boxInventorys.FirstOrDefault(f => f.BoxId == destBox.DestBoxId);
entity.ChangeBox(boxInventory == null ? false : true);
//记录序列号操作日志
SerialNumberOperate op = new SerialNumberOperate()