bug处理

This commit is contained in:
2024-04-23 10:16:16 +08:00
parent c8e2f1eafd
commit 579f2d3a39
197 changed files with 2509 additions and 1363 deletions

View File

@@ -35,7 +35,7 @@ namespace Tnb.WarehouseMgr
/// </summary>
[OverideVisualDev(ModuleConsts.MODULE_WMSOUTSTOCK_ID)]
[ServiceModule(BizTypeId)]
public class WmsOutStockService : ServiceLoggerBase<WmsOutStockService>, IWmsOutStockService
public class WmsOutStockService : DevServBase<WmsOutStockService>, IWmsOutStockService
{
private const string BizTypeId = "26191522660645";
private readonly ISqlSugarClient _db;
@@ -59,7 +59,7 @@ namespace Tnb.WarehouseMgr
IBillRullService billRullService,
IWmsCarryMoveInStockService wmsCarryMoveInStockService,
IWmsCarryService wareCarryService,
IEventPublisher eventPublisher)
IEventPublisher eventPublisher) : base(repository.AsSugarClient())
{
_db = repository.AsSugarClient();
_dictionaryDataService = dictionaryDataService;
@@ -72,7 +72,6 @@ namespace Tnb.WarehouseMgr
_wareCarryService = wareCarryService;
OverideFuncs.CreateAsync = OutStockApplyFor;
_ = InitializationTask;
}
public async Task<dynamic> OutStockApplyFor(VisualDevModelDataCrInput input)
@@ -115,7 +114,7 @@ namespace Tnb.WarehouseMgr
List<string?> freeLocIds = fLocIds.Except(minTaskNumLocs.Select(x => x.endlocation_id)).ToList();
if (freeLocIds?.Count > 0)
{
int rIdx = Random.Shared.Next(0, freeLocIds.Count);
int rIdx = Random.Shared.Next(0, freeLocIds.Count);
loc = await _db.Queryable<BasLocation>().SingleAsync(it => it.id == freeLocIds[rIdx]);
}
else
@@ -712,6 +711,7 @@ namespace Tnb.WarehouseMgr
List<WmsPointH> points = new List<WmsPointH>();
if (sPoint.area_code != ePoint.area_code)
{
points = await _wareHouseService.PathAlgorithms(sPoint.id, ePoint.id);
if (points.Count <= 2)
{
throw new AppFriendlyException("该路径不存在", 500);
@@ -739,6 +739,11 @@ namespace Tnb.WarehouseMgr
startlocation_code = sPoint?.location_code ?? string.Empty,
endlocation_id = ePoint?.location_id ?? string.Empty,
endlocation_code = ePoint?.location_code ?? string.Empty,
startpoint_id = sPoint.id,
startpoint_code = sPoint.point_code,
endpoint_id = ePoint.id,
endpoint_code = ePoint.point_code,
start_floor = sPoint?.floor.ToString(),
end_floor = ePoint?.floor.ToString(),
bill_code = _billRullService.GetBillNumber(WmsWareHouseConst.WMS_PRETASK_H_ENCODE).GetAwaiter().GetResult(),