Работают отчеты в ворд и эксель
This commit is contained in:
parent
f15d160157
commit
6913a6c543
@ -31,6 +31,21 @@ namespace PolyclinicBusinessLogic.OfficePackage.AbstractImplementerReports
|
||||
Text = diagnoseMedicaments.Diagnose.Name,
|
||||
StyleInfo = ExcelStyleInfoType.Text
|
||||
});
|
||||
if (diagnoseMedicaments.Medicaments.Count() > 0)
|
||||
{
|
||||
rowIndex++;
|
||||
}
|
||||
foreach (var medicament in diagnoseMedicaments.Medicaments)
|
||||
{
|
||||
InsertCellInWorksheet(new ExcelCellParameters
|
||||
{
|
||||
ColumnName = "B",
|
||||
RowIndex = rowIndex,
|
||||
Text = medicament.Name,
|
||||
StyleInfo = ExcelStyleInfoType.Text
|
||||
});
|
||||
rowIndex++;
|
||||
}
|
||||
rowIndex++;
|
||||
}
|
||||
SaveExcel(info);
|
||||
|
@ -36,6 +36,22 @@ namespace PolyclinicBusinessLogic.OfficePackage.AbstractImplementerReports
|
||||
JustificationType = WordJustificationType.Both
|
||||
}
|
||||
});
|
||||
foreach (var med in diagnoseMedicaments.Medicaments)
|
||||
{
|
||||
CreateParagraph(new WordParagraph
|
||||
{
|
||||
Texts = new List<(string, WordTextProperties)>
|
||||
{
|
||||
(med.Name, new WordTextProperties{ Size = "24"}),
|
||||
},
|
||||
|
||||
TextProperties = new WordTextProperties
|
||||
{
|
||||
Size = "24",
|
||||
JustificationType = WordJustificationType.Center
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
SaveWord(info);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user