From 12dd661a805c04ade167e4db4d79916c18d60fed Mon Sep 17 00:00:00 2001 From: malimova Date: Fri, 26 Apr 2024 00:24:30 +0400 Subject: [PATCH] =?UTF-8?q?=D0=B2=D1=80=D0=BE=D0=B4=D0=B5=20=D0=B4=D0=BE?= =?UTF-8?q?=D0=B4=D0=B5=D0=BB=D0=B0=D0=BB=D0=B0=20=D0=B4=D0=BE=20=D0=BA?= =?UTF-8?q?=D0=BE=D0=BD=D1=86=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ConfectioneryBusinessLogic.csproj | 2 +- .../ConfectioneryBusinessLogic/SaveToPdf.cs | 2 + .../ConfectioneryView/FormMain.Designer.cs | 17 +++-- Confectionery/ConfectioneryView/FormMain.cs | 2 +- Confectionery/ConfectioneryView/FormMain.resx | 62 ++++++++++++++++++- 5 files changed, 73 insertions(+), 12 deletions(-) diff --git a/Confectionery/ConfectioneryBusinessLogic/ConfectioneryBusinessLogic.csproj b/Confectionery/ConfectioneryBusinessLogic/ConfectioneryBusinessLogic.csproj index 7cfc245..06e699f 100644 --- a/Confectionery/ConfectioneryBusinessLogic/ConfectioneryBusinessLogic.csproj +++ b/Confectionery/ConfectioneryBusinessLogic/ConfectioneryBusinessLogic.csproj @@ -12,8 +12,8 @@ - + diff --git a/Confectionery/ConfectioneryBusinessLogic/SaveToPdf.cs b/Confectionery/ConfectioneryBusinessLogic/SaveToPdf.cs index bad48d4..993956b 100644 --- a/Confectionery/ConfectioneryBusinessLogic/SaveToPdf.cs +++ b/Confectionery/ConfectioneryBusinessLogic/SaveToPdf.cs @@ -3,6 +3,7 @@ using MigraDoc.DocumentObjectModel.Tables; using MigraDoc.Rendering; using ConfectioneryBusinessLogic.OfficePackage.HelperEnums; using ConfectioneryBusinessLogic.OfficePackage.HelperModels; +using MigraDoc.DocumentObjectModel.Visitors; namespace ConfectioneryBusinessLogic @@ -32,6 +33,7 @@ namespace ConfectioneryBusinessLogic var style = document.Styles["Normal"]; style.Font.Name = "Times New Roman"; style.Font.Size = 14; + style = document.Styles.AddStyle("NormalTitle", "Normal"); style.Font.Bold = true; } diff --git a/Confectionery/ConfectioneryView/FormMain.Designer.cs b/Confectionery/ConfectioneryView/FormMain.Designer.cs index fdff896..9d730d6 100644 --- a/Confectionery/ConfectioneryView/FormMain.Designer.cs +++ b/Confectionery/ConfectioneryView/FormMain.Designer.cs @@ -34,7 +34,7 @@ componentsToolStripMenuItem = new ToolStripMenuItem(); pastryToolStripMenuItem = new ToolStripMenuItem(); отчетыToolStripMenuItem = new ToolStripMenuItem(); - componentsListToolStripMenuItem = new ToolStripMenuItem(); + pastrysListToolStripMenuItem = new ToolStripMenuItem(); componentPastryToolStripMenuItem = new ToolStripMenuItem(); ordersListToolStripMenuItem = new ToolStripMenuItem(); buttonCreateOrder = new Button(); @@ -53,7 +53,6 @@ dataGridView.Location = new Point(12, 60); dataGridView.Name = "dataGridView"; dataGridView.RowHeadersWidth = 62; - dataGridView.RowTemplate.Height = 33; dataGridView.Size = new Size(1068, 549); dataGridView.TabIndex = 0; // @@ -90,17 +89,17 @@ // // отчетыToolStripMenuItem // - отчетыToolStripMenuItem.DropDownItems.AddRange(new ToolStripItem[] { componentsListToolStripMenuItem, componentPastryToolStripMenuItem, ordersListToolStripMenuItem }); + отчетыToolStripMenuItem.DropDownItems.AddRange(new ToolStripItem[] { pastrysListToolStripMenuItem, componentPastryToolStripMenuItem, ordersListToolStripMenuItem }); отчетыToolStripMenuItem.Name = "отчетыToolStripMenuItem"; отчетыToolStripMenuItem.Size = new Size(88, 29); отчетыToolStripMenuItem.Text = "Отчеты"; // - // componentsListToolStripMenuItem + // pastrysListToolStripMenuItem // - componentsListToolStripMenuItem.Name = "componentsListToolStripMenuItem"; - componentsListToolStripMenuItem.Size = new Size(327, 34); - componentsListToolStripMenuItem.Text = "Список компонентов"; - componentsListToolStripMenuItem.Click += componentsListToolStripMenuItem_Click; + pastrysListToolStripMenuItem.Name = "pastrysListToolStripMenuItem"; + pastrysListToolStripMenuItem.Size = new Size(327, 34); + pastrysListToolStripMenuItem.Text = "Список изделий"; + pastrysListToolStripMenuItem.Click += pastrysListToolStripMenuItem_Click; // // componentPastryToolStripMenuItem // @@ -207,7 +206,7 @@ private ToolStripMenuItem componentsToolStripMenuItem; private ToolStripMenuItem pastryToolStripMenuItem; private ToolStripMenuItem отчетыToolStripMenuItem; - private ToolStripMenuItem componentsListToolStripMenuItem; + private ToolStripMenuItem pastrysListToolStripMenuItem; private ToolStripMenuItem componentPastryToolStripMenuItem; private ToolStripMenuItem ordersListToolStripMenuItem; } diff --git a/Confectionery/ConfectioneryView/FormMain.cs b/Confectionery/ConfectioneryView/FormMain.cs index 8e93937..af36c90 100644 --- a/Confectionery/ConfectioneryView/FormMain.cs +++ b/Confectionery/ConfectioneryView/FormMain.cs @@ -180,7 +180,7 @@ namespace ConfectioneryView } } - private void componentsListToolStripMenuItem_Click(object sender, EventArgs e) + private void pastrysListToolStripMenuItem_Click(object sender, EventArgs e) { using var dialog = new SaveFileDialog { Filter = "docx|*.docx" }; if (dialog.ShowDialog() == DialogResult.OK) diff --git a/Confectionery/ConfectioneryView/FormMain.resx b/Confectionery/ConfectioneryView/FormMain.resx index 81a9e3d..6c82d08 100644 --- a/Confectionery/ConfectioneryView/FormMain.resx +++ b/Confectionery/ConfectioneryView/FormMain.resx @@ -1,4 +1,64 @@ - + + +