From 6610112df2fe54fd44a0979df5fbe9479864d821 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Wed, 7 Feb 2024 16:24:04 +0400 Subject: [PATCH 1/7] =?UTF-8?q?=D0=9D=D0=B0=D0=B2=D0=B5=D1=80=D0=BD=D0=BE?= =?UTF-8?q?=D0=B5=20=D1=81=D0=B4=D0=B5=D0=BB=D0=B0=D0=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IceCreamShop/MainForm.Designer.cs | 64 ++++-- IceCreamShop/IceCreamShop/MainForm.cs | 18 ++ IceCreamShop/IceCreamShop/Program.cs | 5 + .../IceCreamShop/ShopForm.Designer.cs | 187 ++++++++++++++++++ IceCreamShop/IceCreamShop/ShopForm.cs | 124 ++++++++++++ IceCreamShop/IceCreamShop/ShopForm.resx | 132 +++++++++++++ .../IceCreamShop/ShopsForm.Designer.cs | 117 +++++++++++ IceCreamShop/IceCreamShop/ShopsForm.cs | 118 +++++++++++ IceCreamShop/IceCreamShop/ShopsForm.resx | 120 +++++++++++ .../IceCreamShop/SupplyForm.Designer.cs | 105 ++++++++++ IceCreamShop/IceCreamShop/SupplyForm.cs | 153 ++++++++++++++ IceCreamShop/IceCreamShop/SupplyForm.resx | 120 +++++++++++ .../BusinessLogic/ShopLogic.cs | 137 +++++++++++++ .../BindingModels/ShopBindingModel.cs | 18 ++ .../BusinessLogicsContracts/IShopLogic.cs | 22 +++ .../SearchModels/ShopSearchModel.cs | 15 ++ .../StoragesContracts/IShopStorage.cs | 23 +++ .../ViewModels/ShopViewModel.cs | 22 +++ .../IceCreamShopDataModels/IShopModel.cs | 16 ++ .../DataListSingleton.cs | 2 + .../Implements/ShopStorage.cs | 139 +++++++++++++ .../IceCreamShopListImplement/Models/Shop.cs | 56 ++++++ 22 files changed, 1694 insertions(+), 19 deletions(-) create mode 100644 IceCreamShop/IceCreamShop/ShopForm.Designer.cs create mode 100644 IceCreamShop/IceCreamShop/ShopForm.cs create mode 100644 IceCreamShop/IceCreamShop/ShopForm.resx create mode 100644 IceCreamShop/IceCreamShop/ShopsForm.Designer.cs create mode 100644 IceCreamShop/IceCreamShop/ShopsForm.cs create mode 100644 IceCreamShop/IceCreamShop/ShopsForm.resx create mode 100644 IceCreamShop/IceCreamShop/SupplyForm.Designer.cs create mode 100644 IceCreamShop/IceCreamShop/SupplyForm.cs create mode 100644 IceCreamShop/IceCreamShop/SupplyForm.resx create mode 100644 IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs create mode 100644 IceCreamShop/IceCreamShopContracts/BindingModels/ShopBindingModel.cs create mode 100644 IceCreamShop/IceCreamShopContracts/BusinessLogicsContracts/IShopLogic.cs create mode 100644 IceCreamShop/IceCreamShopContracts/SearchModels/ShopSearchModel.cs create mode 100644 IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs create mode 100644 IceCreamShop/IceCreamShopContracts/ViewModels/ShopViewModel.cs create mode 100644 IceCreamShop/IceCreamShopDataModels/IShopModel.cs create mode 100644 IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs create mode 100644 IceCreamShop/IceCreamShopListImplement/Models/Shop.cs diff --git a/IceCreamShop/IceCreamShop/MainForm.Designer.cs b/IceCreamShop/IceCreamShop/MainForm.Designer.cs index 2b62d4f..6627a9c 100644 --- a/IceCreamShop/IceCreamShop/MainForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/MainForm.Designer.cs @@ -32,12 +32,14 @@ ToolStripMenu = new ToolStripMenuItem(); КомпонентыStripMenuItem = new ToolStripMenuItem(); МороженноеStripMenuItem = new ToolStripMenuItem(); + магазиныToolStripMenuItem = new ToolStripMenuItem(); DataGridView = new DataGridView(); CreateOrderButton = new Button(); TakeInWorkButton = new Button(); ReadyButton = new Button(); IssuedButton = new Button(); RefreshButton = new Button(); + поставкиToolStripMenuItem = new ToolStripMenuItem(); menuStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)DataGridView).BeginInit(); SuspendLayout(); @@ -48,45 +50,55 @@ menuStrip1.Items.AddRange(new ToolStripItem[] { ToolStripMenu }); menuStrip1.Location = new Point(0, 0); menuStrip1.Name = "menuStrip1"; - menuStrip1.Size = new Size(1296, 28); + menuStrip1.Padding = new Padding(5, 2, 0, 2); + menuStrip1.Size = new Size(1134, 24); menuStrip1.TabIndex = 0; menuStrip1.Text = "menuStrip1"; // // ToolStripMenu // - ToolStripMenu.DropDownItems.AddRange(new ToolStripItem[] { КомпонентыStripMenuItem, МороженноеStripMenuItem }); + ToolStripMenu.DropDownItems.AddRange(new ToolStripItem[] { КомпонентыStripMenuItem, МороженноеStripMenuItem, магазиныToolStripMenuItem, поставкиToolStripMenuItem }); ToolStripMenu.Name = "ToolStripMenu"; - ToolStripMenu.Size = new Size(117, 24); + ToolStripMenu.Size = new Size(94, 20); ToolStripMenu.Text = "Справочники"; // // КомпонентыStripMenuItem // КомпонентыStripMenuItem.Name = "КомпонентыStripMenuItem"; - КомпонентыStripMenuItem.Size = new Size(186, 26); + КомпонентыStripMenuItem.Size = new Size(180, 22); КомпонентыStripMenuItem.Text = "Компоненты"; КомпонентыStripMenuItem.Click += КомпонентыStripMenuItem_Click; // // МороженноеStripMenuItem // МороженноеStripMenuItem.Name = "МороженноеStripMenuItem"; - МороженноеStripMenuItem.Size = new Size(186, 26); + МороженноеStripMenuItem.Size = new Size(180, 22); МороженноеStripMenuItem.Text = "Мороженное"; МороженноеStripMenuItem.Click += МороженноеStripMenuItem_Click; // + // магазиныToolStripMenuItem + // + магазиныToolStripMenuItem.Name = "магазиныToolStripMenuItem"; + магазиныToolStripMenuItem.Size = new Size(180, 22); + магазиныToolStripMenuItem.Text = "Магазины"; + магазиныToolStripMenuItem.Click += магазиныToolStripMenuItem_Click; + // // DataGridView // DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - DataGridView.Location = new Point(12, 31); + DataGridView.Location = new Point(10, 23); + DataGridView.Margin = new Padding(3, 2, 3, 2); DataGridView.Name = "DataGridView"; DataGridView.RowHeadersWidth = 51; - DataGridView.Size = new Size(1007, 407); + DataGridView.Size = new Size(881, 305); DataGridView.TabIndex = 1; // // CreateOrderButton // - CreateOrderButton.Location = new Point(1025, 31); + CreateOrderButton.Location = new Point(897, 23); + CreateOrderButton.Margin = new Padding(3, 2, 3, 2); CreateOrderButton.Name = "CreateOrderButton"; - CreateOrderButton.Size = new Size(259, 29); + CreateOrderButton.Size = new Size(227, 22); CreateOrderButton.TabIndex = 2; CreateOrderButton.Text = "Создать заказ"; CreateOrderButton.UseVisualStyleBackColor = true; @@ -94,9 +106,10 @@ // // TakeInWorkButton // - TakeInWorkButton.Location = new Point(1025, 66); + TakeInWorkButton.Location = new Point(897, 50); + TakeInWorkButton.Margin = new Padding(3, 2, 3, 2); TakeInWorkButton.Name = "TakeInWorkButton"; - TakeInWorkButton.Size = new Size(259, 29); + TakeInWorkButton.Size = new Size(227, 22); TakeInWorkButton.TabIndex = 3; TakeInWorkButton.Text = "Отдать заказ в работу"; TakeInWorkButton.UseVisualStyleBackColor = true; @@ -104,9 +117,10 @@ // // ReadyButton // - ReadyButton.Location = new Point(1025, 101); + ReadyButton.Location = new Point(897, 76); + ReadyButton.Margin = new Padding(3, 2, 3, 2); ReadyButton.Name = "ReadyButton"; - ReadyButton.Size = new Size(259, 29); + ReadyButton.Size = new Size(227, 22); ReadyButton.TabIndex = 4; ReadyButton.Text = "Заказ готов"; ReadyButton.UseVisualStyleBackColor = true; @@ -114,9 +128,10 @@ // // IssuedButton // - IssuedButton.Location = new Point(1025, 136); + IssuedButton.Location = new Point(897, 102); + IssuedButton.Margin = new Padding(3, 2, 3, 2); IssuedButton.Name = "IssuedButton"; - IssuedButton.Size = new Size(259, 29); + IssuedButton.Size = new Size(227, 22); IssuedButton.TabIndex = 5; IssuedButton.Text = "Заказ выдан"; IssuedButton.UseVisualStyleBackColor = true; @@ -124,19 +139,27 @@ // // RefreshButton // - RefreshButton.Location = new Point(1025, 171); + RefreshButton.Location = new Point(897, 128); + RefreshButton.Margin = new Padding(3, 2, 3, 2); RefreshButton.Name = "RefreshButton"; - RefreshButton.Size = new Size(259, 29); + RefreshButton.Size = new Size(227, 22); RefreshButton.TabIndex = 6; RefreshButton.Text = "Обновить"; RefreshButton.UseVisualStyleBackColor = true; RefreshButton.Click += RefreshButton_Click; // + // поставкиToolStripMenuItem + // + поставкиToolStripMenuItem.Name = "поставкиToolStripMenuItem"; + поставкиToolStripMenuItem.Size = new Size(180, 22); + поставкиToolStripMenuItem.Text = "Поставки"; + поставкиToolStripMenuItem.Click += поставкиToolStripMenuItem_Click; + // // MainForm // - AutoScaleDimensions = new SizeF(8F, 20F); + AutoScaleDimensions = new SizeF(7F, 15F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(1296, 450); + ClientSize = new Size(1134, 338); Controls.Add(RefreshButton); Controls.Add(IssuedButton); Controls.Add(ReadyButton); @@ -145,6 +168,7 @@ Controls.Add(DataGridView); Controls.Add(menuStrip1); MainMenuStrip = menuStrip1; + Margin = new Padding(3, 2, 3, 2); Name = "MainForm"; Text = "MainForm"; Load += MainForm_Load; @@ -167,5 +191,7 @@ private Button ReadyButton; private Button IssuedButton; private Button RefreshButton; + private ToolStripMenuItem магазиныToolStripMenuItem; + private ToolStripMenuItem поставкиToolStripMenuItem; } } \ No newline at end of file diff --git a/IceCreamShop/IceCreamShop/MainForm.cs b/IceCreamShop/IceCreamShop/MainForm.cs index 600e794..e523217 100644 --- a/IceCreamShop/IceCreamShop/MainForm.cs +++ b/IceCreamShop/IceCreamShop/MainForm.cs @@ -180,5 +180,23 @@ Program.ServiceProvider?.GetService(typeof(OrderForm)); { LoadData(); } + + private void магазиныToolStripMenuItem_Click(object sender, EventArgs e) + { + var service = Program.ServiceProvider?.GetService(typeof(ShopsForm)); + if (service is ShopsForm form) + { + form.ShowDialog(); + } + } + + private void поставкиToolStripMenuItem_Click(object sender, EventArgs e) + { + var service = Program.ServiceProvider?.GetService(typeof(SupplyForm)); + if (service is SupplyForm form) + { + form.ShowDialog(); + } + } } } diff --git a/IceCreamShop/IceCreamShop/Program.cs b/IceCreamShop/IceCreamShop/Program.cs index f670921..4a1e77e 100644 --- a/IceCreamShop/IceCreamShop/Program.cs +++ b/IceCreamShop/IceCreamShop/Program.cs @@ -34,6 +34,8 @@ namespace IceCreamShop option.AddNLog("nlog.config"); }); services.AddTransient(); + services.AddTransient(); + services.AddTransient(); services.AddTransient(); services.AddTransient(); services.AddTransient(); @@ -46,6 +48,9 @@ namespace IceCreamShop services.AddTransient(); services.AddTransient(); services.AddTransient(); + services.AddTransient(); + services.AddTransient(); + services.AddTransient(); } } } diff --git a/IceCreamShop/IceCreamShop/ShopForm.Designer.cs b/IceCreamShop/IceCreamShop/ShopForm.Designer.cs new file mode 100644 index 0000000..964b16f --- /dev/null +++ b/IceCreamShop/IceCreamShop/ShopForm.Designer.cs @@ -0,0 +1,187 @@ +namespace IceCreamShop +{ + partial class ShopForm + { + /// + /// 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() + { + DateTimePicker = new DateTimePicker(); + NameTextBox = new TextBox(); + AddressTextBox = new TextBox(); + NameLabel = new Label(); + AdressLabel = new Label(); + DateLabel = new Label(); + SaveButton = new Button(); + CancelButton = new Button(); + DataGridView = new DataGridView(); + Column1 = new DataGridViewTextBoxColumn(); + Название = new DataGridViewTextBoxColumn(); + Цена = new DataGridViewTextBoxColumn(); + Количество = new DataGridViewTextBoxColumn(); + ((System.ComponentModel.ISupportInitialize)DataGridView).BeginInit(); + SuspendLayout(); + // + // DateTimePicker + // + DateTimePicker.Location = new Point(85, 70); + DateTimePicker.Name = "DateTimePicker"; + DateTimePicker.Size = new Size(318, 23); + DateTimePicker.TabIndex = 0; + // + // NameTextBox + // + NameTextBox.Location = new Point(85, 12); + NameTextBox.Name = "NameTextBox"; + NameTextBox.Size = new Size(318, 23); + NameTextBox.TabIndex = 1; + // + // AddressTextBox + // + AddressTextBox.Location = new Point(85, 41); + AddressTextBox.Name = "AddressTextBox"; + AddressTextBox.Size = new Size(318, 23); + AddressTextBox.TabIndex = 2; + // + // NameLabel + // + NameLabel.AutoSize = true; + NameLabel.Location = new Point(12, 15); + NameLabel.Name = "NameLabel"; + NameLabel.Size = new Size(59, 15); + NameLabel.TabIndex = 3; + NameLabel.Text = "Название"; + // + // AdressLabel + // + AdressLabel.AutoSize = true; + AdressLabel.Location = new Point(12, 44); + AdressLabel.Name = "AdressLabel"; + AdressLabel.Size = new Size(40, 15); + AdressLabel.TabIndex = 4; + AdressLabel.Text = "Адрес"; + // + // DateLabel + // + DateLabel.AutoSize = true; + DateLabel.Location = new Point(12, 76); + DateLabel.Name = "DateLabel"; + DateLabel.Size = new Size(32, 15); + DateLabel.TabIndex = 5; + DateLabel.Text = "Дата"; + // + // SaveButton + // + SaveButton.Location = new Point(247, 255); + SaveButton.Name = "SaveButton"; + SaveButton.Size = new Size(75, 23); + SaveButton.TabIndex = 6; + SaveButton.Text = "Сохранить"; + SaveButton.UseVisualStyleBackColor = true; + SaveButton.Click += SaveButton_Click; + // + // CancelButton + // + CancelButton.Location = new Point(328, 255); + CancelButton.Name = "CancelButton"; + CancelButton.Size = new Size(75, 23); + CancelButton.TabIndex = 7; + CancelButton.Text = "Отмена"; + CancelButton.UseVisualStyleBackColor = true; + CancelButton.Click += CancelButton_Click; + // + // DataGridView + // + DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; + DataGridView.Columns.AddRange(new DataGridViewColumn[] { Column1, Название, Цена, Количество }); + DataGridView.Location = new Point(12, 99); + DataGridView.Name = "DataGridView"; + DataGridView.Size = new Size(391, 150); + DataGridView.TabIndex = 8; + // + // Column1 + // + Column1.HeaderText = "Column1"; + Column1.Name = "Column1"; + Column1.Visible = false; + // + // Название + // + Название.HeaderText = "Название"; + Название.Name = "Название"; + Название.ReadOnly = true; + Название.Width = 150; + // + // Цена + // + Цена.HeaderText = "Цена"; + Цена.Name = "Цена"; + Цена.ReadOnly = true; + // + // Количество + // + Количество.HeaderText = "Количество"; + Количество.Name = "Количество"; + Количество.ReadOnly = true; + // + // ShopForm + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(411, 285); + Controls.Add(DataGridView); + Controls.Add(CancelButton); + Controls.Add(SaveButton); + Controls.Add(DateLabel); + Controls.Add(AdressLabel); + Controls.Add(NameLabel); + Controls.Add(AddressTextBox); + Controls.Add(NameTextBox); + Controls.Add(DateTimePicker); + Name = "ShopForm"; + Text = "ShopForm"; + Load += ShopForm_Load; + ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); + ResumeLayout(false); + PerformLayout(); + } + + #endregion + + private DateTimePicker DateTimePicker; + private TextBox NameTextBox; + private TextBox AddressTextBox; + private Label NameLabel; + private Label AdressLabel; + private Label DateLabel; + private Button SaveButton; + private Button CancelButton; + private DataGridView DataGridView; + private DataGridViewTextBoxColumn Column1; + private DataGridViewTextBoxColumn Название; + private DataGridViewTextBoxColumn Цена; + private DataGridViewTextBoxColumn Количество; + } +} \ No newline at end of file diff --git a/IceCreamShop/IceCreamShop/ShopForm.cs b/IceCreamShop/IceCreamShop/ShopForm.cs new file mode 100644 index 0000000..7af90da --- /dev/null +++ b/IceCreamShop/IceCreamShop/ShopForm.cs @@ -0,0 +1,124 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.BusinessLogicsContracts; +using IceCreamShopContracts.SearchModels; +using IceCreamShopDataModels.Models; +using Microsoft.Extensions.Logging; +using System; +using System.Collections; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace IceCreamShop +{ + public partial class ShopForm : Form + { + private readonly ILogger _logger; + private readonly IShopLogic _logic; + public int? _id; + private Dictionary _iceCreams; + public ShopForm(ILogger logger, IShopLogic logic) + { + InitializeComponent(); + _logger = logger; + _logic = logic; + } + + private void ShopForm_Load(object sender, EventArgs e) + { + if (_id.HasValue) + { + _logger.LogInformation("Загрузка магазина"); + try + { + var shop = _logic.ReadElement(new ShopSearchModel { Id = _id }); + if (shop != null) + { + NameTextBox.Text = shop.ShopName; + AddressTextBox.Text = shop.Address; + DateTimePicker.Text = shop.DateOpen.ToString(); + _iceCreams = shop.ShopIceCreams; + } + LoadData(); + } + catch (Exception ex) + { + _logger.LogError(ex, "Ошибка загрузки магазина"); + MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, + MessageBoxIcon.Error); + } + } + } + + private void LoadData() + { + _logger.LogInformation("Загрузка товаров магазина"); + try + { + if (_iceCreams != null) + { + foreach (var iceCream in _iceCreams) + { + DataGridView.Rows.Add(new object[] { iceCream.Key, iceCream.Value.Item1.IceCreamName, iceCream.Value.Item1.Price, iceCream.Value.Item2 }); + } + } + } + catch (Exception ex) + { + _logger.LogError(ex, "Ошибка загрузки изделий магазина"); + MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, + MessageBoxIcon.Error); + } + } + + private void CancelButton_Click(object sender, EventArgs e) + { + DialogResult = DialogResult.Cancel; + Close(); + } + + private void SaveButton_Click(object sender, EventArgs e) + { + if (string.IsNullOrEmpty(NameTextBox.Text)) + { + MessageBox.Show("Заполните название", "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error); + return; + } + if (string.IsNullOrEmpty(AddressTextBox.Text)) + { + MessageBox.Show("Заполните адрес", "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error); + return; + } + _logger.LogInformation("Сохранение магазина"); + try + { + var model = new ShopBindingModel + { + Id = _id ?? 0, + ShopName = NameTextBox.Text, + Address = AddressTextBox.Text, + DateOpen = DateTimePicker.Value.Date, + ShopIceCreams = _iceCreams + }; + var operationResult = _id.HasValue ? _logic.Update(model) : _logic.Create(model); + if (!operationResult) + { + throw new Exception("Ошибка при сохранении. Дополнительная информация в логах."); + } + MessageBox.Show("Сохранение прошло успешно", "Сообщение", MessageBoxButtons.OK, MessageBoxIcon.Information); + DialogResult = DialogResult.OK; + Close(); + } + catch (Exception ex) + { + _logger.LogError(ex, "Ошибка сохранения магазина"); + MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error); + } + } + } +} diff --git a/IceCreamShop/IceCreamShop/ShopForm.resx b/IceCreamShop/IceCreamShop/ShopForm.resx new file mode 100644 index 0000000..ba02ef3 --- /dev/null +++ b/IceCreamShop/IceCreamShop/ShopForm.resx @@ -0,0 +1,132 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 + + + True + + + True + + + True + + + True + + \ No newline at end of file diff --git a/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs b/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs new file mode 100644 index 0000000..ba6dcaf --- /dev/null +++ b/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs @@ -0,0 +1,117 @@ +namespace IceCreamShop +{ + partial class ShopsForm + { + /// + /// 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() + { + DataGridView = new DataGridView(); + AddButton = new Button(); + UpdateButton = new Button(); + RefreshButton = new Button(); + DeleteButton = new Button(); + ((System.ComponentModel.ISupportInitialize)DataGridView).BeginInit(); + SuspendLayout(); + // + // DataGridView + // + DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; + DataGridView.Location = new Point(12, 12); + DataGridView.Name = "DataGridView"; + DataGridView.Size = new Size(393, 374); + DataGridView.TabIndex = 0; + // + // AddButton + // + AddButton.Location = new Point(411, 12); + AddButton.Name = "AddButton"; + AddButton.Size = new Size(114, 23); + AddButton.TabIndex = 1; + AddButton.Text = "Добавить"; + AddButton.UseVisualStyleBackColor = true; + AddButton.Click += AddButton_Click; + // + // UpdateButton + // + UpdateButton.Location = new Point(411, 41); + UpdateButton.Name = "UpdateButton"; + UpdateButton.Size = new Size(114, 23); + UpdateButton.TabIndex = 2; + UpdateButton.Text = "Изменить"; + UpdateButton.UseVisualStyleBackColor = true; + UpdateButton.Click += UpdateButton_Click; + // + // RefreshButton + // + RefreshButton.Location = new Point(411, 70); + RefreshButton.Name = "RefreshButton"; + RefreshButton.Size = new Size(114, 23); + RefreshButton.TabIndex = 3; + RefreshButton.Text = "Обновить"; + RefreshButton.UseVisualStyleBackColor = true; + RefreshButton.Click += RefreshButton_Click; + // + // DeleteButton + // + DeleteButton.Location = new Point(411, 99); + DeleteButton.Name = "DeleteButton"; + DeleteButton.Size = new Size(114, 23); + DeleteButton.TabIndex = 4; + DeleteButton.Text = "Удалить"; + DeleteButton.UseVisualStyleBackColor = true; + DeleteButton.Click += DeleteButton_Click; + // + // ShopsForm + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(539, 403); + Controls.Add(DeleteButton); + Controls.Add(RefreshButton); + Controls.Add(UpdateButton); + Controls.Add(AddButton); + Controls.Add(DataGridView); + Name = "ShopsForm"; + Text = "ShopsForm"; + Load += ShopsForm_Load; + ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); + ResumeLayout(false); + } + + #endregion + + private DataGridView DataGridView; + private Button AddButton; + private Button UpdateButton; + private Button RefreshButton; + private Button DeleteButton; + private DataGridViewTextBoxColumn Column1; + private DataGridViewTextBoxColumn Column2; + private DataGridViewTextBoxColumn Column3; + private DataGridViewTextBoxColumn Column4; + private DataGridViewTextBoxColumn Column5; + } +} \ No newline at end of file diff --git a/IceCreamShop/IceCreamShop/ShopsForm.cs b/IceCreamShop/IceCreamShop/ShopsForm.cs new file mode 100644 index 0000000..19caee5 --- /dev/null +++ b/IceCreamShop/IceCreamShop/ShopsForm.cs @@ -0,0 +1,118 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.BusinessLogicsContracts; +using Microsoft.Extensions.Logging; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace IceCreamShop +{ + public partial class ShopsForm : Form + { + private readonly ILogger _logger; + private readonly IShopLogic _logic; + public ShopsForm(ILogger logger, IShopLogic logic) + { + InitializeComponent(); + _logger = logger; + _logic = logic; + } + + + private void LoadData() + { + try + { + var list = _logic.ReadList(null); + if (list != null) + { + DataGridView.DataSource = list; + DataGridView.Columns["Id"].Visible = false; + DataGridView.Columns["ShopName"].AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill; + DataGridView.Columns["Address"].AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill; + DataGridView.Columns["DateOpen"].AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill; + DataGridView.Columns["ShopIceCreams"].Visible = false; + } + _logger.LogInformation("Загрузка магазинов"); + } + catch (Exception ex) + { + _logger.LogError(ex, "Ошибка загрузки магазинов"); + MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error); + } + } + + private void ShopsForm_Load(object sender, EventArgs e) + { + LoadData(); + } + + private void AddButton_Click(object sender, EventArgs e) + { + var service = Program.ServiceProvider?.GetService(typeof(ShopForm)); + if (service is ShopForm form) + { + if (form.ShowDialog() == DialogResult.OK) + { + LoadData(); + } + } + } + + private void UpdateButton_Click(object sender, EventArgs e) + { + if (DataGridView.SelectedRows.Count == 1) + { + var service = Program.ServiceProvider?.GetService(typeof(ShopForm)); + if (service is ShopForm form) + { + var tmp = Convert.ToInt32(DataGridView.SelectedRows[0].Cells["Id"].Value); + form._id = Convert.ToInt32(DataGridView.SelectedRows[0].Cells["Id"].Value); + if (form.ShowDialog() == DialogResult.OK) + { + LoadData(); + } + } + } + } + + private void RefreshButton_Click(object sender, EventArgs e) + { + LoadData(); + } + + private void DeleteButton_Click(object sender, EventArgs e) + { + if (DataGridView.SelectedRows.Count == 1) + { + if (MessageBox.Show("Удалить запись?", "Вопрос", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes) + { + int id = Convert.ToInt32(DataGridView.SelectedRows[0].Cells["Id"].Value); + _logger.LogInformation("Удаление магазина"); + try + { + if (!_logic.Delete(new ShopBindingModel + { + Id = id + })) + { + throw new Exception("Ошибка при удалении. Дополнительная информация в логах."); + } + LoadData(); + } + catch (Exception ex) + { + _logger.LogError(ex, "Ошибка удаления магазина"); + MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error); + } + } + } + } + } +} diff --git a/IceCreamShop/IceCreamShop/ShopsForm.resx b/IceCreamShop/IceCreamShop/ShopsForm.resx new file mode 100644 index 0000000..af32865 --- /dev/null +++ b/IceCreamShop/IceCreamShop/ShopsForm.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs b/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs new file mode 100644 index 0000000..665a3e0 --- /dev/null +++ b/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs @@ -0,0 +1,105 @@ +namespace IceCreamShop +{ + partial class SupplyForm + { + /// + /// 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() + { + ShopComboBox = new ComboBox(); + IceCreamComboBox = new ComboBox(); + CountTextBox = new TextBox(); + SaveButton = new Button(); + CancelButton = new Button(); + SuspendLayout(); + // + // ShopComboBox + // + ShopComboBox.FormattingEnabled = true; + ShopComboBox.Location = new Point(12, 12); + ShopComboBox.Name = "ShopComboBox"; + ShopComboBox.Size = new Size(331, 23); + ShopComboBox.TabIndex = 0; + // + // IceCreamComboBox + // + IceCreamComboBox.FormattingEnabled = true; + IceCreamComboBox.Location = new Point(12, 41); + IceCreamComboBox.Name = "IceCreamComboBox"; + IceCreamComboBox.Size = new Size(331, 23); + IceCreamComboBox.TabIndex = 1; + // + // CountTextBox + // + CountTextBox.Location = new Point(12, 70); + CountTextBox.Name = "CountTextBox"; + CountTextBox.Size = new Size(331, 23); + CountTextBox.TabIndex = 2; + // + // SaveButton + // + SaveButton.Location = new Point(187, 99); + SaveButton.Name = "SaveButton"; + SaveButton.Size = new Size(75, 23); + SaveButton.TabIndex = 3; + SaveButton.Text = "Сохранить"; + SaveButton.UseVisualStyleBackColor = true; + SaveButton.Click += SaveButton_Click; + // + // CancelButton + // + CancelButton.Location = new Point(268, 99); + CancelButton.Name = "CancelButton"; + CancelButton.Size = new Size(75, 23); + CancelButton.TabIndex = 4; + CancelButton.Text = "Отмена"; + CancelButton.UseVisualStyleBackColor = true; + CancelButton.Click += CancelButton_Click; + // + // SupplyForm + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(355, 136); + Controls.Add(CancelButton); + Controls.Add(SaveButton); + Controls.Add(CountTextBox); + Controls.Add(IceCreamComboBox); + Controls.Add(ShopComboBox); + Name = "SupplyForm"; + Text = "SupplyForm"; + ResumeLayout(false); + PerformLayout(); + } + + #endregion + + private ComboBox ShopComboBox; + private ComboBox IceCreamComboBox; + private TextBox CountTextBox; + private Button SaveButton; + private Button CancelButton; + } +} \ No newline at end of file diff --git a/IceCreamShop/IceCreamShop/SupplyForm.cs b/IceCreamShop/IceCreamShop/SupplyForm.cs new file mode 100644 index 0000000..83c1961 --- /dev/null +++ b/IceCreamShop/IceCreamShop/SupplyForm.cs @@ -0,0 +1,153 @@ +using IceCreamShopBusinessLogic.BusinessLogic; +using IceCreamShopContracts.BusinessLogicsContracts; +using IceCreamShopContracts.SearchModels; +using IceCreamShopContracts.ViewModels; +using IceCreamShopDataModels.Models; +using System; +using System.Collections; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace IceCreamShop +{ + public partial class SupplyForm : Form + { + private readonly List? _iceCreamList; + private readonly List? _shopsList; + IShopLogic _shopLogic; + IIceCreamLogic _iceCreamLogic; + public int ShopId + { + get + { + return + Convert.ToInt32(ShopComboBox.SelectedValue); + } + set + { + ShopComboBox.SelectedValue = value; + } + } + public int IceCreamId + { + get + { + return + Convert.ToInt32(IceCreamComboBox.SelectedValue); + } + set + { + IceCreamComboBox.SelectedValue = value; + } + } + + public IIceCreamModel? IceCreamModel + { + get + { + if (_iceCreamList == null) + { + return null; + } + foreach (var elem in _iceCreamList) + { + if (elem.Id == IceCreamId) + { + return elem; + } + } + return null; + } + } + + + public int Count + { + get { return Convert.ToInt32(CountTextBox.Text); } + set + { CountTextBox.Text = value.ToString(); } + } + public SupplyForm(IIceCreamLogic iceCreamLogic, IShopLogic shopLogic) + { + InitializeComponent(); + _shopLogic = shopLogic; + _iceCreamLogic = iceCreamLogic; + _iceCreamList = iceCreamLogic.ReadList(null); + _shopsList = shopLogic.ReadList(null); + if (_iceCreamList != null) + { + IceCreamComboBox.DisplayMember = "IceCreamName"; + IceCreamComboBox.ValueMember = "Id"; + IceCreamComboBox.DataSource = _iceCreamList; + IceCreamComboBox.SelectedItem = null; + } + if (_shopsList != null) + { + ShopComboBox.DisplayMember = "ShopName"; + ShopComboBox.ValueMember = "Id"; + ShopComboBox.DataSource = _shopsList; + ShopComboBox.SelectedItem = null; + } + } + + private void SaveButton_Click(object sender, EventArgs e) + { + if (string.IsNullOrEmpty(CountTextBox.Text)) + { + MessageBox.Show("Заполните поле Количество", "Ошибка", + MessageBoxButtons.OK, MessageBoxIcon.Error); + return; + } + if (IceCreamComboBox.SelectedValue == null) + { + MessageBox.Show("Выберите мороженное", "Ошибка", + MessageBoxButtons.OK, MessageBoxIcon.Error); + return; + } + if (ShopComboBox.SelectedValue == null) + { + MessageBox.Show("Выберите магазин", "Ошибка", + MessageBoxButtons.OK, MessageBoxIcon.Error); + return; + } + + try + { + int count = Convert.ToInt32(CountTextBox.Text); + + bool res = _shopLogic.MakeSupply( + new ShopSearchModel() { Id = Convert.ToInt32(ShopComboBox.SelectedValue) }, + _iceCreamLogic.ReadElement(new() { Id = Convert.ToInt32(IceCreamComboBox.SelectedValue) }), + count + ); + + if (!res) + { + throw new Exception("Ошибка при пополнении. Дополнительная информация в логах"); + } + + MessageBox.Show("Пополнение прошло успешно"); + DialogResult = DialogResult.OK; + Close(); + + } + catch (Exception err) + { + MessageBox.Show("Ошибка пополнения"); + return; + } + } + + private void CancelButton_Click(object sender, EventArgs e) + { + DialogResult = DialogResult.Cancel; + Close(); + } + } +} diff --git a/IceCreamShop/IceCreamShop/SupplyForm.resx b/IceCreamShop/IceCreamShop/SupplyForm.resx new file mode 100644 index 0000000..af32865 --- /dev/null +++ b/IceCreamShop/IceCreamShop/SupplyForm.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs b/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs new file mode 100644 index 0000000..fcf4dac --- /dev/null +++ b/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs @@ -0,0 +1,137 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.BusinessLogicsContracts; +using IceCreamShopContracts.SearchModels; +using IceCreamShopContracts.StoragesContracts; +using IceCreamShopContracts.ViewModels; +using IceCreamShopDataModels.Models; +using Microsoft.Extensions.Logging; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopBusinessLogic.BusinessLogic +{ + public class ShopLogic : IShopLogic + { + private readonly ILogger _logger; + private readonly IShopStorage _shopStorage; + + public ShopLogic(ILogger logger, IShopStorage shopStorage) + { + _logger = logger; + _shopStorage = shopStorage; + } + + public List ReadList(ShopSearchModel model) + { + _logger.LogInformation("ReadList. ShopName:{Name}. Id:{ Id}", model?.Name, model?.Id); + var list = model == null ? _shopStorage.GetFullList() : +_shopStorage.GetFilteredList(model); + if (list == null) + { + _logger.LogWarning("ReadList return null list"); + return null; + } + _logger.LogInformation("ReadList. Count:{Count}", list.Count); + return list; + + } + + public bool MakeSupply(ShopSearchModel model, IIceCreamModel iceCream, int count) + { + if (model == null) + return false; + return _shopStorage.SupplyIceCream(model, iceCream, count); + } + + public ShopViewModel ReadElement(ShopSearchModel model) + { + if (model == null) + { + throw new ArgumentNullException(nameof(model)); + } + _logger.LogInformation("ReadElement. ShopName:{ShopName}.Id:{ Id}", model.Name, model.Id); + var element = _shopStorage.GetElement(model); + if (element == null) + { + _logger.LogWarning("ReadElement element not found"); + return null; + } + _logger.LogInformation("ReadElement find. Id:{Id}", element.Id); + return element; + } + + public bool Create(ShopBindingModel model) + { + CheckModel(model); + if (_shopStorage.Insert(model) == null) + { + _logger.LogWarning("Insert operation failed"); + return false; + } + return true; + } + + public bool Update(ShopBindingModel model) + { + CheckModel(model); + if (_shopStorage.Update(model) == null) + { + _logger.LogWarning("Update operation failed"); + return false; + } + return true; + } + public bool Delete(ShopBindingModel model) + { + CheckModel(model, false); + _logger.LogInformation("Delete. Id:{Id}", model.Id); + if (_shopStorage.Delete(model) == null) + { + _logger.LogWarning("Delete operation failed"); + return false; + } + return true; + } + + private void CheckModel(ShopBindingModel model, bool withParams = +true) + { + if (model == null) + { + throw new ArgumentNullException(nameof(model)); + } + if (!withParams) + { + return; + } + if (string.IsNullOrEmpty(model.ShopName)) + { + throw new ArgumentNullException("Нет названия магазина", + nameof(model.ShopName)); + } + if (string.IsNullOrEmpty(model.Address)) + { + throw new ArgumentNullException("Нет адресса магазина", + nameof(model.ShopName)); + } + if(model.DateOpen == null) + { + throw new ArgumentNullException("Нет даты открытия магазина", + nameof(model.ShopName)); + } + _logger.LogInformation("Shop. ShopName:{ShopName}.Address:{Address}. DateOpen:{DateOpen}. Id: { Id}", model.ShopName, model.Address, model.DateOpen, model.Id); + var element = _shopStorage.GetElement(new ShopSearchModel + { + Name = model.ShopName + }); + if (element != null && element.Id != model.Id) + { + throw new InvalidOperationException("Магазин с таким названием уже есть"); + } + } + + } +} diff --git a/IceCreamShop/IceCreamShopContracts/BindingModels/ShopBindingModel.cs b/IceCreamShop/IceCreamShopContracts/BindingModels/ShopBindingModel.cs new file mode 100644 index 0000000..9b202bf --- /dev/null +++ b/IceCreamShop/IceCreamShopContracts/BindingModels/ShopBindingModel.cs @@ -0,0 +1,18 @@ +using IceCreamShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopContracts.BindingModels +{ + public class ShopBindingModel : IShopModel + { + public int Id { get; set; } + public string ShopName { get; set; } + public string Address { get; set; } + public DateTime DateOpen { get; set; } + public Dictionary ShopIceCreams { get; set; } = new(); + } +} diff --git a/IceCreamShop/IceCreamShopContracts/BusinessLogicsContracts/IShopLogic.cs b/IceCreamShop/IceCreamShopContracts/BusinessLogicsContracts/IShopLogic.cs new file mode 100644 index 0000000..c9ee0e2 --- /dev/null +++ b/IceCreamShop/IceCreamShopContracts/BusinessLogicsContracts/IShopLogic.cs @@ -0,0 +1,22 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.SearchModels; +using IceCreamShopContracts.ViewModels; +using IceCreamShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopContracts.BusinessLogicsContracts +{ + public interface IShopLogic + { + List? ReadList(ShopSearchModel? model); + ShopViewModel? ReadElement(ShopSearchModel model); + bool Create(ShopBindingModel model); + bool Update(ShopBindingModel model); + bool Delete(ShopBindingModel model); + bool MakeSupply(ShopSearchModel model, IIceCreamModel iceCream, int count); + } +} diff --git a/IceCreamShop/IceCreamShopContracts/SearchModels/ShopSearchModel.cs b/IceCreamShop/IceCreamShopContracts/SearchModels/ShopSearchModel.cs new file mode 100644 index 0000000..7aa5eb4 --- /dev/null +++ b/IceCreamShop/IceCreamShopContracts/SearchModels/ShopSearchModel.cs @@ -0,0 +1,15 @@ +using IceCreamShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopContracts.SearchModels +{ + public class ShopSearchModel + { + public int? Id { get; set; } + public string? Name { get; set; } + } +} diff --git a/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs b/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs new file mode 100644 index 0000000..500cf16 --- /dev/null +++ b/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs @@ -0,0 +1,23 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.SearchModels; +using IceCreamShopContracts.ViewModels; +using IceCreamShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopContracts.StoragesContracts +{ + public interface IShopStorage + { + List GetFullList(); + List GetFilteredList(ShopSearchModel model); + ShopViewModel? GetElement(ShopSearchModel model); + ShopViewModel? Insert(ShopBindingModel model); + ShopViewModel? Update(ShopBindingModel model); + ShopViewModel? Delete(ShopBindingModel model); + bool SupplyIceCream(ShopSearchModel model, IIceCreamModel iceCream, int Count); + } +} diff --git a/IceCreamShop/IceCreamShopContracts/ViewModels/ShopViewModel.cs b/IceCreamShop/IceCreamShopContracts/ViewModels/ShopViewModel.cs new file mode 100644 index 0000000..0b93fb1 --- /dev/null +++ b/IceCreamShop/IceCreamShopContracts/ViewModels/ShopViewModel.cs @@ -0,0 +1,22 @@ +using IceCreamShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopContracts.ViewModels +{ + public class ShopViewModel : IShopModel + { + public int Id { get; set; } + [DisplayName("Название магазина")] + public string ShopName { get; set; } + [DisplayName("Адрес магазина")] + public string Address { get; set; } + [DisplayName("Дата открытия")] + public DateTime DateOpen { get; set; } + public Dictionary ShopIceCreams { get; set; } = new(); + } +} diff --git a/IceCreamShop/IceCreamShopDataModels/IShopModel.cs b/IceCreamShop/IceCreamShopDataModels/IShopModel.cs new file mode 100644 index 0000000..b852783 --- /dev/null +++ b/IceCreamShop/IceCreamShopDataModels/IShopModel.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopDataModels.Models +{ + public interface IShopModel : IId + { + string ShopName { get; } + string Address { get; } + DateTime DateOpen { get; } + Dictionary ShopIceCreams { get; } + } +} diff --git a/IceCreamShop/IceCreamShopListImplement/DataListSingleton.cs b/IceCreamShop/IceCreamShopListImplement/DataListSingleton.cs index 56da6b9..c3be853 100644 --- a/IceCreamShop/IceCreamShopListImplement/DataListSingleton.cs +++ b/IceCreamShop/IceCreamShopListImplement/DataListSingleton.cs @@ -13,11 +13,13 @@ namespace IceCreamShopListImplement public List Components { get; set; } public List Orders { get; set; } public List IceCreams { get; set; } + public List Shops { get; set; } private DataListSingleton() { Components = new List(); Orders = new List(); IceCreams = new List(); + Shops = new List(); } public static DataListSingleton GetInstance() { diff --git a/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs b/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs new file mode 100644 index 0000000..b9a24f6 --- /dev/null +++ b/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs @@ -0,0 +1,139 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.SearchModels; +using IceCreamShopContracts.StoragesContracts; +using IceCreamShopContracts.ViewModels; +using IceCreamShopDataModels.Models; +using IceCreamShopListImplement.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace IceCreamShopListImplement.Implements +{ + public class ShopStorage : IShopStorage + { + private readonly DataListSingleton _source; + public ShopStorage() + { + _source = DataListSingleton.GetInstance(); + } + public List GetFullList() + { + var result = new List(); + foreach (var shop in _source.Shops) + { + result.Add(shop.GetViewModel); + } + return result; + } + public List GetFilteredList(ShopSearchModel + model) + { + var result = new List(); + if (string.IsNullOrEmpty(model.Name)) + { + return result; + } + foreach (var shop in _source.Shops) + { + if (shop.ShopName.Contains(model.Name)) + { + result.Add(shop.GetViewModel); + } + } + return result; + } + public ShopViewModel? GetElement(ShopSearchModel model) + { + if (string.IsNullOrEmpty(model.Name) && !model.Id.HasValue) + { + return null; + } + foreach (var shop in _source.Shops) + { + if ((!string.IsNullOrEmpty(model.Name) && + shop.ShopName == model.Name) || + (model.Id.HasValue && shop.Id == model.Id)) + { + return shop.GetViewModel; + } + } + return null; + } + public ShopViewModel? Insert(ShopBindingModel model) + { + model.Id = 1; + foreach (var shop in _source.Shops) + { + if (model.Id <= shop.Id) + { + model.Id = shop.Id + 1; + } + } + var newShop = Shop.Create(model); + if (newShop == null) + { + return null; + } + _source.Shops.Add(newShop); + return newShop.GetViewModel; + } + public ShopViewModel? Update(ShopBindingModel model) + { + foreach (var shop in _source.Shops) + { + if (shop.Id == model.Id) + { + shop.Update(model); + return shop.GetViewModel; + } + } + return null; + } + public ShopViewModel? Delete(ShopBindingModel model) + { + for (int i = 0; i < _source.Shops.Count; ++i) + { + if (_source.Shops[i].Id == model.Id) + { + var element = _source.Shops[i]; + _source.Shops.RemoveAt(i); + return element.GetViewModel; + } + } + return null; + } + + public bool SupplyIceCream(ShopSearchModel model, IIceCreamModel iceCream, int count) { + if (model == null) + throw new ArgumentNullException(nameof(model)); + if (iceCream == null) + throw new ArgumentNullException(nameof(iceCream)); + if (count <= 0) + throw new ArgumentNullException("Количество должно быть положительным числом"); + + ShopViewModel curModel = GetElement(model); + if(curModel == null) + throw new ArgumentNullException(nameof(curModel)); + if (curModel.ShopIceCreams.TryGetValue(iceCream.Id, out var pair)) + { + curModel.ShopIceCreams[iceCream.Id] = (pair.Item1, pair.Item2 + count); + } + else + { + curModel.ShopIceCreams.Add(iceCream.Id, (iceCream, count)); + } + Update(new() + { + Id = curModel.Id, + ShopName = curModel.ShopName, + DateOpen = curModel.DateOpen, + Address = curModel.Address, + ShopIceCreams = curModel.ShopIceCreams, + }); + return true; + } + } +} diff --git a/IceCreamShop/IceCreamShopListImplement/Models/Shop.cs b/IceCreamShop/IceCreamShopListImplement/Models/Shop.cs new file mode 100644 index 0000000..239004a --- /dev/null +++ b/IceCreamShop/IceCreamShopListImplement/Models/Shop.cs @@ -0,0 +1,56 @@ +using IceCreamShopContracts.BindingModels; +using IceCreamShopContracts.ViewModels; +using IceCreamShopDataModels.Models; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Xml.Linq; + +namespace IceCreamShopListImplement.Models +{ + public class Shop : IShopModel + { + public int Id { get; private set; } + public string ShopName { get; private set; } + public string Address { get; private set; } + public DateTime DateOpen { get; private set; } + public Dictionary ShopIceCreams { get; private set; } = new(); + + public static Shop? Create (ShopBindingModel model) + { + if (model == null) + return null; + return new Shop() + { + Id = model.Id, + ShopName = model.ShopName, + Address = model.Address, + DateOpen = model.DateOpen, + ShopIceCreams = new() + }; + } + + public void Update(ShopBindingModel? model) + { + if (model == null) + { + return; + } + ShopName = model.ShopName; + Address = model.Address; + DateOpen = model.DateOpen; + ShopIceCreams = model.ShopIceCreams; + } + + public ShopViewModel GetViewModel => new() + { + Id = Id, + ShopName = ShopName, + Address = Address, + DateOpen = DateOpen, + ShopIceCreams = ShopIceCreams + }; + } +} -- 2.25.1 From 1ba81fdfeadb6fd6fc7fd5547b5c680f12905637 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Tue, 13 Feb 2024 13:35:33 +0400 Subject: [PATCH 2/7] =?UTF-8?q?=D0=9F=D0=B5=D1=80=D0=B5=D0=B8=D0=BC=D0=B5?= =?UTF-8?q?=D0=BD=D0=BE=D0=B2=D0=B0=D0=BB=20=D1=84=D0=BE=D1=80=D0=BC=D1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IceCreamShop/ComponentForm.Designer.cs | 35 ++++++++----------- .../IceCreamShop/ComponentsForm.Designer.cs | 2 +- .../IceCreamComponentForm.Designer.cs | 35 ++++++++----------- .../IceCreamShop/IceCreamForm.Designer.cs | 2 +- 4 files changed, 32 insertions(+), 42 deletions(-) diff --git a/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs b/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs index 510512c..52c0a82 100644 --- a/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs @@ -38,45 +38,42 @@ // // NameTextBox // - NameTextBox.Location = new Point(92, 13); - NameTextBox.Margin = new Padding(3, 4, 3, 4); + NameTextBox.Location = new Point(80, 10); NameTextBox.Name = "NameTextBox"; - NameTextBox.Size = new Size(277, 27); + NameTextBox.Size = new Size(243, 23); NameTextBox.TabIndex = 0; // // CostTextBox // - CostTextBox.Location = new Point(92, 56); - CostTextBox.Margin = new Padding(3, 4, 3, 4); + CostTextBox.Location = new Point(80, 42); CostTextBox.Name = "CostTextBox"; - CostTextBox.Size = new Size(135, 27); + CostTextBox.Size = new Size(119, 23); CostTextBox.TabIndex = 1; // // NameLabel // NameLabel.AutoSize = true; - NameLabel.Location = new Point(8, 27); + NameLabel.Location = new Point(7, 20); NameLabel.Name = "NameLabel"; - NameLabel.Size = new Size(77, 20); + NameLabel.Size = new Size(59, 15); NameLabel.TabIndex = 2; NameLabel.Text = "Название"; // // CostLabel // CostLabel.AutoSize = true; - CostLabel.Location = new Point(8, 65); + CostLabel.Location = new Point(7, 49); CostLabel.Name = "CostLabel"; - CostLabel.Size = new Size(45, 20); + CostLabel.Size = new Size(35, 15); CostLabel.TabIndex = 3; CostLabel.Text = "Цена"; // // CancelButton // CancelButton.Anchor = AnchorStyles.Bottom | AnchorStyles.Right; - CancelButton.Location = new Point(282, 91); - CancelButton.Margin = new Padding(3, 4, 3, 4); + CancelButton.Location = new Point(247, 68); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(86, 31); + CancelButton.Size = new Size(75, 23); CancelButton.TabIndex = 4; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -85,10 +82,9 @@ // SaveButton // SaveButton.Anchor = AnchorStyles.Bottom | AnchorStyles.Right; - SaveButton.Location = new Point(189, 91); - SaveButton.Margin = new Padding(3, 4, 3, 4); + SaveButton.Location = new Point(165, 68); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(86, 31); + SaveButton.Size = new Size(75, 23); SaveButton.TabIndex = 5; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -96,19 +92,18 @@ // // ComponentForm // - AutoScaleDimensions = new SizeF(8F, 20F); + AutoScaleDimensions = new SizeF(7F, 15F); AutoScaleMode = AutoScaleMode.Font; AutoSizeMode = AutoSizeMode.GrowAndShrink; - ClientSize = new Size(381, 129); + ClientSize = new Size(333, 97); Controls.Add(SaveButton); Controls.Add(CancelButton); Controls.Add(CostLabel); Controls.Add(NameLabel); Controls.Add(CostTextBox); Controls.Add(NameTextBox); - Margin = new Padding(3, 4, 3, 4); Name = "ComponentForm"; - Text = "Компонент"; + Text = "ComponentForm"; Load += ComponentForm_Load; ResumeLayout(false); PerformLayout(); diff --git a/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs b/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs index 9a2ef3d..f2c8139 100644 --- a/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs @@ -95,7 +95,7 @@ Controls.Add(AddButton); Controls.Add(DataGridView); Name = "ComponentsForm"; - Text = "Компоненты"; + Text = "ComponentsForm"; Load += ComponentsForm_Load; ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); ResumeLayout(false); diff --git a/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs b/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs index cfa4ba4..7406dd4 100644 --- a/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs @@ -39,44 +39,41 @@ // ComponentLabel // ComponentLabel.AutoSize = true; - ComponentLabel.Location = new Point(14, 12); + ComponentLabel.Location = new Point(12, 9); ComponentLabel.Name = "ComponentLabel"; - ComponentLabel.Size = new Size(88, 20); + ComponentLabel.Size = new Size(69, 15); ComponentLabel.TabIndex = 0; ComponentLabel.Text = "Компонент"; // // CountLabel // CountLabel.AutoSize = true; - CountLabel.Location = new Point(14, 53); + CountLabel.Location = new Point(12, 40); CountLabel.Name = "CountLabel"; - CountLabel.Size = new Size(90, 20); + CountLabel.Size = new Size(72, 15); CountLabel.TabIndex = 1; CountLabel.Text = "Количество"; // // CountTextBox // - CountTextBox.Location = new Point(99, 49); - CountTextBox.Margin = new Padding(3, 4, 3, 4); + CountTextBox.Location = new Point(87, 37); CountTextBox.Name = "CountTextBox"; - CountTextBox.Size = new Size(333, 27); + CountTextBox.Size = new Size(292, 23); CountTextBox.TabIndex = 2; // // ComboBox // ComboBox.FormattingEnabled = true; - ComboBox.Location = new Point(99, 8); - ComboBox.Margin = new Padding(3, 4, 3, 4); + ComboBox.Location = new Point(87, 6); ComboBox.Name = "ComboBox"; - ComboBox.Size = new Size(333, 28); + ComboBox.Size = new Size(292, 23); ComboBox.TabIndex = 3; // // SaveButton // - SaveButton.Location = new Point(249, 88); - SaveButton.Margin = new Padding(3, 4, 3, 4); + SaveButton.Location = new Point(218, 66); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(86, 31); + SaveButton.Size = new Size(75, 23); SaveButton.TabIndex = 4; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -84,10 +81,9 @@ // // CancelButton // - CancelButton.Location = new Point(342, 88); - CancelButton.Margin = new Padding(3, 4, 3, 4); + CancelButton.Location = new Point(299, 66); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(86, 31); + CancelButton.Size = new Size(75, 23); CancelButton.TabIndex = 5; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -95,18 +91,17 @@ // // IceCreamComponentForm // - AutoScaleDimensions = new SizeF(8F, 20F); + AutoScaleDimensions = new SizeF(7F, 15F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(447, 128); + ClientSize = new Size(391, 96); Controls.Add(CancelButton); Controls.Add(SaveButton); Controls.Add(ComboBox); Controls.Add(CountTextBox); Controls.Add(CountLabel); Controls.Add(ComponentLabel); - Margin = new Padding(3, 4, 3, 4); Name = "IceCreamComponentForm"; - Text = "Компонент мороженного"; + Text = "IceCreamComponentForm"; ResumeLayout(false); PerformLayout(); } diff --git a/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs b/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs index 9c2476e..c799428 100644 --- a/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs @@ -198,7 +198,7 @@ Controls.Add(PriceLabel); Controls.Add(NameLabel); Name = "IceCreamForm"; - Text = "Мороженное"; + Text = "IceCreamForm"; Load += IceCreamForm_Load; ComponentsGroupBox.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); -- 2.25.1 From 2d37575b1e8058b74ae987883ba20c9611a3d3e8 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Tue, 20 Feb 2024 12:36:06 +0400 Subject: [PATCH 3/7] =?UTF-8?q?=D0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IceCreamShop/ComponentForm.Designer.cs | 35 +++++----- .../IceCreamShop/ComponentsForm.Designer.cs | 33 ++++++---- .../IceCreamComponentForm.Designer.cs | 35 +++++----- .../IceCreamShop/IceCreamForm.Designer.cs | 66 +++++++++++-------- .../IceCreamShop/IceCreamsForm.Designer.cs | 2 +- .../IceCreamShop/MainForm.Designer.cs | 65 ++++++++---------- .../IceCreamShop/ShopForm.Designer.cs | 57 ++++++++++------ .../IceCreamShop/ShopsForm.Designer.cs | 33 ++++++---- .../IceCreamShop/SupplyForm.Designer.cs | 32 +++++---- 9 files changed, 204 insertions(+), 154 deletions(-) diff --git a/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs b/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs index 52c0a82..c3bb312 100644 --- a/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/ComponentForm.Designer.cs @@ -38,42 +38,45 @@ // // NameTextBox // - NameTextBox.Location = new Point(80, 10); + NameTextBox.Location = new Point(91, 13); + NameTextBox.Margin = new Padding(3, 4, 3, 4); NameTextBox.Name = "NameTextBox"; - NameTextBox.Size = new Size(243, 23); + NameTextBox.Size = new Size(277, 27); NameTextBox.TabIndex = 0; // // CostTextBox // - CostTextBox.Location = new Point(80, 42); + CostTextBox.Location = new Point(91, 56); + CostTextBox.Margin = new Padding(3, 4, 3, 4); CostTextBox.Name = "CostTextBox"; - CostTextBox.Size = new Size(119, 23); + CostTextBox.Size = new Size(135, 27); CostTextBox.TabIndex = 1; // // NameLabel // NameLabel.AutoSize = true; - NameLabel.Location = new Point(7, 20); + NameLabel.Location = new Point(8, 27); NameLabel.Name = "NameLabel"; - NameLabel.Size = new Size(59, 15); + NameLabel.Size = new Size(77, 20); NameLabel.TabIndex = 2; NameLabel.Text = "Название"; // // CostLabel // CostLabel.AutoSize = true; - CostLabel.Location = new Point(7, 49); + CostLabel.Location = new Point(8, 65); CostLabel.Name = "CostLabel"; - CostLabel.Size = new Size(35, 15); + CostLabel.Size = new Size(45, 20); CostLabel.TabIndex = 3; CostLabel.Text = "Цена"; // // CancelButton // CancelButton.Anchor = AnchorStyles.Bottom | AnchorStyles.Right; - CancelButton.Location = new Point(247, 68); + CancelButton.Location = new Point(282, 91); + CancelButton.Margin = new Padding(3, 4, 3, 4); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(75, 23); + CancelButton.Size = new Size(86, 31); CancelButton.TabIndex = 4; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -82,9 +85,10 @@ // SaveButton // SaveButton.Anchor = AnchorStyles.Bottom | AnchorStyles.Right; - SaveButton.Location = new Point(165, 68); + SaveButton.Location = new Point(189, 91); + SaveButton.Margin = new Padding(3, 4, 3, 4); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(75, 23); + SaveButton.Size = new Size(86, 31); SaveButton.TabIndex = 5; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -92,18 +96,19 @@ // // ComponentForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; AutoSizeMode = AutoSizeMode.GrowAndShrink; - ClientSize = new Size(333, 97); + ClientSize = new Size(381, 129); Controls.Add(SaveButton); Controls.Add(CancelButton); Controls.Add(CostLabel); Controls.Add(NameLabel); Controls.Add(CostTextBox); Controls.Add(NameTextBox); + Margin = new Padding(3, 4, 3, 4); Name = "ComponentForm"; - Text = "ComponentForm"; + Text = "Форма компонент"; Load += ComponentForm_Load; ResumeLayout(false); PerformLayout(); diff --git a/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs b/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs index f2c8139..f030d2f 100644 --- a/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/ComponentsForm.Designer.cs @@ -39,16 +39,19 @@ // DataGridView // DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - DataGridView.Location = new Point(12, 12); + DataGridView.Location = new Point(14, 16); + DataGridView.Margin = new Padding(3, 4, 3, 4); DataGridView.Name = "DataGridView"; - DataGridView.Size = new Size(369, 350); + DataGridView.RowHeadersWidth = 51; + DataGridView.Size = new Size(422, 467); DataGridView.TabIndex = 0; // // AddButton // - AddButton.Location = new Point(387, 12); + AddButton.Location = new Point(442, 16); + AddButton.Margin = new Padding(3, 4, 3, 4); AddButton.Name = "AddButton"; - AddButton.Size = new Size(126, 23); + AddButton.Size = new Size(144, 31); AddButton.TabIndex = 1; AddButton.Text = "Добавить"; AddButton.UseVisualStyleBackColor = true; @@ -56,9 +59,10 @@ // // ChangeButton // - ChangeButton.Location = new Point(387, 41); + ChangeButton.Location = new Point(442, 55); + ChangeButton.Margin = new Padding(3, 4, 3, 4); ChangeButton.Name = "ChangeButton"; - ChangeButton.Size = new Size(126, 23); + ChangeButton.Size = new Size(144, 31); ChangeButton.TabIndex = 2; ChangeButton.Text = "Изменить"; ChangeButton.UseVisualStyleBackColor = true; @@ -66,9 +70,10 @@ // // DeleteButton // - DeleteButton.Location = new Point(387, 70); + DeleteButton.Location = new Point(442, 93); + DeleteButton.Margin = new Padding(3, 4, 3, 4); DeleteButton.Name = "DeleteButton"; - DeleteButton.Size = new Size(126, 23); + DeleteButton.Size = new Size(144, 31); DeleteButton.TabIndex = 3; DeleteButton.Text = "Удалить"; DeleteButton.UseVisualStyleBackColor = true; @@ -76,9 +81,10 @@ // // RefreshButton // - RefreshButton.Location = new Point(387, 99); + RefreshButton.Location = new Point(442, 132); + RefreshButton.Margin = new Padding(3, 4, 3, 4); RefreshButton.Name = "RefreshButton"; - RefreshButton.Size = new Size(126, 23); + RefreshButton.Size = new Size(144, 31); RefreshButton.TabIndex = 4; RefreshButton.Text = "Обновить"; RefreshButton.UseVisualStyleBackColor = true; @@ -86,16 +92,17 @@ // // ComponentsForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(525, 374); + ClientSize = new Size(600, 499); Controls.Add(RefreshButton); Controls.Add(DeleteButton); Controls.Add(ChangeButton); Controls.Add(AddButton); Controls.Add(DataGridView); + Margin = new Padding(3, 4, 3, 4); Name = "ComponentsForm"; - Text = "ComponentsForm"; + Text = "Форма компонентов"; Load += ComponentsForm_Load; ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); ResumeLayout(false); diff --git a/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs b/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs index 7406dd4..616115a 100644 --- a/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/IceCreamComponentForm.Designer.cs @@ -39,41 +39,44 @@ // ComponentLabel // ComponentLabel.AutoSize = true; - ComponentLabel.Location = new Point(12, 9); + ComponentLabel.Location = new Point(14, 12); ComponentLabel.Name = "ComponentLabel"; - ComponentLabel.Size = new Size(69, 15); + ComponentLabel.Size = new Size(88, 20); ComponentLabel.TabIndex = 0; ComponentLabel.Text = "Компонент"; // // CountLabel // CountLabel.AutoSize = true; - CountLabel.Location = new Point(12, 40); + CountLabel.Location = new Point(14, 53); CountLabel.Name = "CountLabel"; - CountLabel.Size = new Size(72, 15); + CountLabel.Size = new Size(90, 20); CountLabel.TabIndex = 1; CountLabel.Text = "Количество"; // // CountTextBox // - CountTextBox.Location = new Point(87, 37); + CountTextBox.Location = new Point(99, 49); + CountTextBox.Margin = new Padding(3, 4, 3, 4); CountTextBox.Name = "CountTextBox"; - CountTextBox.Size = new Size(292, 23); + CountTextBox.Size = new Size(333, 27); CountTextBox.TabIndex = 2; // // ComboBox // ComboBox.FormattingEnabled = true; - ComboBox.Location = new Point(87, 6); + ComboBox.Location = new Point(99, 8); + ComboBox.Margin = new Padding(3, 4, 3, 4); ComboBox.Name = "ComboBox"; - ComboBox.Size = new Size(292, 23); + ComboBox.Size = new Size(333, 28); ComboBox.TabIndex = 3; // // SaveButton // - SaveButton.Location = new Point(218, 66); + SaveButton.Location = new Point(249, 88); + SaveButton.Margin = new Padding(3, 4, 3, 4); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(75, 23); + SaveButton.Size = new Size(86, 31); SaveButton.TabIndex = 4; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -81,9 +84,10 @@ // // CancelButton // - CancelButton.Location = new Point(299, 66); + CancelButton.Location = new Point(342, 88); + CancelButton.Margin = new Padding(3, 4, 3, 4); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(75, 23); + CancelButton.Size = new Size(86, 31); CancelButton.TabIndex = 5; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -91,17 +95,18 @@ // // IceCreamComponentForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(391, 96); + ClientSize = new Size(447, 128); Controls.Add(CancelButton); Controls.Add(SaveButton); Controls.Add(ComboBox); Controls.Add(CountTextBox); Controls.Add(CountLabel); Controls.Add(ComponentLabel); + Margin = new Padding(3, 4, 3, 4); Name = "IceCreamComponentForm"; - Text = "IceCreamComponentForm"; + Text = "Форма компонент мороженного"; ResumeLayout(false); PerformLayout(); } diff --git a/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs b/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs index c799428..4f50382 100644 --- a/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/IceCreamForm.Designer.cs @@ -50,34 +50,36 @@ // NameLabel // NameLabel.AutoSize = true; - NameLabel.Location = new Point(12, 9); + NameLabel.Location = new Point(14, 12); NameLabel.Name = "NameLabel"; - NameLabel.Size = new Size(59, 15); + NameLabel.Size = new Size(77, 20); NameLabel.TabIndex = 0; NameLabel.Text = "Название"; // // PriceLabel // PriceLabel.AutoSize = true; - PriceLabel.Location = new Point(12, 35); + PriceLabel.Location = new Point(14, 47); PriceLabel.Name = "PriceLabel"; - PriceLabel.Size = new Size(35, 15); + PriceLabel.Size = new Size(45, 20); PriceLabel.TabIndex = 1; PriceLabel.Text = "Цена"; // // NameTextBox // - NameTextBox.Location = new Point(77, 6); + NameTextBox.Location = new Point(88, 8); + NameTextBox.Margin = new Padding(3, 4, 3, 4); NameTextBox.Name = "NameTextBox"; - NameTextBox.Size = new Size(237, 23); + NameTextBox.Size = new Size(270, 27); NameTextBox.TabIndex = 2; // // PriceTextBox // - PriceTextBox.Location = new Point(77, 32); + PriceTextBox.Location = new Point(88, 43); + PriceTextBox.Margin = new Padding(3, 4, 3, 4); PriceTextBox.Name = "PriceTextBox"; PriceTextBox.ReadOnly = true; - PriceTextBox.Size = new Size(100, 23); + PriceTextBox.Size = new Size(114, 27); PriceTextBox.TabIndex = 3; // // ComponentsGroupBox @@ -87,18 +89,21 @@ ComponentsGroupBox.Controls.Add(UpdateButton); ComponentsGroupBox.Controls.Add(AddButton); ComponentsGroupBox.Controls.Add(DataGridView); - ComponentsGroupBox.Location = new Point(12, 64); + ComponentsGroupBox.Location = new Point(14, 85); + ComponentsGroupBox.Margin = new Padding(3, 4, 3, 4); ComponentsGroupBox.Name = "ComponentsGroupBox"; - ComponentsGroupBox.Size = new Size(582, 287); + ComponentsGroupBox.Padding = new Padding(3, 4, 3, 4); + ComponentsGroupBox.Size = new Size(665, 383); ComponentsGroupBox.TabIndex = 4; ComponentsGroupBox.TabStop = false; ComponentsGroupBox.Text = "Компоненты"; // // RefreshButton // - RefreshButton.Location = new Point(481, 109); + RefreshButton.Location = new Point(550, 145); + RefreshButton.Margin = new Padding(3, 4, 3, 4); RefreshButton.Name = "RefreshButton"; - RefreshButton.Size = new Size(75, 23); + RefreshButton.Size = new Size(86, 31); RefreshButton.TabIndex = 4; RefreshButton.Text = "Обновить"; RefreshButton.UseVisualStyleBackColor = true; @@ -106,9 +111,10 @@ // // DeleteButton // - DeleteButton.Location = new Point(481, 80); + DeleteButton.Location = new Point(550, 107); + DeleteButton.Margin = new Padding(3, 4, 3, 4); DeleteButton.Name = "DeleteButton"; - DeleteButton.Size = new Size(75, 23); + DeleteButton.Size = new Size(86, 31); DeleteButton.TabIndex = 3; DeleteButton.Text = "Удалить"; DeleteButton.UseVisualStyleBackColor = true; @@ -116,9 +122,10 @@ // // UpdateButton // - UpdateButton.Location = new Point(481, 51); + UpdateButton.Location = new Point(550, 68); + UpdateButton.Margin = new Padding(3, 4, 3, 4); UpdateButton.Name = "UpdateButton"; - UpdateButton.Size = new Size(75, 23); + UpdateButton.Size = new Size(86, 31); UpdateButton.TabIndex = 2; UpdateButton.Text = "Изменить"; UpdateButton.UseVisualStyleBackColor = true; @@ -126,9 +133,10 @@ // // AddButton // - AddButton.Location = new Point(481, 22); + AddButton.Location = new Point(550, 29); + AddButton.Margin = new Padding(3, 4, 3, 4); AddButton.Name = "AddButton"; - AddButton.Size = new Size(75, 23); + AddButton.Size = new Size(86, 31); AddButton.TabIndex = 1; AddButton.Text = "Добавить"; AddButton.UseVisualStyleBackColor = true; @@ -138,10 +146,11 @@ // DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; DataGridView.Columns.AddRange(new DataGridViewColumn[] { IdColumn, ComponentNameColumn, CountColumn }); - DataGridView.Location = new Point(6, 22); + DataGridView.Location = new Point(7, 29); + DataGridView.Margin = new Padding(3, 4, 3, 4); DataGridView.Name = "DataGridView"; DataGridView.RowHeadersWidth = 51; - DataGridView.Size = new Size(442, 259); + DataGridView.Size = new Size(505, 345); DataGridView.TabIndex = 0; // // IdColumn @@ -168,9 +177,10 @@ // // SaveButton // - SaveButton.Location = new Point(424, 363); + SaveButton.Location = new Point(485, 484); + SaveButton.Margin = new Padding(3, 4, 3, 4); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(75, 23); + SaveButton.Size = new Size(86, 31); SaveButton.TabIndex = 5; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -178,18 +188,19 @@ // // CancelButton // - CancelButton.Location = new Point(505, 363); + CancelButton.Location = new Point(577, 484); + CancelButton.Margin = new Padding(3, 4, 3, 4); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(75, 23); + CancelButton.Size = new Size(86, 31); CancelButton.TabIndex = 6; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; // // IceCreamForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(606, 398); + ClientSize = new Size(693, 531); Controls.Add(CancelButton); Controls.Add(SaveButton); Controls.Add(ComponentsGroupBox); @@ -197,8 +208,9 @@ Controls.Add(NameTextBox); Controls.Add(PriceLabel); Controls.Add(NameLabel); + Margin = new Padding(3, 4, 3, 4); Name = "IceCreamForm"; - Text = "IceCreamForm"; + Text = "Форма мороженного"; Load += IceCreamForm_Load; ComponentsGroupBox.ResumeLayout(false); ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); diff --git a/IceCreamShop/IceCreamShop/IceCreamsForm.Designer.cs b/IceCreamShop/IceCreamShop/IceCreamsForm.Designer.cs index 4bb5d0d..d61e558 100644 --- a/IceCreamShop/IceCreamShop/IceCreamsForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/IceCreamsForm.Designer.cs @@ -96,7 +96,7 @@ Controls.Add(AddButton); Controls.Add(DataGridView); Name = "IceCreamsForm"; - Text = "IceCreamsForm"; + Text = "Форма мороженных"; Load += IceCreamsForm_Load; ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); ResumeLayout(false); diff --git a/IceCreamShop/IceCreamShop/MainForm.Designer.cs b/IceCreamShop/IceCreamShop/MainForm.Designer.cs index 6627a9c..c419e35 100644 --- a/IceCreamShop/IceCreamShop/MainForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/MainForm.Designer.cs @@ -33,13 +33,13 @@ КомпонентыStripMenuItem = new ToolStripMenuItem(); МороженноеStripMenuItem = new ToolStripMenuItem(); магазиныToolStripMenuItem = new ToolStripMenuItem(); + поставкиToolStripMenuItem = new ToolStripMenuItem(); DataGridView = new DataGridView(); CreateOrderButton = new Button(); TakeInWorkButton = new Button(); ReadyButton = new Button(); IssuedButton = new Button(); RefreshButton = new Button(); - поставкиToolStripMenuItem = new ToolStripMenuItem(); menuStrip1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)DataGridView).BeginInit(); SuspendLayout(); @@ -50,8 +50,8 @@ menuStrip1.Items.AddRange(new ToolStripItem[] { ToolStripMenu }); menuStrip1.Location = new Point(0, 0); menuStrip1.Name = "menuStrip1"; - menuStrip1.Padding = new Padding(5, 2, 0, 2); - menuStrip1.Size = new Size(1134, 24); + menuStrip1.Padding = new Padding(6, 3, 0, 3); + menuStrip1.Size = new Size(1296, 30); menuStrip1.TabIndex = 0; menuStrip1.Text = "menuStrip1"; // @@ -59,46 +59,51 @@ // ToolStripMenu.DropDownItems.AddRange(new ToolStripItem[] { КомпонентыStripMenuItem, МороженноеStripMenuItem, магазиныToolStripMenuItem, поставкиToolStripMenuItem }); ToolStripMenu.Name = "ToolStripMenu"; - ToolStripMenu.Size = new Size(94, 20); + ToolStripMenu.Size = new Size(117, 24); ToolStripMenu.Text = "Справочники"; // // КомпонентыStripMenuItem // КомпонентыStripMenuItem.Name = "КомпонентыStripMenuItem"; - КомпонентыStripMenuItem.Size = new Size(180, 22); + КомпонентыStripMenuItem.Size = new Size(186, 26); КомпонентыStripMenuItem.Text = "Компоненты"; КомпонентыStripMenuItem.Click += КомпонентыStripMenuItem_Click; // // МороженноеStripMenuItem // МороженноеStripMenuItem.Name = "МороженноеStripMenuItem"; - МороженноеStripMenuItem.Size = new Size(180, 22); + МороженноеStripMenuItem.Size = new Size(186, 26); МороженноеStripMenuItem.Text = "Мороженное"; МороженноеStripMenuItem.Click += МороженноеStripMenuItem_Click; // // магазиныToolStripMenuItem // магазиныToolStripMenuItem.Name = "магазиныToolStripMenuItem"; - магазиныToolStripMenuItem.Size = new Size(180, 22); + магазиныToolStripMenuItem.Size = new Size(186, 26); магазиныToolStripMenuItem.Text = "Магазины"; магазиныToolStripMenuItem.Click += магазиныToolStripMenuItem_Click; // + // поставкиToolStripMenuItem + // + поставкиToolStripMenuItem.Name = "поставкиToolStripMenuItem"; + поставкиToolStripMenuItem.Size = new Size(186, 26); + поставкиToolStripMenuItem.Text = "Поставки"; + поставкиToolStripMenuItem.Click += поставкиToolStripMenuItem_Click; + // // DataGridView // DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - DataGridView.Location = new Point(10, 23); - DataGridView.Margin = new Padding(3, 2, 3, 2); + DataGridView.Location = new Point(11, 31); DataGridView.Name = "DataGridView"; DataGridView.RowHeadersWidth = 51; - DataGridView.Size = new Size(881, 305); + DataGridView.Size = new Size(1007, 407); DataGridView.TabIndex = 1; // // CreateOrderButton // - CreateOrderButton.Location = new Point(897, 23); - CreateOrderButton.Margin = new Padding(3, 2, 3, 2); + CreateOrderButton.Location = new Point(1025, 31); CreateOrderButton.Name = "CreateOrderButton"; - CreateOrderButton.Size = new Size(227, 22); + CreateOrderButton.Size = new Size(259, 29); CreateOrderButton.TabIndex = 2; CreateOrderButton.Text = "Создать заказ"; CreateOrderButton.UseVisualStyleBackColor = true; @@ -106,10 +111,9 @@ // // TakeInWorkButton // - TakeInWorkButton.Location = new Point(897, 50); - TakeInWorkButton.Margin = new Padding(3, 2, 3, 2); + TakeInWorkButton.Location = new Point(1025, 67); TakeInWorkButton.Name = "TakeInWorkButton"; - TakeInWorkButton.Size = new Size(227, 22); + TakeInWorkButton.Size = new Size(259, 29); TakeInWorkButton.TabIndex = 3; TakeInWorkButton.Text = "Отдать заказ в работу"; TakeInWorkButton.UseVisualStyleBackColor = true; @@ -117,10 +121,9 @@ // // ReadyButton // - ReadyButton.Location = new Point(897, 76); - ReadyButton.Margin = new Padding(3, 2, 3, 2); + ReadyButton.Location = new Point(1025, 101); ReadyButton.Name = "ReadyButton"; - ReadyButton.Size = new Size(227, 22); + ReadyButton.Size = new Size(259, 29); ReadyButton.TabIndex = 4; ReadyButton.Text = "Заказ готов"; ReadyButton.UseVisualStyleBackColor = true; @@ -128,10 +131,9 @@ // // IssuedButton // - IssuedButton.Location = new Point(897, 102); - IssuedButton.Margin = new Padding(3, 2, 3, 2); + IssuedButton.Location = new Point(1025, 136); IssuedButton.Name = "IssuedButton"; - IssuedButton.Size = new Size(227, 22); + IssuedButton.Size = new Size(259, 29); IssuedButton.TabIndex = 5; IssuedButton.Text = "Заказ выдан"; IssuedButton.UseVisualStyleBackColor = true; @@ -139,27 +141,19 @@ // // RefreshButton // - RefreshButton.Location = new Point(897, 128); - RefreshButton.Margin = new Padding(3, 2, 3, 2); + RefreshButton.Location = new Point(1025, 171); RefreshButton.Name = "RefreshButton"; - RefreshButton.Size = new Size(227, 22); + RefreshButton.Size = new Size(259, 29); RefreshButton.TabIndex = 6; RefreshButton.Text = "Обновить"; RefreshButton.UseVisualStyleBackColor = true; RefreshButton.Click += RefreshButton_Click; // - // поставкиToolStripMenuItem - // - поставкиToolStripMenuItem.Name = "поставкиToolStripMenuItem"; - поставкиToolStripMenuItem.Size = new Size(180, 22); - поставкиToolStripMenuItem.Text = "Поставки"; - поставкиToolStripMenuItem.Click += поставкиToolStripMenuItem_Click; - // // MainForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(1134, 338); + ClientSize = new Size(1296, 451); Controls.Add(RefreshButton); Controls.Add(IssuedButton); Controls.Add(ReadyButton); @@ -168,9 +162,8 @@ Controls.Add(DataGridView); Controls.Add(menuStrip1); MainMenuStrip = menuStrip1; - Margin = new Padding(3, 2, 3, 2); Name = "MainForm"; - Text = "MainForm"; + Text = "Форма главная"; Load += MainForm_Load; menuStrip1.ResumeLayout(false); menuStrip1.PerformLayout(); diff --git a/IceCreamShop/IceCreamShop/ShopForm.Designer.cs b/IceCreamShop/IceCreamShop/ShopForm.Designer.cs index 964b16f..e2dec45 100644 --- a/IceCreamShop/IceCreamShop/ShopForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/ShopForm.Designer.cs @@ -46,57 +46,61 @@ // // DateTimePicker // - DateTimePicker.Location = new Point(85, 70); + DateTimePicker.Location = new Point(97, 93); + DateTimePicker.Margin = new Padding(3, 4, 3, 4); DateTimePicker.Name = "DateTimePicker"; - DateTimePicker.Size = new Size(318, 23); + DateTimePicker.Size = new Size(363, 27); DateTimePicker.TabIndex = 0; // // NameTextBox // - NameTextBox.Location = new Point(85, 12); + NameTextBox.Location = new Point(97, 16); + NameTextBox.Margin = new Padding(3, 4, 3, 4); NameTextBox.Name = "NameTextBox"; - NameTextBox.Size = new Size(318, 23); + NameTextBox.Size = new Size(363, 27); NameTextBox.TabIndex = 1; // // AddressTextBox // - AddressTextBox.Location = new Point(85, 41); + AddressTextBox.Location = new Point(97, 55); + AddressTextBox.Margin = new Padding(3, 4, 3, 4); AddressTextBox.Name = "AddressTextBox"; - AddressTextBox.Size = new Size(318, 23); + AddressTextBox.Size = new Size(363, 27); AddressTextBox.TabIndex = 2; // // NameLabel // NameLabel.AutoSize = true; - NameLabel.Location = new Point(12, 15); + NameLabel.Location = new Point(14, 20); NameLabel.Name = "NameLabel"; - NameLabel.Size = new Size(59, 15); + NameLabel.Size = new Size(77, 20); NameLabel.TabIndex = 3; NameLabel.Text = "Название"; // // AdressLabel // AdressLabel.AutoSize = true; - AdressLabel.Location = new Point(12, 44); + AdressLabel.Location = new Point(14, 59); AdressLabel.Name = "AdressLabel"; - AdressLabel.Size = new Size(40, 15); + AdressLabel.Size = new Size(51, 20); AdressLabel.TabIndex = 4; AdressLabel.Text = "Адрес"; // // DateLabel // DateLabel.AutoSize = true; - DateLabel.Location = new Point(12, 76); + DateLabel.Location = new Point(14, 101); DateLabel.Name = "DateLabel"; - DateLabel.Size = new Size(32, 15); + DateLabel.Size = new Size(41, 20); DateLabel.TabIndex = 5; DateLabel.Text = "Дата"; // // SaveButton // - SaveButton.Location = new Point(247, 255); + SaveButton.Location = new Point(282, 340); + SaveButton.Margin = new Padding(3, 4, 3, 4); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(75, 23); + SaveButton.Size = new Size(86, 31); SaveButton.TabIndex = 6; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -104,9 +108,10 @@ // // CancelButton // - CancelButton.Location = new Point(328, 255); + CancelButton.Location = new Point(375, 340); + CancelButton.Margin = new Padding(3, 4, 3, 4); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(75, 23); + CancelButton.Size = new Size(86, 31); CancelButton.TabIndex = 7; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -116,20 +121,25 @@ // DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; DataGridView.Columns.AddRange(new DataGridViewColumn[] { Column1, Название, Цена, Количество }); - DataGridView.Location = new Point(12, 99); + DataGridView.Location = new Point(14, 132); + DataGridView.Margin = new Padding(3, 4, 3, 4); DataGridView.Name = "DataGridView"; - DataGridView.Size = new Size(391, 150); + DataGridView.RowHeadersWidth = 51; + DataGridView.Size = new Size(447, 200); DataGridView.TabIndex = 8; // // Column1 // Column1.HeaderText = "Column1"; + Column1.MinimumWidth = 6; Column1.Name = "Column1"; Column1.Visible = false; + Column1.Width = 125; // // Название // Название.HeaderText = "Название"; + Название.MinimumWidth = 6; Название.Name = "Название"; Название.ReadOnly = true; Название.Width = 150; @@ -137,20 +147,24 @@ // Цена // Цена.HeaderText = "Цена"; + Цена.MinimumWidth = 6; Цена.Name = "Цена"; Цена.ReadOnly = true; + Цена.Width = 125; // // Количество // Количество.HeaderText = "Количество"; + Количество.MinimumWidth = 6; Количество.Name = "Количество"; Количество.ReadOnly = true; + Количество.Width = 125; // // ShopForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(411, 285); + ClientSize = new Size(470, 380); Controls.Add(DataGridView); Controls.Add(CancelButton); Controls.Add(SaveButton); @@ -160,8 +174,9 @@ Controls.Add(AddressTextBox); Controls.Add(NameTextBox); Controls.Add(DateTimePicker); + Margin = new Padding(3, 4, 3, 4); Name = "ShopForm"; - Text = "ShopForm"; + Text = "Форма магазина"; Load += ShopForm_Load; ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); ResumeLayout(false); diff --git a/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs b/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs index ba6dcaf..3d7f9e1 100644 --- a/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/ShopsForm.Designer.cs @@ -39,16 +39,19 @@ // DataGridView // DataGridView.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - DataGridView.Location = new Point(12, 12); + DataGridView.Location = new Point(14, 16); + DataGridView.Margin = new Padding(3, 4, 3, 4); DataGridView.Name = "DataGridView"; - DataGridView.Size = new Size(393, 374); + DataGridView.RowHeadersWidth = 51; + DataGridView.Size = new Size(449, 499); DataGridView.TabIndex = 0; // // AddButton // - AddButton.Location = new Point(411, 12); + AddButton.Location = new Point(470, 16); + AddButton.Margin = new Padding(3, 4, 3, 4); AddButton.Name = "AddButton"; - AddButton.Size = new Size(114, 23); + AddButton.Size = new Size(130, 31); AddButton.TabIndex = 1; AddButton.Text = "Добавить"; AddButton.UseVisualStyleBackColor = true; @@ -56,9 +59,10 @@ // // UpdateButton // - UpdateButton.Location = new Point(411, 41); + UpdateButton.Location = new Point(470, 55); + UpdateButton.Margin = new Padding(3, 4, 3, 4); UpdateButton.Name = "UpdateButton"; - UpdateButton.Size = new Size(114, 23); + UpdateButton.Size = new Size(130, 31); UpdateButton.TabIndex = 2; UpdateButton.Text = "Изменить"; UpdateButton.UseVisualStyleBackColor = true; @@ -66,9 +70,10 @@ // // RefreshButton // - RefreshButton.Location = new Point(411, 70); + RefreshButton.Location = new Point(470, 93); + RefreshButton.Margin = new Padding(3, 4, 3, 4); RefreshButton.Name = "RefreshButton"; - RefreshButton.Size = new Size(114, 23); + RefreshButton.Size = new Size(130, 31); RefreshButton.TabIndex = 3; RefreshButton.Text = "Обновить"; RefreshButton.UseVisualStyleBackColor = true; @@ -76,9 +81,10 @@ // // DeleteButton // - DeleteButton.Location = new Point(411, 99); + DeleteButton.Location = new Point(470, 132); + DeleteButton.Margin = new Padding(3, 4, 3, 4); DeleteButton.Name = "DeleteButton"; - DeleteButton.Size = new Size(114, 23); + DeleteButton.Size = new Size(130, 31); DeleteButton.TabIndex = 4; DeleteButton.Text = "Удалить"; DeleteButton.UseVisualStyleBackColor = true; @@ -86,16 +92,17 @@ // // ShopsForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(539, 403); + ClientSize = new Size(616, 537); Controls.Add(DeleteButton); Controls.Add(RefreshButton); Controls.Add(UpdateButton); Controls.Add(AddButton); Controls.Add(DataGridView); + Margin = new Padding(3, 4, 3, 4); Name = "ShopsForm"; - Text = "ShopsForm"; + Text = "Форма магазинов"; Load += ShopsForm_Load; ((System.ComponentModel.ISupportInitialize)DataGridView).EndInit(); ResumeLayout(false); diff --git a/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs b/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs index 665a3e0..2c16b86 100644 --- a/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/SupplyForm.Designer.cs @@ -38,31 +38,35 @@ // ShopComboBox // ShopComboBox.FormattingEnabled = true; - ShopComboBox.Location = new Point(12, 12); + ShopComboBox.Location = new Point(14, 16); + ShopComboBox.Margin = new Padding(3, 4, 3, 4); ShopComboBox.Name = "ShopComboBox"; - ShopComboBox.Size = new Size(331, 23); + ShopComboBox.Size = new Size(378, 28); ShopComboBox.TabIndex = 0; // // IceCreamComboBox // IceCreamComboBox.FormattingEnabled = true; - IceCreamComboBox.Location = new Point(12, 41); + IceCreamComboBox.Location = new Point(14, 55); + IceCreamComboBox.Margin = new Padding(3, 4, 3, 4); IceCreamComboBox.Name = "IceCreamComboBox"; - IceCreamComboBox.Size = new Size(331, 23); + IceCreamComboBox.Size = new Size(378, 28); IceCreamComboBox.TabIndex = 1; // // CountTextBox // - CountTextBox.Location = new Point(12, 70); + CountTextBox.Location = new Point(14, 93); + CountTextBox.Margin = new Padding(3, 4, 3, 4); CountTextBox.Name = "CountTextBox"; - CountTextBox.Size = new Size(331, 23); + CountTextBox.Size = new Size(378, 27); CountTextBox.TabIndex = 2; // // SaveButton // - SaveButton.Location = new Point(187, 99); + SaveButton.Location = new Point(214, 132); + SaveButton.Margin = new Padding(3, 4, 3, 4); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(75, 23); + SaveButton.Size = new Size(86, 31); SaveButton.TabIndex = 3; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -70,9 +74,10 @@ // // CancelButton // - CancelButton.Location = new Point(268, 99); + CancelButton.Location = new Point(306, 132); + CancelButton.Margin = new Padding(3, 4, 3, 4); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(75, 23); + CancelButton.Size = new Size(86, 31); CancelButton.TabIndex = 4; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -80,16 +85,17 @@ // // SupplyForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(355, 136); + ClientSize = new Size(406, 181); Controls.Add(CancelButton); Controls.Add(SaveButton); Controls.Add(CountTextBox); Controls.Add(IceCreamComboBox); Controls.Add(ShopComboBox); + Margin = new Padding(3, 4, 3, 4); Name = "SupplyForm"; - Text = "SupplyForm"; + Text = "Форма поставок"; ResumeLayout(false); PerformLayout(); } -- 2.25.1 From 2ef8238d7d5608fd7d7069e36a11e1a3bfc06182 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Tue, 20 Feb 2024 12:40:57 +0400 Subject: [PATCH 4/7] =?UTF-8?q?=D0=BC=D0=B5=D0=BB=D0=BA=D0=B8=D0=B5=20?= =?UTF-8?q?=D0=BF=D1=80=D0=B0=D0=B2=D0=BA=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IceCreamShop/IceCreamShopListImplement/Models/Order.cs | 5 ----- 1 file changed, 5 deletions(-) diff --git a/IceCreamShop/IceCreamShopListImplement/Models/Order.cs b/IceCreamShop/IceCreamShopListImplement/Models/Order.cs index 2444fac..08b4c19 100644 --- a/IceCreamShop/IceCreamShopListImplement/Models/Order.cs +++ b/IceCreamShop/IceCreamShopListImplement/Models/Order.cs @@ -46,12 +46,7 @@ namespace IceCreamShopListImplement.Models { return; } - Id = model.Id; - IceCreamId = model.IceCreamId; - Count = model.Count; - Sum = model.Sum; Status = model.Status; - DateCreate = model.DateCreate; DateImplement = model.DateImplement; } public OrderViewModel GetViewModel => new() -- 2.25.1 From fdc11812dd83da227a6856596687038b8034c505 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Tue, 20 Feb 2024 12:47:31 +0400 Subject: [PATCH 5/7] =?UTF-8?q?=D0=B5=D1=89=D0=B5=20=D0=BF=D1=80=D0=B0?= =?UTF-8?q?=D0=B2=D0=BA=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IceCreamShop/OrderForm.Designer.cs | 44 +++++++++++-------- 1 file changed, 25 insertions(+), 19 deletions(-) diff --git a/IceCreamShop/IceCreamShop/OrderForm.Designer.cs b/IceCreamShop/IceCreamShop/OrderForm.Designer.cs index 78d58c6..5149eb0 100644 --- a/IceCreamShop/IceCreamShop/OrderForm.Designer.cs +++ b/IceCreamShop/IceCreamShop/OrderForm.Designer.cs @@ -41,34 +41,38 @@ // IceCreamComboBox // IceCreamComboBox.FormattingEnabled = true; - IceCreamComboBox.Location = new Point(103, 12); + IceCreamComboBox.Location = new Point(118, 16); + IceCreamComboBox.Margin = new Padding(3, 4, 3, 4); IceCreamComboBox.Name = "IceCreamComboBox"; - IceCreamComboBox.Size = new Size(232, 23); + IceCreamComboBox.Size = new Size(265, 28); IceCreamComboBox.TabIndex = 0; IceCreamComboBox.SelectedIndexChanged += IceCreamComboBox_SelectedIndexChanged; // // CountTextBox // - CountTextBox.Location = new Point(103, 41); + CountTextBox.Location = new Point(118, 55); + CountTextBox.Margin = new Padding(3, 4, 3, 4); CountTextBox.Name = "CountTextBox"; - CountTextBox.Size = new Size(232, 23); + CountTextBox.Size = new Size(265, 27); CountTextBox.TabIndex = 1; CountTextBox.TextChanged += CountTextBox_TextChanged; // // SumTextBox // - SumTextBox.Location = new Point(103, 70); + SumTextBox.Location = new Point(118, 93); + SumTextBox.Margin = new Padding(3, 4, 3, 4); SumTextBox.Name = "SumTextBox"; SumTextBox.ReadOnly = true; - SumTextBox.Size = new Size(232, 23); + SumTextBox.Size = new Size(265, 27); SumTextBox.TabIndex = 2; SumTextBox.TextChanged += SumTextBox_TextChanged; // // SaveButton // - SaveButton.Location = new Point(173, 99); + SaveButton.Location = new Point(198, 132); + SaveButton.Margin = new Padding(3, 4, 3, 4); SaveButton.Name = "SaveButton"; - SaveButton.Size = new Size(81, 23); + SaveButton.Size = new Size(93, 31); SaveButton.TabIndex = 3; SaveButton.Text = "Сохранить"; SaveButton.UseVisualStyleBackColor = true; @@ -76,9 +80,10 @@ // // CancelButton // - CancelButton.Location = new Point(260, 99); + CancelButton.Location = new Point(297, 132); + CancelButton.Margin = new Padding(3, 4, 3, 4); CancelButton.Name = "CancelButton"; - CancelButton.Size = new Size(75, 23); + CancelButton.Size = new Size(86, 31); CancelButton.TabIndex = 4; CancelButton.Text = "Отмена"; CancelButton.UseVisualStyleBackColor = true; @@ -87,35 +92,35 @@ // IceCreamLabel // IceCreamLabel.AutoSize = true; - IceCreamLabel.Location = new Point(12, 15); + IceCreamLabel.Location = new Point(14, 20); IceCreamLabel.Name = "IceCreamLabel"; - IceCreamLabel.Size = new Size(81, 15); + IceCreamLabel.Size = new Size(103, 20); IceCreamLabel.TabIndex = 5; IceCreamLabel.Text = "Мороженное"; // // CountLabel // CountLabel.AutoSize = true; - CountLabel.Location = new Point(12, 44); + CountLabel.Location = new Point(14, 59); CountLabel.Name = "CountLabel"; - CountLabel.Size = new Size(72, 15); + CountLabel.Size = new Size(90, 20); CountLabel.TabIndex = 6; CountLabel.Text = "Количество"; // // SumLabel // SumLabel.AutoSize = true; - SumLabel.Location = new Point(12, 73); + SumLabel.Location = new Point(14, 97); SumLabel.Name = "SumLabel"; - SumLabel.Size = new Size(45, 15); + SumLabel.Size = new Size(55, 20); SumLabel.TabIndex = 7; SumLabel.Text = "Сумма"; // // OrderForm // - AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleDimensions = new SizeF(8F, 20F); AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(348, 128); + ClientSize = new Size(398, 171); Controls.Add(SumLabel); Controls.Add(CountLabel); Controls.Add(IceCreamLabel); @@ -124,8 +129,9 @@ Controls.Add(SumTextBox); Controls.Add(CountTextBox); Controls.Add(IceCreamComboBox); + Margin = new Padding(3, 4, 3, 4); Name = "OrderForm"; - Text = "OrderForm"; + Text = "Форма заказа"; Load += OrderForm_Load; ResumeLayout(false); PerformLayout(); -- 2.25.1 From 67d814b43d4a28070ce0eda940012bca1290e953 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Fri, 1 Mar 2024 22:42:15 +0400 Subject: [PATCH 6/7] =?UTF-8?q?=D0=96=D0=B8=D0=B7=D0=BD=D1=8C,=20=D0=BF?= =?UTF-8?q?=D0=BE=D1=82=D1=80=D0=B0=D1=87=D0=B5=D0=BD=D0=BD=D0=B0=D1=8F=20?= =?UTF-8?q?=D0=BD=D0=B0=20=D1=81=D0=BE=D0=B2=D0=B5=D1=80=D1=88=D0=B5=D0=BD?= =?UTF-8?q?=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BE=D0=BA,=20=D0=BD?= =?UTF-8?q?=D0=B5=20=D1=82=D0=BE=D0=BB=D1=8C=D0=BA=D0=BE=20=D0=B1=D0=BE?= =?UTF-8?q?=D0=BB=D0=B5=D0=B5=20=D0=BF=D0=BE=D1=87=D0=B5=D1=82=D0=BD=D0=B0?= =?UTF-8?q?,=20=D0=BD=D0=BE=20=D0=B8=20=D0=B1=D0=BE=D0=BB=D0=B5=D0=B5=20?= =?UTF-8?q?=D0=BF=D0=BE=D0=BB=D0=B5=D0=B7=D0=BD=D0=B0,=20=D1=87=D0=B5?= =?UTF-8?q?=D0=BC=20=D0=B6=D0=B8=D0=B7=D0=BD=D1=8C,=20=D0=BF=D1=80=D0=BE?= =?UTF-8?q?=D0=B2=D0=B5=D0=B4=D0=B5=D0=BD=D0=BD=D0=B0=D1=8F=20=D0=B2=20?= =?UTF-8?q?=D0=BD=D0=B8=D1=87=D0=B5=D0=B3=D0=BE=D0=BD=D0=B5=D0=B4=D0=B5?= =?UTF-8?q?=D0=BB=D0=B0=D0=BD=D0=B8=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BusinessLogic/ShopLogic.cs | 29 +++- .../StoragesContracts/IShopStorage.cs | 1 - .../Implements/ShopStorage.cs | 29 ---- IceCreamShop/temp/temp.sln | 25 +++ IceCreamShop/temp/temp/Form1.Designer.cs | 123 ++++++++++++++ IceCreamShop/temp/temp/Form1.cs | 25 +++ IceCreamShop/temp/temp/Form1.resx | 123 ++++++++++++++ IceCreamShop/temp/temp/Form2.Designer.cs | 112 +++++++++++++ IceCreamShop/temp/temp/Form2.cs | 25 +++ IceCreamShop/temp/temp/Form2.resx | 126 ++++++++++++++ IceCreamShop/temp/temp/Form3.Designer.cs | 104 ++++++++++++ IceCreamShop/temp/temp/Form3.cs | 20 +++ IceCreamShop/temp/temp/Form3.resx | 123 ++++++++++++++ IceCreamShop/temp/temp/Form4.Designer.cs | 110 ++++++++++++ IceCreamShop/temp/temp/Form4.cs | 20 +++ IceCreamShop/temp/temp/Form4.resx | 126 ++++++++++++++ IceCreamShop/temp/temp/Form5.Designer.cs | 157 ++++++++++++++++++ IceCreamShop/temp/temp/Form5.cs | 20 +++ IceCreamShop/temp/temp/Form5.resx | 132 +++++++++++++++ IceCreamShop/temp/temp/Form6.Designer.cs | 116 +++++++++++++ IceCreamShop/temp/temp/Form6.cs | 20 +++ IceCreamShop/temp/temp/Form6.resx | 120 +++++++++++++ IceCreamShop/temp/temp/Form7.Designer.cs | 139 ++++++++++++++++ IceCreamShop/temp/temp/Form7.cs | 20 +++ IceCreamShop/temp/temp/Form7.resx | 120 +++++++++++++ IceCreamShop/temp/temp/Form8.Designer.cs | 137 +++++++++++++++ IceCreamShop/temp/temp/Form8.cs | 20 +++ IceCreamShop/temp/temp/Form8.resx | 120 +++++++++++++ IceCreamShop/temp/temp/Program.cs | 17 ++ IceCreamShop/temp/temp/temp.csproj | 11 ++ 30 files changed, 2238 insertions(+), 32 deletions(-) create mode 100644 IceCreamShop/temp/temp.sln create mode 100644 IceCreamShop/temp/temp/Form1.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form1.cs create mode 100644 IceCreamShop/temp/temp/Form1.resx create mode 100644 IceCreamShop/temp/temp/Form2.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form2.cs create mode 100644 IceCreamShop/temp/temp/Form2.resx create mode 100644 IceCreamShop/temp/temp/Form3.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form3.cs create mode 100644 IceCreamShop/temp/temp/Form3.resx create mode 100644 IceCreamShop/temp/temp/Form4.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form4.cs create mode 100644 IceCreamShop/temp/temp/Form4.resx create mode 100644 IceCreamShop/temp/temp/Form5.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form5.cs create mode 100644 IceCreamShop/temp/temp/Form5.resx create mode 100644 IceCreamShop/temp/temp/Form6.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form6.cs create mode 100644 IceCreamShop/temp/temp/Form6.resx create mode 100644 IceCreamShop/temp/temp/Form7.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form7.cs create mode 100644 IceCreamShop/temp/temp/Form7.resx create mode 100644 IceCreamShop/temp/temp/Form8.Designer.cs create mode 100644 IceCreamShop/temp/temp/Form8.cs create mode 100644 IceCreamShop/temp/temp/Form8.resx create mode 100644 IceCreamShop/temp/temp/Program.cs create mode 100644 IceCreamShop/temp/temp/temp.csproj diff --git a/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs b/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs index fcf4dac..e5e9410 100644 --- a/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs +++ b/IceCreamShop/IceCreamShopBusinessLogic/BusinessLogic/ShopLogic.cs @@ -41,9 +41,34 @@ _shopStorage.GetFilteredList(model); public bool MakeSupply(ShopSearchModel model, IIceCreamModel iceCream, int count) { + if (model == null) - return false; - return _shopStorage.SupplyIceCream(model, iceCream, count); + throw new ArgumentNullException(nameof(model)); + if (iceCream == null) + throw new ArgumentNullException(nameof(iceCream)); + if (count <= 0) + throw new ArgumentNullException("Количество должно быть положительным числом"); + + ShopViewModel curModel = _shopStorage.GetElement(model); + if (curModel == null) + throw new ArgumentNullException(nameof(curModel)); + if (curModel.ShopIceCreams.TryGetValue(iceCream.Id, out var pair)) + { + curModel.ShopIceCreams[iceCream.Id] = (pair.Item1, pair.Item2 + count); + } + else + { + curModel.ShopIceCreams.Add(iceCream.Id, (iceCream, count)); + } + Update(new() + { + Id = curModel.Id, + ShopName = curModel.ShopName, + DateOpen = curModel.DateOpen, + Address = curModel.Address, + ShopIceCreams = curModel.ShopIceCreams, + }); + return true; } public ShopViewModel ReadElement(ShopSearchModel model) diff --git a/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs b/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs index 500cf16..1a7eb3c 100644 --- a/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs +++ b/IceCreamShop/IceCreamShopContracts/StoragesContracts/IShopStorage.cs @@ -18,6 +18,5 @@ namespace IceCreamShopContracts.StoragesContracts ShopViewModel? Insert(ShopBindingModel model); ShopViewModel? Update(ShopBindingModel model); ShopViewModel? Delete(ShopBindingModel model); - bool SupplyIceCream(ShopSearchModel model, IIceCreamModel iceCream, int Count); } } diff --git a/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs b/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs index b9a24f6..0d6e6ea 100644 --- a/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs +++ b/IceCreamShop/IceCreamShopListImplement/Implements/ShopStorage.cs @@ -106,34 +106,5 @@ namespace IceCreamShopListImplement.Implements return null; } - public bool SupplyIceCream(ShopSearchModel model, IIceCreamModel iceCream, int count) { - if (model == null) - throw new ArgumentNullException(nameof(model)); - if (iceCream == null) - throw new ArgumentNullException(nameof(iceCream)); - if (count <= 0) - throw new ArgumentNullException("Количество должно быть положительным числом"); - - ShopViewModel curModel = GetElement(model); - if(curModel == null) - throw new ArgumentNullException(nameof(curModel)); - if (curModel.ShopIceCreams.TryGetValue(iceCream.Id, out var pair)) - { - curModel.ShopIceCreams[iceCream.Id] = (pair.Item1, pair.Item2 + count); - } - else - { - curModel.ShopIceCreams.Add(iceCream.Id, (iceCream, count)); - } - Update(new() - { - Id = curModel.Id, - ShopName = curModel.ShopName, - DateOpen = curModel.DateOpen, - Address = curModel.Address, - ShopIceCreams = curModel.ShopIceCreams, - }); - return true; - } } } diff --git a/IceCreamShop/temp/temp.sln b/IceCreamShop/temp/temp.sln new file mode 100644 index 0000000..b48fb0e --- /dev/null +++ b/IceCreamShop/temp/temp.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.8.34309.116 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "temp", "temp\temp.csproj", "{8E23C6A9-181D-481E-B340-2A5B9DC97EFC}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Debug|Any CPU.Build.0 = Debug|Any CPU + {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Release|Any CPU.ActiveCfg = Release|Any CPU + {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {C349FDB8-8C35-41F7-A5DD-7396B0FAD7DE} + EndGlobalSection +EndGlobal diff --git a/IceCreamShop/temp/temp/Form1.Designer.cs b/IceCreamShop/temp/temp/Form1.Designer.cs new file mode 100644 index 0000000..f543f58 --- /dev/null +++ b/IceCreamShop/temp/temp/Form1.Designer.cs @@ -0,0 +1,123 @@ +namespace temp +{ + partial class Form1 + { + /// + /// 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() + { + menuStrip1 = new MenuStrip(); + справочникToolStripMenuItem = new ToolStripMenuItem(); + привязToolStripMenuItem = new ToolStripMenuItem(); + выгрузкаСписковToolStripMenuItem = new ToolStripMenuItem(); + отчетToolStripMenuItem = new ToolStripMenuItem(); + медикаментыToolStripMenuItem = new ToolStripMenuItem(); + услугиToolStripMenuItem = new ToolStripMenuItem(); + рекомендацииToolStripMenuItem = new ToolStripMenuItem(); + menuStrip1.SuspendLayout(); + SuspendLayout(); + // + // menuStrip1 + // + menuStrip1.Items.AddRange(new ToolStripItem[] { справочникToolStripMenuItem, привязToolStripMenuItem, выгрузкаСписковToolStripMenuItem, отчетToolStripMenuItem }); + menuStrip1.Location = new Point(0, 0); + menuStrip1.Name = "menuStrip1"; + menuStrip1.Size = new Size(800, 24); + menuStrip1.TabIndex = 0; + menuStrip1.Text = "menuStrip1"; + menuStrip1.ItemClicked += menuStrip1_ItemClicked; + // + // справочникToolStripMenuItem + // + справочникToolStripMenuItem.DropDownItems.AddRange(new ToolStripItem[] { медикаментыToolStripMenuItem, услугиToolStripMenuItem, рекомендацииToolStripMenuItem }); + справочникToolStripMenuItem.Name = "справочникToolStripMenuItem"; + справочникToolStripMenuItem.Size = new Size(85, 20); + справочникToolStripMenuItem.Text = "справочник"; + // + // привязToolStripMenuItem + // + привязToolStripMenuItem.Name = "привязToolStripMenuItem"; + привязToolStripMenuItem.Size = new Size(131, 20); + привязToolStripMenuItem.Text = "привязать животное"; + привязToolStripMenuItem.Click += привязToolStripMenuItem_Click; + // + // выгрузкаСписковToolStripMenuItem + // + выгрузкаСписковToolStripMenuItem.Name = "выгрузкаСписковToolStripMenuItem"; + выгрузкаСписковToolStripMenuItem.Size = new Size(117, 20); + выгрузкаСписковToolStripMenuItem.Text = "выгрузка списков"; + // + // отчетToolStripMenuItem + // + отчетToolStripMenuItem.Name = "отчетToolStripMenuItem"; + отчетToolStripMenuItem.Size = new Size(49, 20); + отчетToolStripMenuItem.Text = "отчет"; + // + // медикаментыToolStripMenuItem + // + медикаментыToolStripMenuItem.Name = "медикаментыToolStripMenuItem"; + медикаментыToolStripMenuItem.Size = new Size(180, 22); + медикаментыToolStripMenuItem.Text = "медикаменты"; + // + // услугиToolStripMenuItem + // + услугиToolStripMenuItem.Name = "услугиToolStripMenuItem"; + услугиToolStripMenuItem.Size = new Size(180, 22); + услугиToolStripMenuItem.Text = "услуги"; + // + // рекомендацииToolStripMenuItem + // + рекомендацииToolStripMenuItem.Name = "рекомендацииToolStripMenuItem"; + рекомендацииToolStripMenuItem.Size = new Size(180, 22); + рекомендацииToolStripMenuItem.Text = "рекомендации"; + // + // Form1 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(menuStrip1); + MainMenuStrip = menuStrip1; + Name = "Form1"; + Text = "Form1"; + Load += Form1_Load; + menuStrip1.ResumeLayout(false); + menuStrip1.PerformLayout(); + ResumeLayout(false); + PerformLayout(); + } + + #endregion + + private MenuStrip menuStrip1; + private ToolStripMenuItem справочникToolStripMenuItem; + private ToolStripMenuItem привязToolStripMenuItem; + private ToolStripMenuItem медикаментыToolStripMenuItem; + private ToolStripMenuItem услугиToolStripMenuItem; + private ToolStripMenuItem рекомендацииToolStripMenuItem; + private ToolStripMenuItem выгрузкаСписковToolStripMenuItem; + private ToolStripMenuItem отчетToolStripMenuItem; + } +} diff --git a/IceCreamShop/temp/temp/Form1.cs b/IceCreamShop/temp/temp/Form1.cs new file mode 100644 index 0000000..a244d22 --- /dev/null +++ b/IceCreamShop/temp/temp/Form1.cs @@ -0,0 +1,25 @@ +namespace temp +{ + public partial class Form1 : Form + { + public Form1() + { + InitializeComponent(); + } + + private void menuStrip1_ItemClicked(object sender, ToolStripItemClickedEventArgs e) + { + + } + + private void Form1_Load(object sender, EventArgs e) + { + + } + + private void ToolStripMenuItem_Click(object sender, EventArgs e) + { + + } + } +} diff --git a/IceCreamShop/temp/temp/Form1.resx b/IceCreamShop/temp/temp/Form1.resx new file mode 100644 index 0000000..a0623c8 --- /dev/null +++ b/IceCreamShop/temp/temp/Form1.resx @@ -0,0 +1,123 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 + + + 17, 17 + + \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form2.Designer.cs b/IceCreamShop/temp/temp/Form2.Designer.cs new file mode 100644 index 0000000..81d73ee --- /dev/null +++ b/IceCreamShop/temp/temp/Form2.Designer.cs @@ -0,0 +1,112 @@ +namespace temp +{ + partial class Form2 + { + /// + /// 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() + { + dataGridView1 = new DataGridView(); + button1 = new Button(); + изменить = new Button(); + удалить = new Button(); + название = new DataGridViewTextBoxColumn(); + Column1 = new DataGridViewTextBoxColumn(); + ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); + SuspendLayout(); + // + // dataGridView1 + // + dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; + dataGridView1.Columns.AddRange(new DataGridViewColumn[] { название, Column1 }); + dataGridView1.Location = new Point(12, 12); + dataGridView1.Name = "dataGridView1"; + dataGridView1.Size = new Size(288, 124); + dataGridView1.TabIndex = 0; + // + // button1 + // + button1.Location = new Point(306, 12); + button1.Name = "button1"; + button1.Size = new Size(75, 23); + button1.TabIndex = 1; + button1.Text = "создать"; + button1.UseVisualStyleBackColor = true; + button1.Click += button1_Click; + // + // изменить + // + изменить.Location = new Point(306, 41); + изменить.Name = "изменить"; + изменить.Size = new Size(75, 23); + изменить.TabIndex = 2; + изменить.Text = "изменить"; + изменить.UseVisualStyleBackColor = true; + // + // удалить + // + удалить.Location = new Point(306, 70); + удалить.Name = "удалить"; + удалить.Size = new Size(75, 23); + удалить.TabIndex = 3; + удалить.Text = "удалить"; + удалить.UseVisualStyleBackColor = true; + // + // название + // + название.HeaderText = "название"; + название.Name = "название"; + название.Width = 150; + // + // Column1 + // + Column1.HeaderText = "цена"; + Column1.Name = "Column1"; + // + // Form2 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(555, 450); + Controls.Add(удалить); + Controls.Add(изменить); + Controls.Add(button1); + Controls.Add(dataGridView1); + Name = "Form2"; + Text = "Form2"; + ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); + ResumeLayout(false); + } + + #endregion + + private DataGridView dataGridView1; + private Button button1; + private Button изменить; + private DataGridViewTextBoxColumn название; + private DataGridViewTextBoxColumn Column1; + private Button удалить; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form2.cs b/IceCreamShop/temp/temp/Form2.cs new file mode 100644 index 0000000..bed0096 --- /dev/null +++ b/IceCreamShop/temp/temp/Form2.cs @@ -0,0 +1,25 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form2 : Form + { + public Form2() + { + InitializeComponent(); + } + + private void button1_Click(object sender, EventArgs e) + { + + } + } +} diff --git a/IceCreamShop/temp/temp/Form2.resx b/IceCreamShop/temp/temp/Form2.resx new file mode 100644 index 0000000..63ab778 --- /dev/null +++ b/IceCreamShop/temp/temp/Form2.resx @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 + + + True + + + True + + \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form3.Designer.cs b/IceCreamShop/temp/temp/Form3.Designer.cs new file mode 100644 index 0000000..b3f0453 --- /dev/null +++ b/IceCreamShop/temp/temp/Form3.Designer.cs @@ -0,0 +1,104 @@ +namespace temp +{ + partial class Form3 + { + /// + /// 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() + { + comboBox1 = new ComboBox(); + dataGridView1 = new DataGridView(); + Column1 = new DataGridViewTextBoxColumn(); + button1 = new Button(); + отмена = new Button(); + ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); + SuspendLayout(); + // + // comboBox1 + // + comboBox1.FormattingEnabled = true; + comboBox1.Location = new Point(12, 24); + comboBox1.Name = "comboBox1"; + comboBox1.Size = new Size(240, 23); + comboBox1.TabIndex = 0; + comboBox1.Text = "медикаменты"; + // + // dataGridView1 + // + dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; + dataGridView1.Columns.AddRange(new DataGridViewColumn[] { Column1 }); + dataGridView1.Location = new Point(12, 53); + dataGridView1.Name = "dataGridView1"; + dataGridView1.Size = new Size(240, 150); + dataGridView1.TabIndex = 1; + // + // Column1 + // + Column1.HeaderText = "название животного"; + Column1.Name = "Column1"; + Column1.Width = 200; + // + // button1 + // + button1.Location = new Point(12, 209); + button1.Name = "button1"; + button1.Size = new Size(98, 23); + button1.TabIndex = 2; + button1.Text = "привязать"; + button1.UseVisualStyleBackColor = true; + // + // отмена + // + отмена.Location = new Point(154, 209); + отмена.Name = "отмена"; + отмена.Size = new Size(98, 23); + отмена.TabIndex = 3; + отмена.Text = "привязать"; + отмена.UseVisualStyleBackColor = true; + // + // Form3 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(отмена); + Controls.Add(button1); + Controls.Add(dataGridView1); + Controls.Add(comboBox1); + Name = "Form3"; + Text = "Form3"; + ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); + ResumeLayout(false); + } + + #endregion + + private ComboBox comboBox1; + private DataGridView dataGridView1; + private DataGridViewTextBoxColumn Column1; + private Button button1; + private Button отмена; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form3.cs b/IceCreamShop/temp/temp/Form3.cs new file mode 100644 index 0000000..88e10f2 --- /dev/null +++ b/IceCreamShop/temp/temp/Form3.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form3 : Form + { + public Form3() + { + InitializeComponent(); + } + } +} diff --git a/IceCreamShop/temp/temp/Form3.resx b/IceCreamShop/temp/temp/Form3.resx new file mode 100644 index 0000000..909d3b7 --- /dev/null +++ b/IceCreamShop/temp/temp/Form3.resx @@ -0,0 +1,123 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 + + + True + + \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form4.Designer.cs b/IceCreamShop/temp/temp/Form4.Designer.cs new file mode 100644 index 0000000..cea557b --- /dev/null +++ b/IceCreamShop/temp/temp/Form4.Designer.cs @@ -0,0 +1,110 @@ +namespace temp +{ + partial class Form4 + { + /// + /// 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() + { + dataGridView1 = new DataGridView(); + название = new DataGridViewTextBoxColumn(); + цена = new DataGridViewTextBoxColumn(); + button1 = new Button(); + button2 = new Button(); + button3 = new Button(); + ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); + SuspendLayout(); + // + // dataGridView1 + // + dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; + dataGridView1.Columns.AddRange(new DataGridViewColumn[] { название, цена }); + dataGridView1.Location = new Point(12, 12); + dataGridView1.Name = "dataGridView1"; + dataGridView1.Size = new Size(244, 150); + dataGridView1.TabIndex = 0; + // + // название + // + название.HeaderText = "услуга"; + название.Name = "название"; + // + // цена + // + цена.HeaderText = "цена"; + цена.Name = "цена"; + // + // button1 + // + button1.Location = new Point(262, 12); + button1.Name = "button1"; + button1.Size = new Size(75, 23); + button1.TabIndex = 1; + button1.Text = "добавить"; + button1.UseVisualStyleBackColor = true; + // + // button2 + // + button2.Location = new Point(262, 41); + button2.Name = "button2"; + button2.Size = new Size(75, 23); + button2.TabIndex = 2; + button2.Text = "изменить"; + button2.UseVisualStyleBackColor = true; + // + // button3 + // + button3.Location = new Point(262, 70); + button3.Name = "button3"; + button3.Size = new Size(75, 23); + button3.TabIndex = 3; + button3.Text = "удалить"; + button3.UseVisualStyleBackColor = true; + // + // Form4 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(button3); + Controls.Add(button2); + Controls.Add(button1); + Controls.Add(dataGridView1); + Name = "Form4"; + Text = "Form4"; + ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); + ResumeLayout(false); + } + + #endregion + + private DataGridView dataGridView1; + private DataGridViewTextBoxColumn название; + private DataGridViewTextBoxColumn цена; + private Button button1; + private Button button2; + private Button button3; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form4.cs b/IceCreamShop/temp/temp/Form4.cs new file mode 100644 index 0000000..b270e75 --- /dev/null +++ b/IceCreamShop/temp/temp/Form4.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form4 : Form + { + public Form4() + { + InitializeComponent(); + } + } +} diff --git a/IceCreamShop/temp/temp/Form4.resx b/IceCreamShop/temp/temp/Form4.resx new file mode 100644 index 0000000..9caca4b --- /dev/null +++ b/IceCreamShop/temp/temp/Form4.resx @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 + + + True + + + True + + \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form5.Designer.cs b/IceCreamShop/temp/temp/Form5.Designer.cs new file mode 100644 index 0000000..b8cd5b1 --- /dev/null +++ b/IceCreamShop/temp/temp/Form5.Designer.cs @@ -0,0 +1,157 @@ +namespace temp +{ + partial class Form5 + { + /// + /// 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() + { + textBox1 = new TextBox(); + textBox2 = new TextBox(); + label1 = new Label(); + label2 = new Label(); + dataGridView1 = new DataGridView(); + v = new DataGridViewTextBoxColumn(); + Column1 = new DataGridViewTextBoxColumn(); + button1 = new Button(); + button2 = new Button(); + button3 = new Button(); + ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); + SuspendLayout(); + // + // textBox1 + // + textBox1.Location = new Point(75, 29); + textBox1.Name = "textBox1"; + textBox1.Size = new Size(179, 23); + textBox1.TabIndex = 0; + // + // textBox2 + // + textBox2.Enabled = false; + textBox2.Location = new Point(75, 58); + textBox2.Name = "textBox2"; + textBox2.Size = new Size(82, 23); + textBox2.TabIndex = 1; + // + // label1 + // + label1.AutoSize = true; + label1.Location = new Point(12, 37); + label1.Name = "label1"; + label1.Size = new Size(57, 15); + label1.TabIndex = 2; + label1.Text = "название"; + // + // label2 + // + label2.AutoSize = true; + label2.Location = new Point(36, 61); + label2.Name = "label2"; + label2.Size = new Size(33, 15); + label2.TabIndex = 3; + label2.Text = "цена"; + // + // dataGridView1 + // + dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; + dataGridView1.Columns.AddRange(new DataGridViewColumn[] { v, Column1 }); + dataGridView1.Location = new Point(12, 87); + dataGridView1.Name = "dataGridView1"; + dataGridView1.Size = new Size(242, 150); + dataGridView1.TabIndex = 4; + // + // v + // + v.HeaderText = "медикамент"; + v.Name = "v"; + // + // Column1 + // + Column1.HeaderText = "количество"; + Column1.Name = "Column1"; + // + // button1 + // + button1.Location = new Point(260, 87); + button1.Name = "button1"; + button1.Size = new Size(75, 23); + button1.TabIndex = 5; + button1.Text = "добавить"; + button1.UseVisualStyleBackColor = true; + // + // button2 + // + button2.Location = new Point(260, 116); + button2.Name = "button2"; + button2.Size = new Size(75, 23); + button2.TabIndex = 6; + button2.Text = "изменить"; + button2.UseVisualStyleBackColor = true; + // + // button3 + // + button3.Location = new Point(260, 145); + button3.Name = "button3"; + button3.RightToLeft = RightToLeft.Yes; + button3.Size = new Size(75, 23); + button3.TabIndex = 7; + button3.Text = "удалить"; + button3.UseVisualStyleBackColor = true; + // + // Form5 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(button3); + Controls.Add(button2); + Controls.Add(button1); + Controls.Add(dataGridView1); + Controls.Add(label2); + Controls.Add(label1); + Controls.Add(textBox2); + Controls.Add(textBox1); + Name = "Form5"; + Text = "Form5"; + ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); + ResumeLayout(false); + PerformLayout(); + } + + #endregion + + private TextBox textBox1; + private TextBox textBox2; + private Label label1; + private Label label2; + private DataGridView dataGridView1; + private DataGridViewTextBoxColumn v; + private DataGridViewTextBoxColumn Column1; + private Button button1; + private Button button2; + private Button button3; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form5.cs b/IceCreamShop/temp/temp/Form5.cs new file mode 100644 index 0000000..35a60b5 --- /dev/null +++ b/IceCreamShop/temp/temp/Form5.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form5 : Form + { + public Form5() + { + InitializeComponent(); + } + } +} diff --git a/IceCreamShop/temp/temp/Form5.resx b/IceCreamShop/temp/temp/Form5.resx new file mode 100644 index 0000000..8417479 --- /dev/null +++ b/IceCreamShop/temp/temp/Form5.resx @@ -0,0 +1,132 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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 + + + True + + + True + + + True + + + True + + \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form6.Designer.cs b/IceCreamShop/temp/temp/Form6.Designer.cs new file mode 100644 index 0000000..1fd2993 --- /dev/null +++ b/IceCreamShop/temp/temp/Form6.Designer.cs @@ -0,0 +1,116 @@ +namespace temp +{ + partial class Form6 + { + /// + /// 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() + { + comboBox1 = new ComboBox(); + textBox1 = new TextBox(); + label1 = new Label(); + label2 = new Label(); + сохранить = new Button(); + button2 = new Button(); + SuspendLayout(); + // + // comboBox1 + // + comboBox1.FormattingEnabled = true; + comboBox1.Location = new Point(36, 25); + comboBox1.Name = "comboBox1"; + comboBox1.Size = new Size(184, 23); + comboBox1.TabIndex = 0; + // + // textBox1 + // + textBox1.Location = new Point(36, 69); + textBox1.Name = "textBox1"; + textBox1.Size = new Size(184, 23); + textBox1.TabIndex = 1; + // + // label1 + // + label1.AutoSize = true; + label1.Location = new Point(36, 7); + label1.Name = "label1"; + label1.Size = new Size(74, 15); + label1.TabIndex = 2; + label1.Text = "медикамент"; + // + // label2 + // + label2.AutoSize = true; + label2.Location = new Point(36, 51); + label2.Name = "label2"; + label2.Size = new Size(71, 15); + label2.TabIndex = 3; + label2.Text = "количество"; + // + // сохранить + // + сохранить.Location = new Point(36, 98); + сохранить.Name = "сохранить"; + сохранить.Size = new Size(75, 23); + сохранить.TabIndex = 4; + сохранить.Text = "сохранить"; + сохранить.UseVisualStyleBackColor = true; + // + // button2 + // + button2.Location = new Point(145, 98); + button2.Name = "button2"; + button2.Size = new Size(75, 23); + button2.TabIndex = 5; + button2.Text = "отмена"; + button2.UseVisualStyleBackColor = true; + // + // Form6 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(button2); + Controls.Add(сохранить); + Controls.Add(label2); + Controls.Add(label1); + Controls.Add(textBox1); + Controls.Add(comboBox1); + Name = "Form6"; + Text = "Form6"; + ResumeLayout(false); + PerformLayout(); + } + + #endregion + + private ComboBox comboBox1; + private TextBox textBox1; + private Label label1; + private Label label2; + private Button сохранить; + private Button button2; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form6.cs b/IceCreamShop/temp/temp/Form6.cs new file mode 100644 index 0000000..e1c25d0 --- /dev/null +++ b/IceCreamShop/temp/temp/Form6.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form6 : Form + { + public Form6() + { + InitializeComponent(); + } + } +} diff --git a/IceCreamShop/temp/temp/Form6.resx b/IceCreamShop/temp/temp/Form6.resx new file mode 100644 index 0000000..af32865 --- /dev/null +++ b/IceCreamShop/temp/temp/Form6.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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/IceCreamShop/temp/temp/Form7.Designer.cs b/IceCreamShop/temp/temp/Form7.Designer.cs new file mode 100644 index 0000000..d7dccd1 --- /dev/null +++ b/IceCreamShop/temp/temp/Form7.Designer.cs @@ -0,0 +1,139 @@ +namespace temp +{ + partial class Form7 + { + /// + /// 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() + { + comboBox1 = new ComboBox(); + comboBox2 = new ComboBox(); + услуга = new Label(); + label1 = new Label(); + label2 = new Label(); + textBox1 = new TextBox(); + button1 = new Button(); + button2 = new Button(); + SuspendLayout(); + // + // comboBox1 + // + comboBox1.FormattingEnabled = true; + comboBox1.Location = new Point(70, 32); + comboBox1.Name = "comboBox1"; + comboBox1.Size = new Size(158, 23); + comboBox1.TabIndex = 0; + // + // comboBox2 + // + comboBox2.FormattingEnabled = true; + comboBox2.Location = new Point(70, 76); + comboBox2.Name = "comboBox2"; + comboBox2.Size = new Size(158, 23); + comboBox2.TabIndex = 1; + // + // услуга + // + услуга.AutoSize = true; + услуга.Location = new Point(70, 14); + услуга.Name = "услуга"; + услуга.Size = new Size(43, 15); + услуга.TabIndex = 2; + услуга.Text = "услуга"; + // + // label1 + // + label1.AutoSize = true; + label1.Location = new Point(70, 58); + label1.Name = "label1"; + label1.Size = new Size(46, 15); + label1.TabIndex = 3; + label1.Text = "оценка"; + // + // label2 + // + label2.AutoSize = true; + label2.Location = new Point(70, 102); + label2.Name = "label2"; + label2.Size = new Size(35, 15); + label2.TabIndex = 4; + label2.Text = "текст"; + // + // textBox1 + // + textBox1.Location = new Point(70, 120); + textBox1.Name = "textBox1"; + textBox1.Size = new Size(158, 23); + textBox1.TabIndex = 5; + // + // button1 + // + button1.Location = new Point(70, 149); + button1.Name = "button1"; + button1.Size = new Size(75, 23); + button1.TabIndex = 6; + button1.Text = "сохранить"; + button1.UseVisualStyleBackColor = true; + // + // button2 + // + button2.Location = new Point(153, 149); + button2.Name = "button2"; + button2.Size = new Size(75, 23); + button2.TabIndex = 7; + button2.Text = "отмена"; + button2.UseVisualStyleBackColor = true; + // + // Form7 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(button2); + Controls.Add(button1); + Controls.Add(textBox1); + Controls.Add(label2); + Controls.Add(label1); + Controls.Add(услуга); + Controls.Add(comboBox2); + Controls.Add(comboBox1); + Name = "Form7"; + Text = "Form7"; + ResumeLayout(false); + PerformLayout(); + } + + #endregion + + private ComboBox comboBox1; + private ComboBox comboBox2; + private Label услуга; + private Label label1; + private Label label2; + private TextBox textBox1; + private Button button1; + private Button button2; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form7.cs b/IceCreamShop/temp/temp/Form7.cs new file mode 100644 index 0000000..087bf56 --- /dev/null +++ b/IceCreamShop/temp/temp/Form7.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form7 : Form + { + public Form7() + { + InitializeComponent(); + } + } +} diff --git a/IceCreamShop/temp/temp/Form7.resx b/IceCreamShop/temp/temp/Form7.resx new file mode 100644 index 0000000..af32865 --- /dev/null +++ b/IceCreamShop/temp/temp/Form7.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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/IceCreamShop/temp/temp/Form8.Designer.cs b/IceCreamShop/temp/temp/Form8.Designer.cs new file mode 100644 index 0000000..a27f3e5 --- /dev/null +++ b/IceCreamShop/temp/temp/Form8.Designer.cs @@ -0,0 +1,137 @@ +namespace temp +{ + partial class Form8 + { + /// + /// 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() + { + checkBox1 = new CheckBox(); + checkBox2 = new CheckBox(); + checkBox3 = new CheckBox(); + groupBox1 = new GroupBox(); + button1 = new Button(); + button2 = new Button(); + button3 = new Button(); + groupBox1.SuspendLayout(); + SuspendLayout(); + // + // checkBox1 + // + checkBox1.AutoSize = true; + checkBox1.Location = new Point(6, 22); + checkBox1.Name = "checkBox1"; + checkBox1.Size = new Size(71, 19); + checkBox1.TabIndex = 0; + checkBox1.Text = "услуга 1"; + checkBox1.UseVisualStyleBackColor = true; + // + // checkBox2 + // + checkBox2.AutoSize = true; + checkBox2.Location = new Point(6, 47); + checkBox2.Name = "checkBox2"; + checkBox2.Size = new Size(71, 19); + checkBox2.TabIndex = 1; + checkBox2.Text = "услуга 2"; + checkBox2.UseVisualStyleBackColor = true; + // + // checkBox3 + // + checkBox3.AutoSize = true; + checkBox3.Location = new Point(6, 72); + checkBox3.Name = "checkBox3"; + checkBox3.Size = new Size(71, 19); + checkBox3.TabIndex = 2; + checkBox3.Text = "услуга 3"; + checkBox3.UseVisualStyleBackColor = true; + // + // groupBox1 + // + groupBox1.Controls.Add(checkBox1); + groupBox1.Controls.Add(checkBox3); + groupBox1.Controls.Add(checkBox2); + groupBox1.Location = new Point(270, 106); + groupBox1.Name = "groupBox1"; + groupBox1.Size = new Size(237, 100); + groupBox1.TabIndex = 3; + groupBox1.TabStop = false; + groupBox1.Text = "услуги"; + // + // button1 + // + button1.Location = new Point(270, 212); + button1.Name = "button1"; + button1.RightToLeft = RightToLeft.No; + button1.Size = new Size(75, 23); + button1.TabIndex = 4; + button1.Text = "word"; + button1.UseVisualStyleBackColor = true; + // + // button2 + // + button2.Location = new Point(351, 212); + button2.Name = "button2"; + button2.Size = new Size(75, 23); + button2.TabIndex = 5; + button2.Text = "excel"; + button2.UseVisualStyleBackColor = true; + // + // button3 + // + button3.Location = new Point(432, 212); + button3.Name = "button3"; + button3.Size = new Size(75, 23); + button3.TabIndex = 6; + button3.Text = "отмена"; + button3.UseVisualStyleBackColor = true; + // + // Form8 + // + AutoScaleDimensions = new SizeF(7F, 15F); + AutoScaleMode = AutoScaleMode.Font; + ClientSize = new Size(800, 450); + Controls.Add(button3); + Controls.Add(button2); + Controls.Add(button1); + Controls.Add(groupBox1); + Name = "Form8"; + Text = "Form8"; + groupBox1.ResumeLayout(false); + groupBox1.PerformLayout(); + ResumeLayout(false); + } + + #endregion + + private CheckBox checkBox1; + private CheckBox checkBox2; + private CheckBox checkBox3; + private GroupBox groupBox1; + private Button button1; + private Button button2; + private Button button3; + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form8.cs b/IceCreamShop/temp/temp/Form8.cs new file mode 100644 index 0000000..fa44bd7 --- /dev/null +++ b/IceCreamShop/temp/temp/Form8.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Data; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Forms; + +namespace temp +{ + public partial class Form8 : Form + { + public Form8() + { + InitializeComponent(); + } + } +} diff --git a/IceCreamShop/temp/temp/Form8.resx b/IceCreamShop/temp/temp/Form8.resx new file mode 100644 index 0000000..af32865 --- /dev/null +++ b/IceCreamShop/temp/temp/Form8.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 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/IceCreamShop/temp/temp/Program.cs b/IceCreamShop/temp/temp/Program.cs new file mode 100644 index 0000000..9515381 --- /dev/null +++ b/IceCreamShop/temp/temp/Program.cs @@ -0,0 +1,17 @@ +namespace temp +{ + internal static class Program + { + /// + /// The main entry point for the application. + /// + [STAThread] + static void Main() + { + // To customize application configuration such as set high DPI settings or default font, + // see https://aka.ms/applicationconfiguration. + ApplicationConfiguration.Initialize(); + Application.Run(new Form1()); + } + } +} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/temp.csproj b/IceCreamShop/temp/temp/temp.csproj new file mode 100644 index 0000000..663fdb8 --- /dev/null +++ b/IceCreamShop/temp/temp/temp.csproj @@ -0,0 +1,11 @@ + + + + WinExe + net8.0-windows + enable + true + enable + + + \ No newline at end of file -- 2.25.1 From 92cbbc7280ad09e4e8d79ef12db3072edb50a9e6 Mon Sep 17 00:00:00 2001 From: gg12 darfren Date: Fri, 1 Mar 2024 22:53:12 +0400 Subject: [PATCH 7/7] =?UTF-8?q?=D0=AF=20=D0=BD=D0=B5=20=D0=B7=D0=BD=D0=B0?= =?UTF-8?q?=D1=8E=20=20=D0=BA=D0=B0=D0=BA=20=20=D1=8D=D1=82=D0=BE=20=D0=BF?= =?UTF-8?q?=D1=80=D0=BE=D0=B8=D0=B7=D0=BE=D1=88=D0=BB=D0=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IceCreamShop/temp/temp.sln | 25 ---- IceCreamShop/temp/temp/Form1.Designer.cs | 123 ------------------ IceCreamShop/temp/temp/Form1.cs | 25 ---- IceCreamShop/temp/temp/Form1.resx | 123 ------------------ IceCreamShop/temp/temp/Form2.Designer.cs | 112 ---------------- IceCreamShop/temp/temp/Form2.cs | 25 ---- IceCreamShop/temp/temp/Form2.resx | 126 ------------------ IceCreamShop/temp/temp/Form3.Designer.cs | 104 --------------- IceCreamShop/temp/temp/Form3.cs | 20 --- IceCreamShop/temp/temp/Form3.resx | 123 ------------------ IceCreamShop/temp/temp/Form4.Designer.cs | 110 ---------------- IceCreamShop/temp/temp/Form4.cs | 20 --- IceCreamShop/temp/temp/Form4.resx | 126 ------------------ IceCreamShop/temp/temp/Form5.Designer.cs | 157 ----------------------- IceCreamShop/temp/temp/Form5.cs | 20 --- IceCreamShop/temp/temp/Form5.resx | 132 ------------------- IceCreamShop/temp/temp/Form6.Designer.cs | 116 ----------------- IceCreamShop/temp/temp/Form6.cs | 20 --- IceCreamShop/temp/temp/Form6.resx | 120 ----------------- IceCreamShop/temp/temp/Form7.Designer.cs | 139 -------------------- IceCreamShop/temp/temp/Form7.cs | 20 --- IceCreamShop/temp/temp/Form7.resx | 120 ----------------- IceCreamShop/temp/temp/Form8.Designer.cs | 137 -------------------- IceCreamShop/temp/temp/Form8.cs | 20 --- IceCreamShop/temp/temp/Form8.resx | 120 ----------------- IceCreamShop/temp/temp/Program.cs | 17 --- IceCreamShop/temp/temp/temp.csproj | 11 -- 27 files changed, 2211 deletions(-) delete mode 100644 IceCreamShop/temp/temp.sln delete mode 100644 IceCreamShop/temp/temp/Form1.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form1.cs delete mode 100644 IceCreamShop/temp/temp/Form1.resx delete mode 100644 IceCreamShop/temp/temp/Form2.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form2.cs delete mode 100644 IceCreamShop/temp/temp/Form2.resx delete mode 100644 IceCreamShop/temp/temp/Form3.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form3.cs delete mode 100644 IceCreamShop/temp/temp/Form3.resx delete mode 100644 IceCreamShop/temp/temp/Form4.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form4.cs delete mode 100644 IceCreamShop/temp/temp/Form4.resx delete mode 100644 IceCreamShop/temp/temp/Form5.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form5.cs delete mode 100644 IceCreamShop/temp/temp/Form5.resx delete mode 100644 IceCreamShop/temp/temp/Form6.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form6.cs delete mode 100644 IceCreamShop/temp/temp/Form6.resx delete mode 100644 IceCreamShop/temp/temp/Form7.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form7.cs delete mode 100644 IceCreamShop/temp/temp/Form7.resx delete mode 100644 IceCreamShop/temp/temp/Form8.Designer.cs delete mode 100644 IceCreamShop/temp/temp/Form8.cs delete mode 100644 IceCreamShop/temp/temp/Form8.resx delete mode 100644 IceCreamShop/temp/temp/Program.cs delete mode 100644 IceCreamShop/temp/temp/temp.csproj diff --git a/IceCreamShop/temp/temp.sln b/IceCreamShop/temp/temp.sln deleted file mode 100644 index b48fb0e..0000000 --- a/IceCreamShop/temp/temp.sln +++ /dev/null @@ -1,25 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 17 -VisualStudioVersion = 17.8.34309.116 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "temp", "temp\temp.csproj", "{8E23C6A9-181D-481E-B340-2A5B9DC97EFC}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Debug|Any CPU.Build.0 = Debug|Any CPU - {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Release|Any CPU.ActiveCfg = Release|Any CPU - {8E23C6A9-181D-481E-B340-2A5B9DC97EFC}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {C349FDB8-8C35-41F7-A5DD-7396B0FAD7DE} - EndGlobalSection -EndGlobal diff --git a/IceCreamShop/temp/temp/Form1.Designer.cs b/IceCreamShop/temp/temp/Form1.Designer.cs deleted file mode 100644 index f543f58..0000000 --- a/IceCreamShop/temp/temp/Form1.Designer.cs +++ /dev/null @@ -1,123 +0,0 @@ -namespace temp -{ - partial class Form1 - { - /// - /// 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() - { - menuStrip1 = new MenuStrip(); - справочникToolStripMenuItem = new ToolStripMenuItem(); - привязToolStripMenuItem = new ToolStripMenuItem(); - выгрузкаСписковToolStripMenuItem = new ToolStripMenuItem(); - отчетToolStripMenuItem = new ToolStripMenuItem(); - медикаментыToolStripMenuItem = new ToolStripMenuItem(); - услугиToolStripMenuItem = new ToolStripMenuItem(); - рекомендацииToolStripMenuItem = new ToolStripMenuItem(); - menuStrip1.SuspendLayout(); - SuspendLayout(); - // - // menuStrip1 - // - menuStrip1.Items.AddRange(new ToolStripItem[] { справочникToolStripMenuItem, привязToolStripMenuItem, выгрузкаСписковToolStripMenuItem, отчетToolStripMenuItem }); - menuStrip1.Location = new Point(0, 0); - menuStrip1.Name = "menuStrip1"; - menuStrip1.Size = new Size(800, 24); - menuStrip1.TabIndex = 0; - menuStrip1.Text = "menuStrip1"; - menuStrip1.ItemClicked += menuStrip1_ItemClicked; - // - // справочникToolStripMenuItem - // - справочникToolStripMenuItem.DropDownItems.AddRange(new ToolStripItem[] { медикаментыToolStripMenuItem, услугиToolStripMenuItem, рекомендацииToolStripMenuItem }); - справочникToolStripMenuItem.Name = "справочникToolStripMenuItem"; - справочникToolStripMenuItem.Size = new Size(85, 20); - справочникToolStripMenuItem.Text = "справочник"; - // - // привязToolStripMenuItem - // - привязToolStripMenuItem.Name = "привязToolStripMenuItem"; - привязToolStripMenuItem.Size = new Size(131, 20); - привязToolStripMenuItem.Text = "привязать животное"; - привязToolStripMenuItem.Click += привязToolStripMenuItem_Click; - // - // выгрузкаСписковToolStripMenuItem - // - выгрузкаСписковToolStripMenuItem.Name = "выгрузкаСписковToolStripMenuItem"; - выгрузкаСписковToolStripMenuItem.Size = new Size(117, 20); - выгрузкаСписковToolStripMenuItem.Text = "выгрузка списков"; - // - // отчетToolStripMenuItem - // - отчетToolStripMenuItem.Name = "отчетToolStripMenuItem"; - отчетToolStripMenuItem.Size = new Size(49, 20); - отчетToolStripMenuItem.Text = "отчет"; - // - // медикаментыToolStripMenuItem - // - медикаментыToolStripMenuItem.Name = "медикаментыToolStripMenuItem"; - медикаментыToolStripMenuItem.Size = new Size(180, 22); - медикаментыToolStripMenuItem.Text = "медикаменты"; - // - // услугиToolStripMenuItem - // - услугиToolStripMenuItem.Name = "услугиToolStripMenuItem"; - услугиToolStripMenuItem.Size = new Size(180, 22); - услугиToolStripMenuItem.Text = "услуги"; - // - // рекомендацииToolStripMenuItem - // - рекомендацииToolStripMenuItem.Name = "рекомендацииToolStripMenuItem"; - рекомендацииToolStripMenuItem.Size = new Size(180, 22); - рекомендацииToolStripMenuItem.Text = "рекомендации"; - // - // Form1 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(menuStrip1); - MainMenuStrip = menuStrip1; - Name = "Form1"; - Text = "Form1"; - Load += Form1_Load; - menuStrip1.ResumeLayout(false); - menuStrip1.PerformLayout(); - ResumeLayout(false); - PerformLayout(); - } - - #endregion - - private MenuStrip menuStrip1; - private ToolStripMenuItem справочникToolStripMenuItem; - private ToolStripMenuItem привязToolStripMenuItem; - private ToolStripMenuItem медикаментыToolStripMenuItem; - private ToolStripMenuItem услугиToolStripMenuItem; - private ToolStripMenuItem рекомендацииToolStripMenuItem; - private ToolStripMenuItem выгрузкаСписковToolStripMenuItem; - private ToolStripMenuItem отчетToolStripMenuItem; - } -} diff --git a/IceCreamShop/temp/temp/Form1.cs b/IceCreamShop/temp/temp/Form1.cs deleted file mode 100644 index a244d22..0000000 --- a/IceCreamShop/temp/temp/Form1.cs +++ /dev/null @@ -1,25 +0,0 @@ -namespace temp -{ - public partial class Form1 : Form - { - public Form1() - { - InitializeComponent(); - } - - private void menuStrip1_ItemClicked(object sender, ToolStripItemClickedEventArgs e) - { - - } - - private void Form1_Load(object sender, EventArgs e) - { - - } - - private void ToolStripMenuItem_Click(object sender, EventArgs e) - { - - } - } -} diff --git a/IceCreamShop/temp/temp/Form1.resx b/IceCreamShop/temp/temp/Form1.resx deleted file mode 100644 index a0623c8..0000000 --- a/IceCreamShop/temp/temp/Form1.resx +++ /dev/null @@ -1,123 +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 - - - 17, 17 - - \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form2.Designer.cs b/IceCreamShop/temp/temp/Form2.Designer.cs deleted file mode 100644 index 81d73ee..0000000 --- a/IceCreamShop/temp/temp/Form2.Designer.cs +++ /dev/null @@ -1,112 +0,0 @@ -namespace temp -{ - partial class Form2 - { - /// - /// 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() - { - dataGridView1 = new DataGridView(); - button1 = new Button(); - изменить = new Button(); - удалить = new Button(); - название = new DataGridViewTextBoxColumn(); - Column1 = new DataGridViewTextBoxColumn(); - ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); - SuspendLayout(); - // - // dataGridView1 - // - dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - dataGridView1.Columns.AddRange(new DataGridViewColumn[] { название, Column1 }); - dataGridView1.Location = new Point(12, 12); - dataGridView1.Name = "dataGridView1"; - dataGridView1.Size = new Size(288, 124); - dataGridView1.TabIndex = 0; - // - // button1 - // - button1.Location = new Point(306, 12); - button1.Name = "button1"; - button1.Size = new Size(75, 23); - button1.TabIndex = 1; - button1.Text = "создать"; - button1.UseVisualStyleBackColor = true; - button1.Click += button1_Click; - // - // изменить - // - изменить.Location = new Point(306, 41); - изменить.Name = "изменить"; - изменить.Size = new Size(75, 23); - изменить.TabIndex = 2; - изменить.Text = "изменить"; - изменить.UseVisualStyleBackColor = true; - // - // удалить - // - удалить.Location = new Point(306, 70); - удалить.Name = "удалить"; - удалить.Size = new Size(75, 23); - удалить.TabIndex = 3; - удалить.Text = "удалить"; - удалить.UseVisualStyleBackColor = true; - // - // название - // - название.HeaderText = "название"; - название.Name = "название"; - название.Width = 150; - // - // Column1 - // - Column1.HeaderText = "цена"; - Column1.Name = "Column1"; - // - // Form2 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(555, 450); - Controls.Add(удалить); - Controls.Add(изменить); - Controls.Add(button1); - Controls.Add(dataGridView1); - Name = "Form2"; - Text = "Form2"; - ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); - ResumeLayout(false); - } - - #endregion - - private DataGridView dataGridView1; - private Button button1; - private Button изменить; - private DataGridViewTextBoxColumn название; - private DataGridViewTextBoxColumn Column1; - private Button удалить; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form2.cs b/IceCreamShop/temp/temp/Form2.cs deleted file mode 100644 index bed0096..0000000 --- a/IceCreamShop/temp/temp/Form2.cs +++ /dev/null @@ -1,25 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form2 : Form - { - public Form2() - { - InitializeComponent(); - } - - private void button1_Click(object sender, EventArgs e) - { - - } - } -} diff --git a/IceCreamShop/temp/temp/Form2.resx b/IceCreamShop/temp/temp/Form2.resx deleted file mode 100644 index 63ab778..0000000 --- a/IceCreamShop/temp/temp/Form2.resx +++ /dev/null @@ -1,126 +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 - - - True - - - True - - \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form3.Designer.cs b/IceCreamShop/temp/temp/Form3.Designer.cs deleted file mode 100644 index b3f0453..0000000 --- a/IceCreamShop/temp/temp/Form3.Designer.cs +++ /dev/null @@ -1,104 +0,0 @@ -namespace temp -{ - partial class Form3 - { - /// - /// 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() - { - comboBox1 = new ComboBox(); - dataGridView1 = new DataGridView(); - Column1 = new DataGridViewTextBoxColumn(); - button1 = new Button(); - отмена = new Button(); - ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); - SuspendLayout(); - // - // comboBox1 - // - comboBox1.FormattingEnabled = true; - comboBox1.Location = new Point(12, 24); - comboBox1.Name = "comboBox1"; - comboBox1.Size = new Size(240, 23); - comboBox1.TabIndex = 0; - comboBox1.Text = "медикаменты"; - // - // dataGridView1 - // - dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - dataGridView1.Columns.AddRange(new DataGridViewColumn[] { Column1 }); - dataGridView1.Location = new Point(12, 53); - dataGridView1.Name = "dataGridView1"; - dataGridView1.Size = new Size(240, 150); - dataGridView1.TabIndex = 1; - // - // Column1 - // - Column1.HeaderText = "название животного"; - Column1.Name = "Column1"; - Column1.Width = 200; - // - // button1 - // - button1.Location = new Point(12, 209); - button1.Name = "button1"; - button1.Size = new Size(98, 23); - button1.TabIndex = 2; - button1.Text = "привязать"; - button1.UseVisualStyleBackColor = true; - // - // отмена - // - отмена.Location = new Point(154, 209); - отмена.Name = "отмена"; - отмена.Size = new Size(98, 23); - отмена.TabIndex = 3; - отмена.Text = "привязать"; - отмена.UseVisualStyleBackColor = true; - // - // Form3 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(отмена); - Controls.Add(button1); - Controls.Add(dataGridView1); - Controls.Add(comboBox1); - Name = "Form3"; - Text = "Form3"; - ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); - ResumeLayout(false); - } - - #endregion - - private ComboBox comboBox1; - private DataGridView dataGridView1; - private DataGridViewTextBoxColumn Column1; - private Button button1; - private Button отмена; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form3.cs b/IceCreamShop/temp/temp/Form3.cs deleted file mode 100644 index 88e10f2..0000000 --- a/IceCreamShop/temp/temp/Form3.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form3 : Form - { - public Form3() - { - InitializeComponent(); - } - } -} diff --git a/IceCreamShop/temp/temp/Form3.resx b/IceCreamShop/temp/temp/Form3.resx deleted file mode 100644 index 909d3b7..0000000 --- a/IceCreamShop/temp/temp/Form3.resx +++ /dev/null @@ -1,123 +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 - - - True - - \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form4.Designer.cs b/IceCreamShop/temp/temp/Form4.Designer.cs deleted file mode 100644 index cea557b..0000000 --- a/IceCreamShop/temp/temp/Form4.Designer.cs +++ /dev/null @@ -1,110 +0,0 @@ -namespace temp -{ - partial class Form4 - { - /// - /// 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() - { - dataGridView1 = new DataGridView(); - название = new DataGridViewTextBoxColumn(); - цена = new DataGridViewTextBoxColumn(); - button1 = new Button(); - button2 = new Button(); - button3 = new Button(); - ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); - SuspendLayout(); - // - // dataGridView1 - // - dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - dataGridView1.Columns.AddRange(new DataGridViewColumn[] { название, цена }); - dataGridView1.Location = new Point(12, 12); - dataGridView1.Name = "dataGridView1"; - dataGridView1.Size = new Size(244, 150); - dataGridView1.TabIndex = 0; - // - // название - // - название.HeaderText = "услуга"; - название.Name = "название"; - // - // цена - // - цена.HeaderText = "цена"; - цена.Name = "цена"; - // - // button1 - // - button1.Location = new Point(262, 12); - button1.Name = "button1"; - button1.Size = new Size(75, 23); - button1.TabIndex = 1; - button1.Text = "добавить"; - button1.UseVisualStyleBackColor = true; - // - // button2 - // - button2.Location = new Point(262, 41); - button2.Name = "button2"; - button2.Size = new Size(75, 23); - button2.TabIndex = 2; - button2.Text = "изменить"; - button2.UseVisualStyleBackColor = true; - // - // button3 - // - button3.Location = new Point(262, 70); - button3.Name = "button3"; - button3.Size = new Size(75, 23); - button3.TabIndex = 3; - button3.Text = "удалить"; - button3.UseVisualStyleBackColor = true; - // - // Form4 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(button3); - Controls.Add(button2); - Controls.Add(button1); - Controls.Add(dataGridView1); - Name = "Form4"; - Text = "Form4"; - ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); - ResumeLayout(false); - } - - #endregion - - private DataGridView dataGridView1; - private DataGridViewTextBoxColumn название; - private DataGridViewTextBoxColumn цена; - private Button button1; - private Button button2; - private Button button3; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form4.cs b/IceCreamShop/temp/temp/Form4.cs deleted file mode 100644 index b270e75..0000000 --- a/IceCreamShop/temp/temp/Form4.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form4 : Form - { - public Form4() - { - InitializeComponent(); - } - } -} diff --git a/IceCreamShop/temp/temp/Form4.resx b/IceCreamShop/temp/temp/Form4.resx deleted file mode 100644 index 9caca4b..0000000 --- a/IceCreamShop/temp/temp/Form4.resx +++ /dev/null @@ -1,126 +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 - - - True - - - True - - \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form5.Designer.cs b/IceCreamShop/temp/temp/Form5.Designer.cs deleted file mode 100644 index b8cd5b1..0000000 --- a/IceCreamShop/temp/temp/Form5.Designer.cs +++ /dev/null @@ -1,157 +0,0 @@ -namespace temp -{ - partial class Form5 - { - /// - /// 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() - { - textBox1 = new TextBox(); - textBox2 = new TextBox(); - label1 = new Label(); - label2 = new Label(); - dataGridView1 = new DataGridView(); - v = new DataGridViewTextBoxColumn(); - Column1 = new DataGridViewTextBoxColumn(); - button1 = new Button(); - button2 = new Button(); - button3 = new Button(); - ((System.ComponentModel.ISupportInitialize)dataGridView1).BeginInit(); - SuspendLayout(); - // - // textBox1 - // - textBox1.Location = new Point(75, 29); - textBox1.Name = "textBox1"; - textBox1.Size = new Size(179, 23); - textBox1.TabIndex = 0; - // - // textBox2 - // - textBox2.Enabled = false; - textBox2.Location = new Point(75, 58); - textBox2.Name = "textBox2"; - textBox2.Size = new Size(82, 23); - textBox2.TabIndex = 1; - // - // label1 - // - label1.AutoSize = true; - label1.Location = new Point(12, 37); - label1.Name = "label1"; - label1.Size = new Size(57, 15); - label1.TabIndex = 2; - label1.Text = "название"; - // - // label2 - // - label2.AutoSize = true; - label2.Location = new Point(36, 61); - label2.Name = "label2"; - label2.Size = new Size(33, 15); - label2.TabIndex = 3; - label2.Text = "цена"; - // - // dataGridView1 - // - dataGridView1.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.AutoSize; - dataGridView1.Columns.AddRange(new DataGridViewColumn[] { v, Column1 }); - dataGridView1.Location = new Point(12, 87); - dataGridView1.Name = "dataGridView1"; - dataGridView1.Size = new Size(242, 150); - dataGridView1.TabIndex = 4; - // - // v - // - v.HeaderText = "медикамент"; - v.Name = "v"; - // - // Column1 - // - Column1.HeaderText = "количество"; - Column1.Name = "Column1"; - // - // button1 - // - button1.Location = new Point(260, 87); - button1.Name = "button1"; - button1.Size = new Size(75, 23); - button1.TabIndex = 5; - button1.Text = "добавить"; - button1.UseVisualStyleBackColor = true; - // - // button2 - // - button2.Location = new Point(260, 116); - button2.Name = "button2"; - button2.Size = new Size(75, 23); - button2.TabIndex = 6; - button2.Text = "изменить"; - button2.UseVisualStyleBackColor = true; - // - // button3 - // - button3.Location = new Point(260, 145); - button3.Name = "button3"; - button3.RightToLeft = RightToLeft.Yes; - button3.Size = new Size(75, 23); - button3.TabIndex = 7; - button3.Text = "удалить"; - button3.UseVisualStyleBackColor = true; - // - // Form5 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(button3); - Controls.Add(button2); - Controls.Add(button1); - Controls.Add(dataGridView1); - Controls.Add(label2); - Controls.Add(label1); - Controls.Add(textBox2); - Controls.Add(textBox1); - Name = "Form5"; - Text = "Form5"; - ((System.ComponentModel.ISupportInitialize)dataGridView1).EndInit(); - ResumeLayout(false); - PerformLayout(); - } - - #endregion - - private TextBox textBox1; - private TextBox textBox2; - private Label label1; - private Label label2; - private DataGridView dataGridView1; - private DataGridViewTextBoxColumn v; - private DataGridViewTextBoxColumn Column1; - private Button button1; - private Button button2; - private Button button3; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form5.cs b/IceCreamShop/temp/temp/Form5.cs deleted file mode 100644 index 35a60b5..0000000 --- a/IceCreamShop/temp/temp/Form5.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form5 : Form - { - public Form5() - { - InitializeComponent(); - } - } -} diff --git a/IceCreamShop/temp/temp/Form5.resx b/IceCreamShop/temp/temp/Form5.resx deleted file mode 100644 index 8417479..0000000 --- a/IceCreamShop/temp/temp/Form5.resx +++ /dev/null @@ -1,132 +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 - - - True - - - True - - - True - - - True - - \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form6.Designer.cs b/IceCreamShop/temp/temp/Form6.Designer.cs deleted file mode 100644 index 1fd2993..0000000 --- a/IceCreamShop/temp/temp/Form6.Designer.cs +++ /dev/null @@ -1,116 +0,0 @@ -namespace temp -{ - partial class Form6 - { - /// - /// 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() - { - comboBox1 = new ComboBox(); - textBox1 = new TextBox(); - label1 = new Label(); - label2 = new Label(); - сохранить = new Button(); - button2 = new Button(); - SuspendLayout(); - // - // comboBox1 - // - comboBox1.FormattingEnabled = true; - comboBox1.Location = new Point(36, 25); - comboBox1.Name = "comboBox1"; - comboBox1.Size = new Size(184, 23); - comboBox1.TabIndex = 0; - // - // textBox1 - // - textBox1.Location = new Point(36, 69); - textBox1.Name = "textBox1"; - textBox1.Size = new Size(184, 23); - textBox1.TabIndex = 1; - // - // label1 - // - label1.AutoSize = true; - label1.Location = new Point(36, 7); - label1.Name = "label1"; - label1.Size = new Size(74, 15); - label1.TabIndex = 2; - label1.Text = "медикамент"; - // - // label2 - // - label2.AutoSize = true; - label2.Location = new Point(36, 51); - label2.Name = "label2"; - label2.Size = new Size(71, 15); - label2.TabIndex = 3; - label2.Text = "количество"; - // - // сохранить - // - сохранить.Location = new Point(36, 98); - сохранить.Name = "сохранить"; - сохранить.Size = new Size(75, 23); - сохранить.TabIndex = 4; - сохранить.Text = "сохранить"; - сохранить.UseVisualStyleBackColor = true; - // - // button2 - // - button2.Location = new Point(145, 98); - button2.Name = "button2"; - button2.Size = new Size(75, 23); - button2.TabIndex = 5; - button2.Text = "отмена"; - button2.UseVisualStyleBackColor = true; - // - // Form6 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(button2); - Controls.Add(сохранить); - Controls.Add(label2); - Controls.Add(label1); - Controls.Add(textBox1); - Controls.Add(comboBox1); - Name = "Form6"; - Text = "Form6"; - ResumeLayout(false); - PerformLayout(); - } - - #endregion - - private ComboBox comboBox1; - private TextBox textBox1; - private Label label1; - private Label label2; - private Button сохранить; - private Button button2; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form6.cs b/IceCreamShop/temp/temp/Form6.cs deleted file mode 100644 index e1c25d0..0000000 --- a/IceCreamShop/temp/temp/Form6.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form6 : Form - { - public Form6() - { - InitializeComponent(); - } - } -} diff --git a/IceCreamShop/temp/temp/Form6.resx b/IceCreamShop/temp/temp/Form6.resx deleted file mode 100644 index af32865..0000000 --- a/IceCreamShop/temp/temp/Form6.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/IceCreamShop/temp/temp/Form7.Designer.cs b/IceCreamShop/temp/temp/Form7.Designer.cs deleted file mode 100644 index d7dccd1..0000000 --- a/IceCreamShop/temp/temp/Form7.Designer.cs +++ /dev/null @@ -1,139 +0,0 @@ -namespace temp -{ - partial class Form7 - { - /// - /// 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() - { - comboBox1 = new ComboBox(); - comboBox2 = new ComboBox(); - услуга = new Label(); - label1 = new Label(); - label2 = new Label(); - textBox1 = new TextBox(); - button1 = new Button(); - button2 = new Button(); - SuspendLayout(); - // - // comboBox1 - // - comboBox1.FormattingEnabled = true; - comboBox1.Location = new Point(70, 32); - comboBox1.Name = "comboBox1"; - comboBox1.Size = new Size(158, 23); - comboBox1.TabIndex = 0; - // - // comboBox2 - // - comboBox2.FormattingEnabled = true; - comboBox2.Location = new Point(70, 76); - comboBox2.Name = "comboBox2"; - comboBox2.Size = new Size(158, 23); - comboBox2.TabIndex = 1; - // - // услуга - // - услуга.AutoSize = true; - услуга.Location = new Point(70, 14); - услуга.Name = "услуга"; - услуга.Size = new Size(43, 15); - услуга.TabIndex = 2; - услуга.Text = "услуга"; - // - // label1 - // - label1.AutoSize = true; - label1.Location = new Point(70, 58); - label1.Name = "label1"; - label1.Size = new Size(46, 15); - label1.TabIndex = 3; - label1.Text = "оценка"; - // - // label2 - // - label2.AutoSize = true; - label2.Location = new Point(70, 102); - label2.Name = "label2"; - label2.Size = new Size(35, 15); - label2.TabIndex = 4; - label2.Text = "текст"; - // - // textBox1 - // - textBox1.Location = new Point(70, 120); - textBox1.Name = "textBox1"; - textBox1.Size = new Size(158, 23); - textBox1.TabIndex = 5; - // - // button1 - // - button1.Location = new Point(70, 149); - button1.Name = "button1"; - button1.Size = new Size(75, 23); - button1.TabIndex = 6; - button1.Text = "сохранить"; - button1.UseVisualStyleBackColor = true; - // - // button2 - // - button2.Location = new Point(153, 149); - button2.Name = "button2"; - button2.Size = new Size(75, 23); - button2.TabIndex = 7; - button2.Text = "отмена"; - button2.UseVisualStyleBackColor = true; - // - // Form7 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(button2); - Controls.Add(button1); - Controls.Add(textBox1); - Controls.Add(label2); - Controls.Add(label1); - Controls.Add(услуга); - Controls.Add(comboBox2); - Controls.Add(comboBox1); - Name = "Form7"; - Text = "Form7"; - ResumeLayout(false); - PerformLayout(); - } - - #endregion - - private ComboBox comboBox1; - private ComboBox comboBox2; - private Label услуга; - private Label label1; - private Label label2; - private TextBox textBox1; - private Button button1; - private Button button2; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form7.cs b/IceCreamShop/temp/temp/Form7.cs deleted file mode 100644 index 087bf56..0000000 --- a/IceCreamShop/temp/temp/Form7.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form7 : Form - { - public Form7() - { - InitializeComponent(); - } - } -} diff --git a/IceCreamShop/temp/temp/Form7.resx b/IceCreamShop/temp/temp/Form7.resx deleted file mode 100644 index af32865..0000000 --- a/IceCreamShop/temp/temp/Form7.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/IceCreamShop/temp/temp/Form8.Designer.cs b/IceCreamShop/temp/temp/Form8.Designer.cs deleted file mode 100644 index a27f3e5..0000000 --- a/IceCreamShop/temp/temp/Form8.Designer.cs +++ /dev/null @@ -1,137 +0,0 @@ -namespace temp -{ - partial class Form8 - { - /// - /// 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() - { - checkBox1 = new CheckBox(); - checkBox2 = new CheckBox(); - checkBox3 = new CheckBox(); - groupBox1 = new GroupBox(); - button1 = new Button(); - button2 = new Button(); - button3 = new Button(); - groupBox1.SuspendLayout(); - SuspendLayout(); - // - // checkBox1 - // - checkBox1.AutoSize = true; - checkBox1.Location = new Point(6, 22); - checkBox1.Name = "checkBox1"; - checkBox1.Size = new Size(71, 19); - checkBox1.TabIndex = 0; - checkBox1.Text = "услуга 1"; - checkBox1.UseVisualStyleBackColor = true; - // - // checkBox2 - // - checkBox2.AutoSize = true; - checkBox2.Location = new Point(6, 47); - checkBox2.Name = "checkBox2"; - checkBox2.Size = new Size(71, 19); - checkBox2.TabIndex = 1; - checkBox2.Text = "услуга 2"; - checkBox2.UseVisualStyleBackColor = true; - // - // checkBox3 - // - checkBox3.AutoSize = true; - checkBox3.Location = new Point(6, 72); - checkBox3.Name = "checkBox3"; - checkBox3.Size = new Size(71, 19); - checkBox3.TabIndex = 2; - checkBox3.Text = "услуга 3"; - checkBox3.UseVisualStyleBackColor = true; - // - // groupBox1 - // - groupBox1.Controls.Add(checkBox1); - groupBox1.Controls.Add(checkBox3); - groupBox1.Controls.Add(checkBox2); - groupBox1.Location = new Point(270, 106); - groupBox1.Name = "groupBox1"; - groupBox1.Size = new Size(237, 100); - groupBox1.TabIndex = 3; - groupBox1.TabStop = false; - groupBox1.Text = "услуги"; - // - // button1 - // - button1.Location = new Point(270, 212); - button1.Name = "button1"; - button1.RightToLeft = RightToLeft.No; - button1.Size = new Size(75, 23); - button1.TabIndex = 4; - button1.Text = "word"; - button1.UseVisualStyleBackColor = true; - // - // button2 - // - button2.Location = new Point(351, 212); - button2.Name = "button2"; - button2.Size = new Size(75, 23); - button2.TabIndex = 5; - button2.Text = "excel"; - button2.UseVisualStyleBackColor = true; - // - // button3 - // - button3.Location = new Point(432, 212); - button3.Name = "button3"; - button3.Size = new Size(75, 23); - button3.TabIndex = 6; - button3.Text = "отмена"; - button3.UseVisualStyleBackColor = true; - // - // Form8 - // - AutoScaleDimensions = new SizeF(7F, 15F); - AutoScaleMode = AutoScaleMode.Font; - ClientSize = new Size(800, 450); - Controls.Add(button3); - Controls.Add(button2); - Controls.Add(button1); - Controls.Add(groupBox1); - Name = "Form8"; - Text = "Form8"; - groupBox1.ResumeLayout(false); - groupBox1.PerformLayout(); - ResumeLayout(false); - } - - #endregion - - private CheckBox checkBox1; - private CheckBox checkBox2; - private CheckBox checkBox3; - private GroupBox groupBox1; - private Button button1; - private Button button2; - private Button button3; - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/Form8.cs b/IceCreamShop/temp/temp/Form8.cs deleted file mode 100644 index fa44bd7..0000000 --- a/IceCreamShop/temp/temp/Form8.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace temp -{ - public partial class Form8 : Form - { - public Form8() - { - InitializeComponent(); - } - } -} diff --git a/IceCreamShop/temp/temp/Form8.resx b/IceCreamShop/temp/temp/Form8.resx deleted file mode 100644 index af32865..0000000 --- a/IceCreamShop/temp/temp/Form8.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/IceCreamShop/temp/temp/Program.cs b/IceCreamShop/temp/temp/Program.cs deleted file mode 100644 index 9515381..0000000 --- a/IceCreamShop/temp/temp/Program.cs +++ /dev/null @@ -1,17 +0,0 @@ -namespace temp -{ - internal static class Program - { - /// - /// The main entry point for the application. - /// - [STAThread] - static void Main() - { - // To customize application configuration such as set high DPI settings or default font, - // see https://aka.ms/applicationconfiguration. - ApplicationConfiguration.Initialize(); - Application.Run(new Form1()); - } - } -} \ No newline at end of file diff --git a/IceCreamShop/temp/temp/temp.csproj b/IceCreamShop/temp/temp/temp.csproj deleted file mode 100644 index 663fdb8..0000000 --- a/IceCreamShop/temp/temp/temp.csproj +++ /dev/null @@ -1,11 +0,0 @@ - - - - WinExe - net8.0-windows - enable - true - enable - - - \ No newline at end of file -- 2.25.1