diff --git a/MotorPlant/MotorPlantDatabaseImplement/Implements/OrderStorage.cs b/MotorPlant/MotorPlantDatabaseImplement/Implements/OrderStorage.cs index f47b0ee..688d32e 100644 --- a/MotorPlant/MotorPlantDatabaseImplement/Implements/OrderStorage.cs +++ b/MotorPlant/MotorPlantDatabaseImplement/Implements/OrderStorage.cs @@ -82,11 +82,11 @@ namespace MotorPlantDatabaseImplement.Implements if (model == null) return null; using var context = new MotorPlantDatabase(); - foreach (var Flower in context.Engines) + foreach (var Engine in context.Engines) { - if (Flower.Id == model.EngineId) + if (Engine.Id == model.EngineId) { - model.EngineName = Flower.EngineName; + model.EngineName = Engine.EngineName; break; } } diff --git a/MotorPlant/MotorPlantFileImplement/Implements/OrderStorage.cs b/MotorPlant/MotorPlantFileImplement/Implements/OrderStorage.cs index 95416f2..df30565 100644 --- a/MotorPlant/MotorPlantFileImplement/Implements/OrderStorage.cs +++ b/MotorPlant/MotorPlantFileImplement/Implements/OrderStorage.cs @@ -78,9 +78,9 @@ namespace MotorPlantFileImplement.Implements private OrderViewModel GetViewModel(Order order) { var viewModel = order.GetViewModel; - var flower = source.Engines.FirstOrDefault(x => x.Id == order.EngineId); + var engine = source.Engines.FirstOrDefault(x => x.Id == order.EngineId); var client = source.Clients.FirstOrDefault(x => x.Id == order.ClientId); - viewModel.EngineName = flower?.EngineName; + viewModel.EngineName = engine?.EngineName; viewModel.ClientFIO = client?.ClientFIO; return viewModel; }