This commit is contained in:
@@ -290,4 +290,8 @@ vbeta 8.0-b0.7 2021-12-28
|
||||
Basic - Premium AMD Shared CPU 1 vCPU 1 GB 25 GB 1 TB $6/mo
|
||||
300, 1m 3s, 475 pages (FUCKING WORKS!!!!)
|
||||
1000, 3m 33s 1610 pages (FUCK YEAH!)
|
||||
1800 timed out at 15 min but no crash
|
||||
1800 timed out at 15 min but no crash
|
||||
|
||||
Testing windev beta 0.8 after fixing double render due to style issue
|
||||
1000 debug run 4m 41s 1556 pages
|
||||
1000 release run 3m 26s 1556 pages
|
||||
@@ -623,11 +623,7 @@ namespace AyaNova.Biz
|
||||
if (!string.IsNullOrWhiteSpace(report.JsHelpers))
|
||||
await page.AddScriptTagAsync(new AddTagOptions() { Content = report.JsHelpers });
|
||||
|
||||
// if (!string.IsNullOrWhiteSpace(report.Style))
|
||||
// await page.AddStyleTagAsync(new AddTagOptions() { Content = report.Style });
|
||||
|
||||
log.LogDebug($"Preparing page: adding Client meta data");
|
||||
|
||||
//Client meta data to JSON string
|
||||
var clientMeta = reportRequest.ClientMeta.ToString();
|
||||
|
||||
@@ -668,9 +664,6 @@ namespace AyaNova.Biz
|
||||
if (!ReportRenderManager.KeepGoing(job.GId))
|
||||
return;
|
||||
|
||||
//#### DEBUGGING TOOL: view page contents
|
||||
// var pagecontent = await page.GetContentAsync();
|
||||
|
||||
//prePareData / preRender
|
||||
var ReportDataObject = $"{{ ayReportData:{ReportData}, ayReportMetaData:{reportMeta}, ayClientMetaData:{clientMeta}, ayServerMetaData:{serverMeta} }}";
|
||||
|
||||
@@ -691,17 +684,8 @@ namespace AyaNova.Biz
|
||||
if (!ReportRenderManager.KeepGoing(job.GId))
|
||||
return;
|
||||
|
||||
//render report as HTML
|
||||
|
||||
//add style
|
||||
// if (!string.IsNullOrWhiteSpace(report.Style))
|
||||
// {
|
||||
// log.LogDebug($"Adding report template Style CSS");
|
||||
// await page.AddStyleTagAsync(new AddTagOptions { Content = report.Style });
|
||||
// }
|
||||
// log.LogInformation(report.Style);
|
||||
// log.LogInformation(compiledHTML);
|
||||
log.LogDebug($"Setting page content to style and compiled HTML");
|
||||
//render report as HTML
|
||||
log.LogDebug($"Setting render page content style and compiled HTML");
|
||||
await page.SetContentAsync($"<style>{report.Style}</style>{compiledHTML}");
|
||||
|
||||
|
||||
@@ -722,7 +706,6 @@ namespace AyaNova.Biz
|
||||
var ClientPDFTime = reportRequest.ClientMeta["PDFTime"].Value<string>();
|
||||
PdfOptions.HeaderTemplate = report.HeaderTemplate.Replace("PDFDate", ClientPDFDate).Replace("PDFTime", ClientPDFTime);
|
||||
PdfOptions.FooterTemplate = report.FooterTemplate.Replace("PDFDate", ClientPDFDate).Replace("PDFTime", ClientPDFTime);
|
||||
|
||||
}
|
||||
|
||||
if (report.PaperFormat != ReportPaperFormat.NotSet)
|
||||
@@ -777,11 +760,7 @@ namespace AyaNova.Biz
|
||||
|
||||
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;
|
||||
//Defaults to 1. Scale amount must be between 0.1 and 2.
|
||||
|
||||
Reference in New Issue
Block a user