diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_BA_SERVICE.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_BA_SERVICE.cs index 8a5a1556..0f43731f 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_BA_SERVICE.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BQ/BBAC_BA_SERVICE.cs @@ -370,9 +370,9 @@ namespace Win.Sfs.SettleAccount.Entities.BQ if (adjlist != null && adjlist.Count > 0) { - var relationList =_relationRepository.Where(p => p.BusinessType == inv.BusinessType); + var relationList =_relationRepository.Where(p => p.BusinessType == inv.BusinessType).ToList(); - var relist= relationList.GroupBy(p => new { p.SettleMaterialCode, p.ErpMaterialCode }).Select(p => p.FirstOrDefault()); + var relist= relationList.GroupBy(p => new { p.SettleMaterialCode, p.ErpMaterialCode }).Select(p => p.FirstOrDefault()).ToList(); foreach (var itm in adjlist)