diff --git a/server/AyaNova/biz/ReportBiz.cs b/server/AyaNova/biz/ReportBiz.cs index d7dd7aa5..633b5743 100644 --- a/server/AyaNova/biz/ReportBiz.cs +++ b/server/AyaNova/biz/ReportBiz.cs @@ -572,6 +572,27 @@ namespace AyaNova.Biz } } + PdfOptions.Landscape = report.Landscape; + if (!string.IsNullOrWhiteSpace(report.MarginOptionsBottom)) + PdfOptions.MarginOptions.Bottom = report.MarginOptionsBottom; + + if (!string.IsNullOrWhiteSpace(report.MarginOptionsLeft)) + PdfOptions.MarginOptions.Left = report.MarginOptionsLeft; + + if (!string.IsNullOrWhiteSpace(report.MarginOptionsRight)) + PdfOptions.MarginOptions.Right = report.MarginOptionsRight; + + if (!string.IsNullOrWhiteSpace(report.MarginOptionsTop)) + PdfOptions.MarginOptions.Top = report.MarginOptionsTop; + + //holding this back until figure it out + //it's not really a report property, but a print time / render property + //PdfOptions.PageRanges=report.PageRanges; + + PdfOptions.PreferCSSPageSize=report.PreferCSSPageSize; + PdfOptions.PrintBackground=report.PrintBackground; + PdfOptions.Scale=report.Scale; + //render to pdf and return log.LogDebug($"Calling render page contents to PDF"); await page.PdfAsync(outputFullPath, PdfOptions);