Список изделий

This commit is contained in:
Андрей Байгулов 2024-04-25 22:52:43 +04:00
parent c4a17d6300
commit 5a2f7da8a8
6 changed files with 9 additions and 10 deletions

View File

@ -17,11 +17,11 @@ namespace SushiBarBusinessLogic.OfficePackage
JustificationType = WordJustificationType.Center
}
});
foreach (var component in info.Components)
foreach (var sushi in info.Sushi)
{
CreateParagraph(new WordParagraph
{
Texts = new List<(string, WordTextProperties)> { (component.ComponentName, new WordTextProperties { Size = "24", }) },
Texts = new List<(string, WordTextProperties)> { (sushi.SushiName, new WordTextProperties { Size = "24", }) },
TextProperties = new WordTextProperties
{
Size = "24",

View File

@ -87,8 +87,8 @@ namespace SushiBarBusinessLogic.BusinessLogics
_saveToWord.CreateDoc(new WordInfo
{
FileName = model.FileName,
Title = "Список компонент",
Components = _componentStorage.GetFullList()
Title = "Список изделий",
Sushi = _SushiStorage.GetFullList()
});
}
/// <summary>
@ -100,7 +100,7 @@ namespace SushiBarBusinessLogic.BusinessLogics
_saveToExcel.CreateReport(new ExcelInfo
{
FileName = model.FileName,
Title = "Список компонент",
Title = "Список компонентов",
SushiComponents = GetSushiComponent()
});
}

View File

@ -27,7 +27,7 @@ namespace SushiBarBusinessLogic.OfficePackage.Implements
private static void DefineStyles(Document document)
{
var style = document.Styles["Normal"];
style.Font.Name = "Arial";
style.Font.Name = "Times New Roman";
style.Font.Size = 14;
style = document.Styles.AddStyle("NormalTitle", "Normal");
style.Font.Bold = true;

View File

@ -64,8 +64,7 @@ namespace SushiBarBusinessLogic.OfficePackage.Implements
{
paragraphMarkRunProperties.AppendChild(new FontSize
{
Val =
paragraphProperties.Size
Val = paragraphProperties.Size
});
}
properties.AppendChild(paragraphMarkRunProperties);

View File

@ -6,6 +6,6 @@ namespace SushiBarBusinessLogic.OfficePackage.HelperModels
{
public string FileName { get; set; } = string.Empty;
public string Title { get; set; } = string.Empty;
public List<ComponentViewModel> Components { get; set; } = new();
public List<SushiViewModel> Sushi { get; set; } = new();
}
}

View File

@ -146,7 +146,7 @@
//
ComponentsListToolStripMenuItem.Name = "ComponentsListToolStripMenuItem";
ComponentsListToolStripMenuItem.Size = new Size(218, 22);
ComponentsListToolStripMenuItem.Text = "Список компонентов";
ComponentsListToolStripMenuItem.Text = "Список изделий";
ComponentsListToolStripMenuItem.Click += ComponentsListToolStripMenuItem_Click;
//
// ComponentSushisToolStripMenuItem