From fef0d95c7a5372eb81e151932c2881fb3d3c60c0 Mon Sep 17 00:00:00 2001 From: platoff aeeee Date: Fri, 24 May 2024 13:42:42 +0400 Subject: [PATCH] 13 --- ...r.Designer.cs => FormCreateAd.Designer.cs} | 2 +- .../{FormCreateOrder.cs => FormCreateAd.cs} | 4 +- ...FormCreateOrder.resx => FormCreateAd.resx} | 0 .../FormFurnitureWorkPiece.Designer.cs | 118 ----------------- ...ce.Designer.cs => FormKomment.Designer.cs} | 45 ++++--- .../{FormWorkPiece.cs => FormKomment.cs} | 4 +- ...rnitureWorkPiece.resx => FormKomment.resx} | 0 .../FormKomments.Designer.cs | 121 +++++++++++++++++ .../{FormWorkPieces.cs => FormKomments.cs} | 12 +- ...{FormFurnitures.resx => FormKomments.resx} | 0 .../FormMain.Designer.cs | 16 +-- .../FurnitureAssemblyView/FormMain.cs | 12 +- ...iture.Designer.cs => FormUser.Designer.cs} | 2 +- .../{FormFurniture.cs => FormUser.cs} | 12 +- .../{FormFurniture.resx => FormUser.resx} | 9 ++ ...ures.Designer.cs => FormUsers.Designer.cs} | 2 +- .../{FormFurnitures.cs => FormUsers.cs} | 12 +- .../{FormWorkPiece.resx => FormUsers.resx} | 0 .../FormUsersKomment.Designer.cs | 122 ++++++++++++++++++ ...nitureWorkPiece.cs => FormUsersKomment.cs} | 4 +- .../FormUsersKomment.resx | 60 +++++++++ .../FormWorkPieces.Designer.cs | 114 ---------------- .../FurnitureAssemblyView/FormWorkPieces.resx | 120 ----------------- .../FurnitureAssemblyView/Program.cs | 12 +- 24 files changed, 385 insertions(+), 418 deletions(-) rename FurnitureAssembly/FurnitureAssemblyView/{FormCreateOrder.Designer.cs => FormCreateAd.Designer.cs} (99%) rename FurnitureAssembly/FurnitureAssemblyView/{FormCreateOrder.cs => FormCreateAd.cs} (97%) rename FurnitureAssembly/FurnitureAssemblyView/{FormCreateOrder.resx => FormCreateAd.resx} (100%) delete mode 100644 FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.Designer.cs rename FurnitureAssembly/FurnitureAssemblyView/{FormWorkPiece.Designer.cs => FormKomment.Designer.cs} (74%) rename FurnitureAssembly/FurnitureAssemblyView/{FormWorkPiece.cs => FormKomment.cs} (96%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurnitureWorkPiece.resx => FormKomment.resx} (100%) create mode 100644 FurnitureAssembly/FurnitureAssemblyView/FormKomments.Designer.cs rename FurnitureAssembly/FurnitureAssemblyView/{FormWorkPieces.cs => FormKomments.cs} (93%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurnitures.resx => FormKomments.resx} (100%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurniture.Designer.cs => FormUser.Designer.cs} (99%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurniture.cs => FormUser.cs} (96%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurniture.resx => FormUser.resx} (85%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurnitures.Designer.cs => FormUsers.Designer.cs} (99%) rename FurnitureAssembly/FurnitureAssemblyView/{FormFurnitures.cs => FormUsers.cs} (93%) rename FurnitureAssembly/FurnitureAssemblyView/{FormWorkPiece.resx => FormUsers.resx} (100%) create mode 100644 FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.Designer.cs rename FurnitureAssembly/FurnitureAssemblyView/{FormFurnitureWorkPiece.cs => FormUsersKomment.cs} (95%) create mode 100644 FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.resx delete mode 100644 FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.Designer.cs delete mode 100644 FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.resx diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.Designer.cs similarity index 99% rename from FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.Designer.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.Designer.cs index 72855e8..76fb992 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.Designer.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.Designer.cs @@ -1,6 +1,6 @@ namespace FurnitureAssemblyView { - partial class FormCreateOrder + partial class FormCreateAd { /// /// Required designer variable. diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.cs b/FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.cs similarity index 97% rename from FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.cs index 19da819..2cef0ca 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.cs @@ -15,7 +15,7 @@ using System.Windows.Forms; namespace FurnitureAssemblyView { - public partial class FormCreateOrder : Form + public partial class FormCreateAd : Form { private readonly ILogger _logger; @@ -23,7 +23,7 @@ namespace FurnitureAssemblyView private readonly IAdLogic _logicO; - public FormCreateOrder(ILogger logger, IUsersLogic logicM, IAdLogic logicO) + public FormCreateAd(ILogger logger, IUsersLogic logicM, IAdLogic logicO) { InitializeComponent(); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.resx b/FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.resx similarity index 100% rename from FurnitureAssembly/FurnitureAssemblyView/FormCreateOrder.resx rename to FurnitureAssembly/FurnitureAssemblyView/FormCreateAd.resx diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.Designer.cs deleted file mode 100644 index e7b3465..0000000 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.Designer.cs +++ /dev/null @@ -1,118 +0,0 @@ -namespace FurnitureAssemblyView -{ - partial class FormFurnitureWorkPiece - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - labelWorkPiece = new Label(); - labelCount = new Label(); - comboBoxWorkPiece = new ComboBox(); - textBoxCount = new TextBox(); - buttonSave = new Button(); - buttonCancel = new Button(); - SuspendLayout(); - // - // labelWorkPiece - // - labelWorkPiece.AutoSize = true; - labelWorkPiece.Location = new Point(31, 33); - labelWorkPiece.Name = "labelWorkPiece"; - labelWorkPiece.Size = new Size(81, 20); - labelWorkPiece.TabIndex = 0; - labelWorkPiece.Text = "Заготовка:"; - // - // labelCount - // - labelCount.AutoSize = true; - labelCount.Location = new Point(31, 79); - labelCount.Name = "labelCount"; - labelCount.Size = new Size(93, 20); - labelCount.TabIndex = 1; - labelCount.Text = "Количество:"; - // - // comboBoxWorkPiece - // - comboBoxWorkPiece.FormattingEnabled = true; - comboBoxWorkPiece.Location = new Point(156, 30); - comboBoxWorkPiece.Name = "comboBoxWorkPiece"; - comboBoxWorkPiece.Size = new Size(320, 28); - comboBoxWorkPiece.TabIndex = 2; - // - // textBoxCount - // - textBoxCount.Location = new Point(156, 76); - textBoxCount.Name = "textBoxCount"; - textBoxCount.Size = new Size(320, 27); - textBoxCount.TabIndex = 3; - // - // buttonSave - // - buttonSave.Location = new Point(236, 118); - buttonSave.Name = "buttonSave"; - buttonSave.Size = new Size(110, 38); - buttonSave.TabIndex = 4; - buttonSave.Text = "Сохранить"; - buttonSave.UseVisualStyleBackColor = true; - buttonSave.Click += ButtonSave_Click; - // - // buttonCancel - // - buttonCancel.Location = new Point(363, 118); - buttonCancel.Name = "buttonCancel"; - buttonCancel.Size = new Size(113, 38); - buttonCancel.TabIndex = 5; - buttonCancel.Text = "Отмена"; - buttonCancel.UseVisualStyleBackColor = true; - buttonCancel.Click += ButtonCancel_Click; - // - // FormFurnitureWorkPiece - // - AutoScaleDimensions = new SizeF(8F, 20F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(526, 168); - Controls.Add(buttonCancel); - Controls.Add(buttonSave); - Controls.Add(textBoxCount); - Controls.Add(comboBoxWorkPiece); - Controls.Add(labelCount); - Controls.Add(labelWorkPiece); - Name = "FormFurnitureWorkPiece"; - Text = "Заготовки для изделия"; - ResumeLayout(false); - PerformLayout(); - } - - #endregion - - private Label labelWorkPiece; - private Label labelCount; - private ComboBox comboBoxWorkPiece; - private TextBox textBoxCount; - private Button buttonSave; - private Button buttonCancel; - } -} \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormKomment.Designer.cs similarity index 74% rename from FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.Designer.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormKomment.Designer.cs index 287673e..8d99a11 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.Designer.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormKomment.Designer.cs @@ -1,6 +1,6 @@ namespace FurnitureAssemblyView { - partial class FormWorkPiece + partial class FormKomment { /// /// Required designer variable. @@ -39,40 +39,45 @@ // labelName // this.labelName.AutoSize = true; - this.labelName.Location = new System.Drawing.Point(30, 24); + this.labelName.Location = new System.Drawing.Point(12, 19); this.labelName.Name = "labelName"; - this.labelName.Size = new System.Drawing.Size(80, 20); + this.labelName.Size = new System.Drawing.Size(117, 15); this.labelName.TabIndex = 0; - this.labelName.Text = "Название:"; + this.labelName.Text = "Текст комментария:"; // // labelPrice // this.labelPrice.AutoSize = true; - this.labelPrice.Location = new System.Drawing.Point(30, 65); + this.labelPrice.Location = new System.Drawing.Point(103, 128); this.labelPrice.Name = "labelPrice"; - this.labelPrice.Size = new System.Drawing.Size(48, 20); + this.labelPrice.Size = new System.Drawing.Size(38, 15); this.labelPrice.TabIndex = 1; this.labelPrice.Text = "Цена:"; // // textBoxName // - this.textBoxName.Location = new System.Drawing.Point(127, 21); + this.textBoxName.Location = new System.Drawing.Point(135, 16); + this.textBoxName.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.textBoxName.Multiline = true; this.textBoxName.Name = "textBoxName"; - this.textBoxName.Size = new System.Drawing.Size(293, 27); + this.textBoxName.ScrollBars = System.Windows.Forms.ScrollBars.Horizontal; + this.textBoxName.Size = new System.Drawing.Size(314, 105); this.textBoxName.TabIndex = 2; // // textBoxCost // - this.textBoxCost.Location = new System.Drawing.Point(127, 62); + this.textBoxCost.Location = new System.Drawing.Point(158, 125); + this.textBoxCost.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.textBoxCost.Name = "textBoxCost"; - this.textBoxCost.Size = new System.Drawing.Size(179, 27); + this.textBoxCost.Size = new System.Drawing.Size(157, 23); this.textBoxCost.TabIndex = 3; // // buttonCancel // - this.buttonCancel.Location = new System.Drawing.Point(326, 104); + this.buttonCancel.Location = new System.Drawing.Point(333, 152); + this.buttonCancel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonCancel.Name = "buttonCancel"; - this.buttonCancel.Size = new System.Drawing.Size(94, 29); + this.buttonCancel.Size = new System.Drawing.Size(82, 22); this.buttonCancel.TabIndex = 4; this.buttonCancel.Text = "Отмена"; this.buttonCancel.UseVisualStyleBackColor = true; @@ -80,27 +85,29 @@ // // buttonSave // - this.buttonSave.Location = new System.Drawing.Point(212, 104); + this.buttonSave.Location = new System.Drawing.Point(245, 152); + this.buttonSave.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonSave.Name = "buttonSave"; - this.buttonSave.Size = new System.Drawing.Size(94, 29); + this.buttonSave.Size = new System.Drawing.Size(82, 22); this.buttonSave.TabIndex = 5; this.buttonSave.Text = "Сохранить"; this.buttonSave.UseVisualStyleBackColor = true; this.buttonSave.Click += new System.EventHandler(this.ButtonSave_Click); // - // FormWorkPiece + // FormKomment // - this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 20F); + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(464, 153); + this.ClientSize = new System.Drawing.Size(474, 185); this.Controls.Add(this.buttonSave); this.Controls.Add(this.buttonCancel); this.Controls.Add(this.textBoxCost); this.Controls.Add(this.textBoxName); this.Controls.Add(this.labelPrice); this.Controls.Add(this.labelName); - this.Name = "FormWorkPiece"; - this.Text = "Заготовка"; + this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.Name = "FormKomment"; + this.Text = "Комментарий"; this.Load += new System.EventHandler(this.FormWorkPiece_Load); this.ResumeLayout(false); this.PerformLayout(); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.cs b/FurnitureAssembly/FurnitureAssemblyView/FormKomment.cs similarity index 96% rename from FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormKomment.cs index 57fb52c..196ffd4 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormKomment.cs @@ -6,7 +6,7 @@ using Microsoft.Extensions.Logging; namespace FurnitureAssemblyView { // "" - public partial class FormWorkPiece : Form + public partial class FormKomment : Form { private readonly ILogger _logger; @@ -17,7 +17,7 @@ namespace FurnitureAssemblyView public int Id { set { _id = value; } } // - public FormWorkPiece(ILogger logger, IKommentLogic logic) + public FormKomment(ILogger logger, IKommentLogic logic) { InitializeComponent(); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.resx b/FurnitureAssembly/FurnitureAssemblyView/FormKomment.resx similarity index 100% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.resx rename to FurnitureAssembly/FurnitureAssemblyView/FormKomment.resx diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormKomments.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormKomments.Designer.cs new file mode 100644 index 0000000..4a8ee92 --- /dev/null +++ b/FurnitureAssembly/FurnitureAssemblyView/FormKomments.Designer.cs @@ -0,0 +1,121 @@ +namespace FurnitureAssemblyView +{ + partial class FormKomments + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.buttonAdd = new System.Windows.Forms.Button(); + this.buttonUpdate = new System.Windows.Forms.Button(); + this.buttonDelete = new System.Windows.Forms.Button(); + this.buttonRefresh = new System.Windows.Forms.Button(); + this.dataGridView = new System.Windows.Forms.DataGridView(); + ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit(); + this.SuspendLayout(); + // + // buttonAdd + // + this.buttonAdd.Location = new System.Drawing.Point(561, 27); + this.buttonAdd.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.buttonAdd.Name = "buttonAdd"; + this.buttonAdd.Size = new System.Drawing.Size(102, 35); + this.buttonAdd.TabIndex = 0; + this.buttonAdd.Text = "Добавить"; + this.buttonAdd.UseVisualStyleBackColor = true; + this.buttonAdd.Click += new System.EventHandler(this.ButtonAdd_Click); + // + // buttonUpdate + // + this.buttonUpdate.Location = new System.Drawing.Point(561, 76); + this.buttonUpdate.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.buttonUpdate.Name = "buttonUpdate"; + this.buttonUpdate.Size = new System.Drawing.Size(102, 35); + this.buttonUpdate.TabIndex = 1; + this.buttonUpdate.Text = "Изменить"; + this.buttonUpdate.UseVisualStyleBackColor = true; + this.buttonUpdate.Click += new System.EventHandler(this.ButtonUpdate_Click); + // + // buttonDelete + // + this.buttonDelete.Location = new System.Drawing.Point(561, 126); + this.buttonDelete.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.buttonDelete.Name = "buttonDelete"; + this.buttonDelete.Size = new System.Drawing.Size(102, 35); + this.buttonDelete.TabIndex = 2; + this.buttonDelete.Text = "Удалить"; + this.buttonDelete.UseVisualStyleBackColor = true; + this.buttonDelete.Click += new System.EventHandler(this.ButtonDelete_Click); + // + // buttonRefresh + // + this.buttonRefresh.Location = new System.Drawing.Point(561, 179); + this.buttonRefresh.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.buttonRefresh.Name = "buttonRefresh"; + this.buttonRefresh.Size = new System.Drawing.Size(102, 35); + this.buttonRefresh.TabIndex = 3; + this.buttonRefresh.Text = "Обновить"; + this.buttonRefresh.UseVisualStyleBackColor = true; + this.buttonRefresh.Click += new System.EventHandler(this.ButtonRefresh_Click); + // + // dataGridView + // + this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.dataGridView.Location = new System.Drawing.Point(10, 9); + this.dataGridView.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.dataGridView.Name = "dataGridView"; + this.dataGridView.RowHeadersWidth = 51; + this.dataGridView.RowTemplate.Height = 29; + this.dataGridView.Size = new System.Drawing.Size(545, 320); + this.dataGridView.TabIndex = 4; + // + // FormKomments + // + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(683, 338); + this.Controls.Add(this.dataGridView); + this.Controls.Add(this.buttonRefresh); + this.Controls.Add(this.buttonDelete); + this.Controls.Add(this.buttonUpdate); + this.Controls.Add(this.buttonAdd); + this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.Name = "FormKomments"; + this.Text = "Комментарии"; + this.Load += new System.EventHandler(this.FormWorkPiece_Load); + ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit(); + this.ResumeLayout(false); + + } + + #endregion + + private Button buttonAdd; + private Button buttonUpdate; + private Button buttonDelete; + private Button buttonRefresh; + private DataGridView dataGridView; + } +} \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.cs b/FurnitureAssembly/FurnitureAssemblyView/FormKomments.cs similarity index 93% rename from FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormKomments.cs index 6029257..cee5d51 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormKomments.cs @@ -14,13 +14,13 @@ using System.Windows.Forms; namespace FurnitureAssemblyView { // Форма со всеми созданными заготовками - public partial class FormWorkPieces : Form + public partial class FormKomments : Form { private readonly ILogger _logger; private readonly IKommentLogic _logic; - public FormWorkPieces(ILogger logger, IKommentLogic logic) + public FormKomments(ILogger logger, IKommentLogic logic) { InitializeComponent(); _logger = logger; @@ -59,9 +59,9 @@ namespace FurnitureAssemblyView private void ButtonAdd_Click(object sender, EventArgs e) { - var service = Program.ServiceProvider?.GetService(typeof(FormWorkPiece)); + var service = Program.ServiceProvider?.GetService(typeof(FormKomment)); - if (service is FormWorkPiece form) + if (service is FormKomment form) { if (form.ShowDialog() == DialogResult.OK) { @@ -75,9 +75,9 @@ namespace FurnitureAssemblyView { if (dataGridView.SelectedRows.Count == 1) { - var service = Program.ServiceProvider?.GetService(typeof(FormWorkPiece)); + var service = Program.ServiceProvider?.GetService(typeof(FormKomment)); - if (service is FormWorkPiece form) + if (service is FormKomment form) { form.Id = Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value); if (form.ShowDialog() == DialogResult.OK) diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.resx b/FurnitureAssembly/FurnitureAssemblyView/FormKomments.resx similarity index 100% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.resx rename to FurnitureAssembly/FurnitureAssemblyView/FormKomments.resx diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormMain.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormMain.Designer.cs index e7afbb6..b1d0415 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormMain.Designer.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormMain.Designer.cs @@ -50,12 +50,12 @@ this.dataGridView.Name = "dataGridView"; this.dataGridView.RowHeadersWidth = 51; this.dataGridView.RowTemplate.Height = 29; - this.dataGridView.Size = new System.Drawing.Size(794, 302); + this.dataGridView.Size = new System.Drawing.Size(709, 302); this.dataGridView.TabIndex = 0; // // buttonCreateOrder // - this.buttonCreateOrder.Location = new System.Drawing.Point(820, 27); + this.buttonCreateOrder.Location = new System.Drawing.Point(725, 27); this.buttonCreateOrder.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonCreateOrder.Name = "buttonCreateOrder"; this.buttonCreateOrder.Size = new System.Drawing.Size(178, 34); @@ -66,7 +66,7 @@ // // buttonTakeOrderInWork // - this.buttonTakeOrderInWork.Location = new System.Drawing.Point(820, 65); + this.buttonTakeOrderInWork.Location = new System.Drawing.Point(725, 65); this.buttonTakeOrderInWork.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonTakeOrderInWork.Name = "buttonTakeOrderInWork"; this.buttonTakeOrderInWork.Size = new System.Drawing.Size(178, 56); @@ -77,7 +77,7 @@ // // buttonOrderReady // - this.buttonOrderReady.Location = new System.Drawing.Point(820, 125); + this.buttonOrderReady.Location = new System.Drawing.Point(725, 125); this.buttonOrderReady.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonOrderReady.Name = "buttonOrderReady"; this.buttonOrderReady.Size = new System.Drawing.Size(178, 31); @@ -88,7 +88,7 @@ // // buttonIssuedOrder // - this.buttonIssuedOrder.Location = new System.Drawing.Point(820, 160); + this.buttonIssuedOrder.Location = new System.Drawing.Point(725, 160); this.buttonIssuedOrder.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonIssuedOrder.Name = "buttonIssuedOrder"; this.buttonIssuedOrder.Size = new System.Drawing.Size(178, 33); @@ -99,7 +99,7 @@ // // buttonRefresh // - this.buttonRefresh.Location = new System.Drawing.Point(820, 197); + this.buttonRefresh.Location = new System.Drawing.Point(725, 197); this.buttonRefresh.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); this.buttonRefresh.Name = "buttonRefresh"; this.buttonRefresh.Size = new System.Drawing.Size(178, 29); @@ -116,7 +116,7 @@ this.menuStrip.Location = new System.Drawing.Point(0, 0); this.menuStrip.Name = "menuStrip"; this.menuStrip.Padding = new System.Windows.Forms.Padding(5, 2, 0, 2); - this.menuStrip.Size = new System.Drawing.Size(1015, 24); + this.menuStrip.Size = new System.Drawing.Size(910, 24); this.menuStrip.TabIndex = 6; this.menuStrip.Text = "menuStrip"; // @@ -147,7 +147,7 @@ // this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(1015, 338); + this.ClientSize = new System.Drawing.Size(910, 338); this.Controls.Add(this.buttonRefresh); this.Controls.Add(this.buttonIssuedOrder); this.Controls.Add(this.buttonOrderReady); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormMain.cs b/FurnitureAssembly/FurnitureAssemblyView/FormMain.cs index 9b50bb2..7315537 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormMain.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormMain.cs @@ -58,9 +58,9 @@ namespace FurnitureAssemblyView private void WorkPieceToolStripMenuItem_Click(object sender, EventArgs e) { - var service = Program.ServiceProvider?.GetService(typeof(FormWorkPieces)); + var service = Program.ServiceProvider?.GetService(typeof(FormKomments)); - if (service is FormWorkPieces form) + if (service is FormKomments form) { form.ShowDialog(); } @@ -68,9 +68,9 @@ namespace FurnitureAssemblyView private void FurnitureToolStripMenuItem_Click(object sender, EventArgs e) { - var service = Program.ServiceProvider?.GetService(typeof(FormFurnitures)); + var service = Program.ServiceProvider?.GetService(typeof(FormUsers)); - if (service is FormFurnitures form) + if (service is FormUsers form) { form.ShowDialog(); } @@ -78,9 +78,9 @@ namespace FurnitureAssemblyView private void ButtonCreateOrder_Click(object sender, EventArgs e) { - var service = Program.ServiceProvider?.GetService(typeof(FormCreateOrder)); + var service = Program.ServiceProvider?.GetService(typeof(FormCreateAd)); - if (service is FormCreateOrder form) + if (service is FormCreateAd form) { form.ShowDialog(); LoadData(); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurniture.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormUser.Designer.cs similarity index 99% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurniture.Designer.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormUser.Designer.cs index 69ac0d5..19b54a4 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurniture.Designer.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUser.Designer.cs @@ -1,6 +1,6 @@ namespace FurnitureAssemblyView { - partial class FormFurniture + partial class FormUser { /// /// Required designer variable. diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurniture.cs b/FurnitureAssembly/FurnitureAssemblyView/FormUser.cs similarity index 96% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurniture.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormUser.cs index 7a24816..b303145 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurniture.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUser.cs @@ -15,7 +15,7 @@ using System.Windows.Forms; namespace FurnitureAssemblyView { - public partial class FormFurniture : Form + public partial class FormUser : Form { private readonly ILogger _logger; @@ -27,7 +27,7 @@ namespace FurnitureAssemblyView public int Id { set { _id = value; } } - public FormFurniture(ILogger logger, IUsersLogic logic) + public FormUser(ILogger logger, IUsersLogic logic) { InitializeComponent(); @@ -89,9 +89,9 @@ namespace FurnitureAssemblyView private void ButtonAdd_Click(object sender, EventArgs e) { - var service = Program.ServiceProvider?.GetService(typeof(FormFurnitureWorkPiece)); + var service = Program.ServiceProvider?.GetService(typeof(FormUsersKomment)); - if (service is FormFurnitureWorkPiece form) + if (service is FormUsersKomment form) { if (form.ShowDialog() == DialogResult.OK) { @@ -120,9 +120,9 @@ namespace FurnitureAssemblyView { if (dataGridView.SelectedRows.Count == 1) { - var service = Program.ServiceProvider?.GetService(typeof(FormFurnitureWorkPiece)); + var service = Program.ServiceProvider?.GetService(typeof(FormUsersKomment)); - if (service is FormFurnitureWorkPiece form) + if (service is FormUsersKomment form) { int id = Convert.ToInt32(dataGridView.SelectedRows[0].Cells[0].Value); form.Id = id; diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurniture.resx b/FurnitureAssembly/FurnitureAssemblyView/FormUser.resx similarity index 85% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurniture.resx rename to FurnitureAssembly/FurnitureAssemblyView/FormUser.resx index fb971ef..8eefdd7 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurniture.resx +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUser.resx @@ -66,4 +66,13 @@ True + + True + + + True + + + True + \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormUsers.Designer.cs similarity index 99% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.Designer.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormUsers.Designer.cs index f51032d..acd7aec 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.Designer.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUsers.Designer.cs @@ -1,6 +1,6 @@ namespace FurnitureAssemblyView { - partial class FormFurnitures + partial class FormUsers { /// /// Required designer variable. diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.cs b/FurnitureAssembly/FurnitureAssemblyView/FormUsers.cs similarity index 93% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormUsers.cs index 16a56df..2d14fbd 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitures.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUsers.cs @@ -13,13 +13,13 @@ using System.Windows.Forms; namespace FurnitureAssemblyView { - public partial class FormFurnitures : Form + public partial class FormUsers : Form { private readonly ILogger _logger; private readonly IUsersLogic _logic; - public FormFurnitures(ILogger logger, IUsersLogic logic) + public FormUsers(ILogger logger, IUsersLogic logic) { InitializeComponent(); @@ -58,9 +58,9 @@ namespace FurnitureAssemblyView private void ButtonAdd_Click(object sender, EventArgs e) { - var service = Program.ServiceProvider?.GetService(typeof(FormFurniture)); + var service = Program.ServiceProvider?.GetService(typeof(FormUser)); - if (service is FormFurniture form) + if (service is FormUser form) { if (form.ShowDialog() == DialogResult.OK) { @@ -73,9 +73,9 @@ namespace FurnitureAssemblyView { if (dataGridView.SelectedRows.Count == 1) { - var service = Program.ServiceProvider?.GetService(typeof(FormFurniture)); + var service = Program.ServiceProvider?.GetService(typeof(FormUser)); - if (service is FormFurniture form) + if (service is FormUser form) { form.Id = Convert.ToInt32(dataGridView.SelectedRows[0].Cells["Id"].Value); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.resx b/FurnitureAssembly/FurnitureAssemblyView/FormUsers.resx similarity index 100% rename from FurnitureAssembly/FurnitureAssemblyView/FormWorkPiece.resx rename to FurnitureAssembly/FurnitureAssemblyView/FormUsers.resx diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.Designer.cs new file mode 100644 index 0000000..b194244 --- /dev/null +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.Designer.cs @@ -0,0 +1,122 @@ +namespace FurnitureAssemblyView +{ + partial class FormUsersKomment + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + this.labelWorkPiece = new System.Windows.Forms.Label(); + this.labelCount = new System.Windows.Forms.Label(); + this.comboBoxWorkPiece = new System.Windows.Forms.ComboBox(); + this.textBoxCount = new System.Windows.Forms.TextBox(); + this.buttonSave = new System.Windows.Forms.Button(); + this.buttonCancel = new System.Windows.Forms.Button(); + this.SuspendLayout(); + // + // labelWorkPiece + // + this.labelWorkPiece.AutoSize = true; + this.labelWorkPiece.Location = new System.Drawing.Point(27, 25); + this.labelWorkPiece.Name = "labelWorkPiece"; + this.labelWorkPiece.Size = new System.Drawing.Size(87, 15); + this.labelWorkPiece.TabIndex = 0; + this.labelWorkPiece.Text = "Комментарий:"; + // + // labelCount + // + this.labelCount.AutoSize = true; + this.labelCount.Location = new System.Drawing.Point(27, 59); + this.labelCount.Name = "labelCount"; + this.labelCount.Size = new System.Drawing.Size(75, 15); + this.labelCount.TabIndex = 1; + this.labelCount.Text = "Количество:"; + // + // comboBoxWorkPiece + // + this.comboBoxWorkPiece.FormattingEnabled = true; + this.comboBoxWorkPiece.Location = new System.Drawing.Point(136, 22); + this.comboBoxWorkPiece.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.comboBoxWorkPiece.Name = "comboBoxWorkPiece"; + this.comboBoxWorkPiece.Size = new System.Drawing.Size(280, 23); + this.comboBoxWorkPiece.TabIndex = 2; + // + // textBoxCount + // + this.textBoxCount.Location = new System.Drawing.Point(136, 57); + this.textBoxCount.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.textBoxCount.Name = "textBoxCount"; + this.textBoxCount.Size = new System.Drawing.Size(280, 23); + this.textBoxCount.TabIndex = 3; + // + // buttonSave + // + this.buttonSave.Location = new System.Drawing.Point(215, 109); + this.buttonSave.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.buttonSave.Name = "buttonSave"; + this.buttonSave.Size = new System.Drawing.Size(96, 28); + this.buttonSave.TabIndex = 4; + this.buttonSave.Text = "Сохранить"; + this.buttonSave.UseVisualStyleBackColor = true; + // + // buttonCancel + // + this.buttonCancel.Location = new System.Drawing.Point(317, 109); + this.buttonCancel.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.buttonCancel.Name = "buttonCancel"; + this.buttonCancel.Size = new System.Drawing.Size(99, 28); + this.buttonCancel.TabIndex = 5; + this.buttonCancel.Text = "Отмена"; + this.buttonCancel.UseVisualStyleBackColor = true; + // + // FormUsersKomment + // + this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(432, 148); + this.Controls.Add(this.buttonCancel); + this.Controls.Add(this.buttonSave); + this.Controls.Add(this.textBoxCount); + this.Controls.Add(this.comboBoxWorkPiece); + this.Controls.Add(this.labelCount); + this.Controls.Add(this.labelWorkPiece); + this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2); + this.Name = "FormUsersKomment"; + this.Text = "Пользователи и Комменты"; + this.ResumeLayout(false); + this.PerformLayout(); + + } + + #endregion + + private Label labelWorkPiece; + private Label labelCount; + private ComboBox comboBoxWorkPiece; + private TextBox textBoxCount; + private Button buttonSave; + private Button buttonCancel; + } +} \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.cs b/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.cs similarity index 95% rename from FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.cs rename to FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.cs index ea2a00e..271e0c2 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/FormFurnitureWorkPiece.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.cs @@ -14,7 +14,7 @@ using System.Windows.Forms; namespace FurnitureAssemblyView { - public partial class FormFurnitureWorkPiece : Form + public partial class FormUsersKomment : Form { private readonly List? _list; @@ -54,7 +54,7 @@ namespace FurnitureAssemblyView } } - public FormFurnitureWorkPiece(IKommentLogic logic) + public FormUsersKomment(IKommentLogic logic) { InitializeComponent(); diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.resx b/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.resx new file mode 100644 index 0000000..f298a7b --- /dev/null +++ b/FurnitureAssembly/FurnitureAssemblyView/FormUsersKomment.resx @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.Designer.cs b/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.Designer.cs deleted file mode 100644 index 876791a..0000000 --- a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.Designer.cs +++ /dev/null @@ -1,114 +0,0 @@ -namespace FurnitureAssemblyView -{ - partial class FormWorkPieces - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - buttonAdd = new Button(); - buttonUpdate = new Button(); - buttonDelete = new Button(); - buttonRefresh = new Button(); - dataGridView = new DataGridView(); - ((System.ComponentModel.ISupportInitialize)dataGridView).BeginInit(); - SuspendLayout(); - // - // buttonAdd - // - buttonAdd.Location = new Point(641, 36); - buttonAdd.Name = "buttonAdd"; - buttonAdd.Size = new Size(116, 47); - buttonAdd.TabIndex = 0; - buttonAdd.Text = "Добавить"; - buttonAdd.UseVisualStyleBackColor = true; - buttonAdd.Click += ButtonAdd_Click; - // - // buttonUpdate - // - buttonUpdate.Location = new Point(641, 102); - buttonUpdate.Name = "buttonUpdate"; - buttonUpdate.Size = new Size(116, 47); - buttonUpdate.TabIndex = 1; - buttonUpdate.Text = "Изменить"; - buttonUpdate.UseVisualStyleBackColor = true; - buttonUpdate.Click += ButtonUpdate_Click; - // - // buttonDelete - // - buttonDelete.Location = new Point(641, 168); - buttonDelete.Name = "buttonDelete"; - buttonDelete.Size = new Size(116, 47); - buttonDelete.TabIndex = 2; - buttonDelete.Text = "Удалить"; - buttonDelete.UseVisualStyleBackColor = true; - buttonDelete.Click += ButtonDelete_Click; - // - // buttonRefresh - // - buttonRefresh.Location = new Point(641, 239); - buttonRefresh.Name = "buttonRefresh"; - buttonRefresh.Size = new Size(116, 47); - buttonRefresh.TabIndex = 3; - buttonRefresh.Text = "Обновить"; - buttonRefresh.UseVisualStyleBackColor = true; - buttonRefresh.Click += ButtonRefresh_Click; - // - // dataGridView - // - dataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - dataGridView.Location = new Point(12, 12); - dataGridView.Name = "dataGridView"; - dataGridView.RowHeadersWidth = 51; - dataGridView.RowTemplate.Height = 29; - dataGridView.Size = new Size(604, 426); - dataGridView.TabIndex = 4; - // - // FormWorkPieces - // - AutoScaleDimensions = new SizeF(8F, 20F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(781, 450); - Controls.Add(dataGridView); - Controls.Add(buttonRefresh); - Controls.Add(buttonDelete); - Controls.Add(buttonUpdate); - Controls.Add(buttonAdd); - Name = "FormWorkPieces"; - Text = "Заготовки"; - Load += FormWorkPiece_Load; - ((System.ComponentModel.ISupportInitialize)dataGridView).EndInit(); - ResumeLayout(false); - } - - #endregion - - private Button buttonAdd; - private Button buttonUpdate; - private Button buttonDelete; - private Button buttonRefresh; - private DataGridView dataGridView; - } -} \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.resx b/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.resx deleted file mode 100644 index af32865..0000000 --- a/FurnitureAssembly/FurnitureAssemblyView/FormWorkPieces.resx +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/FurnitureAssembly/FurnitureAssemblyView/Program.cs b/FurnitureAssembly/FurnitureAssemblyView/Program.cs index 0b67161..74cb3a9 100644 --- a/FurnitureAssembly/FurnitureAssemblyView/Program.cs +++ b/FurnitureAssembly/FurnitureAssemblyView/Program.cs @@ -45,12 +45,12 @@ namespace FurnitureAssemblyView services.AddTransient(); services.AddTransient(); - services.AddTransient(); - services.AddTransient(); - services.AddTransient(); - services.AddTransient(); - services.AddTransient(); - services.AddTransient(); + services.AddTransient(); + services.AddTransient(); + services.AddTransient(); + services.AddTransient(); + services.AddTransient(); + services.AddTransient(); } } } \ No newline at end of file