This commit is contained in:
aleksandr chegodaev 2024-06-17 16:37:20 +04:00
parent fb63a12ddd
commit 03ce74e177

View File

@ -93,10 +93,7 @@ namespace LawFirmFileImplement.Implements
var shopDocuments = source.Shops.SelectMany(shop => shop.ShopDocuments.Where(c => c.Value.Item1.Id == document.Id));
int countStore = 0;
foreach (var it in shopDocuments)
countStore += it.Value.Item2;
var countStore = shopDocuments.Sum(it => it.Value.Item2);
if (count > countStore)
return false;