fix(性能测试): 修复导出报告图表错乱的问题
This commit is contained in:
parent
13c5754098
commit
87e00fb3d5
|
@ -168,7 +168,7 @@ export function exportPdf(name, canvasList) {
|
|||
let blankHeight = a4Height - currentHeight;
|
||||
|
||||
if (leftHeight > blankHeight) {
|
||||
if (blankHeight < 200) {
|
||||
if (blankHeight < 300) {
|
||||
pdf.addPage();
|
||||
currentHeight = 0;
|
||||
}
|
||||
|
@ -182,10 +182,10 @@ export function exportPdf(name, canvasList) {
|
|||
leftHeight -= occupation;
|
||||
position -= occupation;
|
||||
//避免添加空白页
|
||||
// if (leftHeight > 0) {
|
||||
// pdf.addPage();
|
||||
// currentHeight = 0;
|
||||
// }
|
||||
if (leftHeight > 0) {
|
||||
pdf.addPage();
|
||||
currentHeight = 0;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
pdf.addImage(pageData, 'JPEG', 0, currentHeight, imgWidth, imgHeight);
|
||||
|
|
Loading…
Reference in New Issue