Browse Source

更新版本

Agv分支2024-11-19
赵新宇 4 months ago
parent
commit
7e7720293a
  1. 24
      be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/TransferNotes/TransferNoteAppService.cs

24
be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/TransferNotes/TransferNoteAppService.cs

@ -78,7 +78,7 @@ public class TransferNoteAppService : SfsStoreWithDetailsAppServiceBase
IPostionLocationAppService postionLocationAppService, IPostionLocationAppService postionLocationAppService,
IItemBasicAppService itemBasicAppService, IItemBasicAppService itemBasicAppService,
UnitOfWorkManager unitOfWorkManager, UnitOfWorkManager unitOfWorkManager,
IProductionLineAppService _productionLineAppService, IProductionLineAppService productionLineAppService,
IExpectOutAppService expectOutAppService) : base(repository) IExpectOutAppService expectOutAppService) : base(repository)
{ {
_unitOfWorkManager = unitOfWorkManager; _unitOfWorkManager = unitOfWorkManager;
@ -96,6 +96,7 @@ public class TransferNoteAppService : SfsStoreWithDetailsAppServiceBase
_agvOptions = agvOptions; _agvOptions = agvOptions;
_postionLocationAppService = postionLocationAppService; _postionLocationAppService = postionLocationAppService;
_itemBasicAppService = itemBasicAppService; _itemBasicAppService = itemBasicAppService;
_productionLineAppService = productionLineAppService;
} }
#region 东阳使用 #region 东阳使用
@ -709,21 +710,30 @@ public class TransferNoteAppService : SfsStoreWithDetailsAppServiceBase
{ {
errors.Add($"来源起始点{detail.BeginPosition}库位没查到"); errors.Add($"来源起始点{detail.BeginPosition}库位没查到");
} }
var productionline = await _productionLineAppService.GetByLocationCodeAsync(fromlocation.Code).ConfigureAwait(false);
if (productionline == null)
{
errors.Add($"结束点{detail.BeginPosition}库位不在生产线中!");
}
LocationDTO tolocation = await _locationAppService.GetByCodeAsync(detail.EndPosition).ConfigureAwait(false); LocationDTO tolocation = await _locationAppService.GetByCodeAsync(detail.EndPosition).ConfigureAwait(false);
if (tolocation == null) if (tolocation == null)
{ {
errors.Add($"结束点{detail.EndPosition}库位没查到"); errors.Add($"结束点{detail.EndPosition}库位没查到");
} }
var productionline=await _productionLineAppService.GetByLocationCodeAsync(tolocation.Code).ConfigureAwait(false);
if (productionline == null)
{
errors.Add($"结束点{detail.EndPosition}库位不在生产线中!");
}
transfer.Type = productionline.ProductionLineType.ToString();

Loading…
Cancel
Save