refactor(MES/Product): 对工单物料列表按物料代码和批次号排序

添加了OrderBy操作,确保工单物料列表按物料代码和批次号排序,提高数据展示的一致性
This commit is contained in:
2026-01-31 23:03:07 +08:00
parent b018ebc687
commit cc88e78231

View File

@@ -161,6 +161,7 @@ namespace DOAN.Service.MES.product
Unit = it.Unit, Unit = it.Unit,
BatchNo = it.BatchNo, BatchNo = it.BatchNo,
}) })
.OrderBy(it => it.MaterialCode)
.ToList(); .ToList();
result = InventoryList; result = InventoryList;
} }
@@ -190,6 +191,8 @@ namespace DOAN.Service.MES.product
Unit = it.Unit, Unit = it.Unit,
BatchNo = it.BatchNo, BatchNo = it.BatchNo,
}) })
.OrderBy(it => it.MaterialCode)
.OrderBy(it => it.BatchNo)
.ToList(); .ToList();
result.AddRange(InventoryList); result.AddRange(InventoryList);
} }