исправление ошибки

This commit is contained in:
evasina2312@gmail.com 2023-04-18 13:03:51 +04:00
parent d30cd30aef
commit 022039bbb9

View File

@ -16,9 +16,9 @@ namespace ComputersShopDatabaseImplement.Implements
.ToList(); .ToList();
foreach (var order in orderList) foreach (var order in orderList)
{ {
string manufactureName = context.Computers string computerName = context.Computers
.SingleOrDefault(x => x.Id == order.ComputerId)?.ComputerName ?? string.Empty; .SingleOrDefault(x => x.Id == order.ComputerId)?.ComputerName ?? string.Empty;
order.ComputerName = manufactureName; order.ComputerName = computerName;
} }
return orderList; return orderList;
} }