diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormComponent.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormComponent.Designer.cs index 9285128..8f64057 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormComponent.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormComponent.Designer.cs @@ -100,7 +100,7 @@ this.Controls.Add(this.textBoxName); this.Controls.Add(this.labelName); this.Name = "FormComponent"; - this.Text = "FormComponent"; + this.Text = "Компонент"; this.ResumeLayout(false); this.PerformLayout(); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormComponents.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormComponents.Designer.cs index cbc6613..bf4819b 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormComponents.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormComponents.Designer.cs @@ -103,7 +103,7 @@ this.Controls.Add(this.buttonAdd); this.Controls.Add(this.dataGridView); this.Name = "FormComponents"; - this.Text = "FormComponents"; + this.Text = "Компоненты"; this.Load += new System.EventHandler(this.FormComponents_Load); ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit(); this.ResumeLayout(false); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormCreateOrder.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormCreateOrder.Designer.cs index 1fce33c..68ebddd 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormCreateOrder.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormCreateOrder.Designer.cs @@ -126,7 +126,7 @@ this.Controls.Add(this.label2); this.Controls.Add(this.label1); this.Name = "FormCreateOrder"; - this.Text = "FormCreateOrder"; + this.Text = "Создать заказ"; ((System.ComponentModel.ISupportInitialize)(this.textBoxCount)).EndInit(); this.ResumeLayout(false); this.PerformLayout(); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormMain.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormMain.Designer.cs index a2e34f9..64cc0eb 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormMain.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormMain.Designer.cs @@ -155,7 +155,7 @@ this.Controls.Add(this.buttonCreateOrder); this.Controls.Add(this.dataGridView); this.Name = "FormMain"; - this.Text = "FormMain"; + this.Text = "Заказы"; ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit(); this.menuStrip1.ResumeLayout(false); this.menuStrip1.PerformLayout(); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormReinforced.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormReinforced.Designer.cs index bda4a1c..910c8e6 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormReinforced.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormReinforced.Designer.cs @@ -239,7 +239,7 @@ this.Controls.Add(this.buttonSave); this.Controls.Add(this.buttonCancel); this.Name = "FormReinforced"; - this.Text = "FormReinforced"; + this.Text = "Изделие"; this.groupBox1.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit(); this.ResumeLayout(false); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormReinforcedComponent.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormReinforcedComponent.Designer.cs index 1e52690..718ed6f 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormReinforcedComponent.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormReinforcedComponent.Designer.cs @@ -101,7 +101,7 @@ this.Controls.Add(this.labelCount); this.Controls.Add(this.labelReinforced); this.Name = "FormReinforcedComponent"; - this.Text = "FormReinforcedComponent"; + this.Text = "Компонент изделия"; this.ResumeLayout(false); this.PerformLayout(); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.Designer.cs b/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.Designer.cs index 7b4f17b..fc657ee 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.Designer.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.Designer.cs @@ -103,7 +103,7 @@ this.Controls.Add(this.buttonAdd); this.Controls.Add(this.dataGridView); this.Name = "FormViewReinforced"; - this.Text = "FormViewReinforced"; + this.Text = "Изделия"; this.Load += new System.EventHandler(this.FormViewReinforced_Load); ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit(); this.ResumeLayout(false); diff --git a/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.cs b/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.cs index 29a50ab..5f77fbe 100644 --- a/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.cs +++ b/PrecastConcretePlant/PrecastConcretePlant/FormViewReinforced.cs @@ -56,18 +56,15 @@ namespace PrecastConcretePlantView { if (dataGridView.SelectedRows.Count == 1) { - var service = - Program.ServiceProvider?.GetService(typeof(FormComponent)); - if (service is FormComponent form) + var service = Program.ServiceProvider?.GetService(typeof(FormReinforced)); + if (service is FormReinforced form) { - form.Id = - Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value); + form.Id = Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value); if (form.ShowDialog() == DialogResult.OK) { - + LoadData(); } } - LoadData(); } } private void ButtonDel_Click(object sender, EventArgs e) diff --git a/PrecastConcretePlant/PrecastConcretePlantListImplement/OrderStorage.cs b/PrecastConcretePlant/PrecastConcretePlantListImplement/OrderStorage.cs index 653873e..06f32b6 100644 --- a/PrecastConcretePlant/PrecastConcretePlantListImplement/OrderStorage.cs +++ b/PrecastConcretePlant/PrecastConcretePlantListImplement/OrderStorage.cs @@ -106,11 +106,11 @@ namespace PrecastConcretePlantListImplement private OrderViewModel GetViewModel(Order model) { var res = model.GetViewModel; - foreach (var pastry in _source.Reinforced) + foreach (var reinforced in _source.Reinforced) { - if (pastry.Id == model.ReinforcedId) + if (reinforced.Id == model.ReinforcedId) { - res.ReinforcedName = pastry.ReinforcedName; + res.ReinforcedName = reinforced.ReinforcedName; break; } }