From 66fec616b7cc6e1ddab851b6d9d140fa1bf9c49f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=BA=20=D0=98=D0=B3=D0=BE=D1=80=D1=8C?= Date: Sun, 26 Mar 2023 19:34:29 +0400 Subject: [PATCH] =?UTF-8?q?=D0=B4=D0=BE=D0=B4=D0=B5=D0=BB=D0=BA=D0=B0=20?= =?UTF-8?q?=D0=BF=D0=BE=20=D0=B2=D0=BE=D1=80=D0=B4=D1=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../BusinessLogics/ReportLogic.cs | 4 ++-- .../OfficePackage/AbstractSaveToWord.cs | 6 ++++-- .../OfficePackage/HelperModels/WordInfo.cs | 2 +- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/BusinessLogics/ReportLogic.cs b/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/BusinessLogics/ReportLogic.cs index ba87c78..5d78b87 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/BusinessLogics/ReportLogic.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/BusinessLogics/ReportLogic.cs @@ -88,8 +88,8 @@ namespace BlacksmithWorkShopBusinessLogic.BusinessLogics _saveToWord.CreateDoc(new WordInfo { FileName = model.FileName, - Title = "Список компонент", - Components = _componentStorage.GetFullList() + Title = "Список изделий", + Manufactures = _manufactureStorage.GetFullList() }); } /// diff --git a/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/AbstractSaveToWord.cs b/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/AbstractSaveToWord.cs index f0b516f..1e4e6eb 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/AbstractSaveToWord.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/AbstractSaveToWord.cs @@ -20,13 +20,15 @@ namespace BlacksmithWorkshopBusinessLogic.OfficePackage JustificationType = WordJustificationType.Center } }); - foreach (var component in info.Components) + foreach (var manufacture in info.Manufactures) { CreateParagraph(new WordParagraph { Texts = new List<(string, WordTextProperties)> { - (component.ComponentName, new WordTextProperties { Size = "24", }) + (manufacture.ManufactureName, new WordTextProperties { Bold = true, Size = "24", }), + (" ", new WordTextProperties { Size = "24"}), + (manufacture.Price.ToString(), new WordTextProperties { Size = "24" }) }, TextProperties = new WordTextProperties { diff --git a/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/HelperModels/WordInfo.cs b/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/HelperModels/WordInfo.cs index b44871f..4eee400 100644 --- a/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/HelperModels/WordInfo.cs +++ b/BlacksmithWorkshop/BlacksmithWorkshopBusinessLogic/OfficePackage/HelperModels/WordInfo.cs @@ -6,6 +6,6 @@ namespace BlacksmithWorkshopBusinessLogic.OfficePackage.HelperModels { public string FileName { get; set; } = string.Empty; public string Title { get; set; } = string.Empty; - public List Components { get; set; } = new(); + public List Manufactures { get; set; } = new(); } }