现场问题

This commit is contained in:
2024-10-08 11:33:35 +08:00
parent 4af8cc9d86
commit 2a3a56814b
5 changed files with 72 additions and 62 deletions

View File

@@ -743,19 +743,22 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA
for (int carry_mat_index = 0; carry_mat_index < carry_mats.Count; carry_mat_index++)
{
var carry_mat = carry_mats[carry_mat_index];
bool isexists = false;
foreach (var basRegionMat in basRegionMats)
{
if (!carry_mat.category_list.Contains(basRegionMat.category))
{
carry_mats.RemoveAt(carry_mat_index); carry_mat_index--;
}
else
if (carry_mat.category_list.Contains(basRegionMat.category))
{
carry_mat.category = basRegionMat.category;
carry_mat.region_id = basRegionMat.region_id;
carry_mat.region_code = basRegionMat.region_code;
isexists = true;
break;
}
}
if (!isexists)
{
carry_mats.RemoveAt(carry_mat_index); carry_mat_index--;
}
}
#endregion
@@ -767,7 +770,7 @@ where carry_code = '{coderesult}' and status = '{WmsWareHouseConst.TASK_BILL_STA
List<BasLocation> endLocations = new List<BasLocation>();
// 小件物料入外协存储区
var carry_mat = carry_mats.Where(r => r.carry_id == wmsCarryH.id).First();
var carry_mat = carry_mats.Where(r => r.carry_id == wmsCarryH.id).FirstOrDefault();
if (carry_mat != null && !string.IsNullOrEmpty(carry_mat.category))
{
inStockStrategyInput = new() { warehouse_id = "1", Size = 1, passage = startlocation.passage, AvoidBusyPassage = true, Region_id = carry_mat.region_id, PolicyCode = WmsWareHouseConst.POLICY_YCLINSTOCK };