mirror of
https://gitee.com/fit2cloud-feizhiyun/MeterSphere.git
synced 2024-11-29 18:48:13 +08:00
fix(性能测试): 修复导出性能测试报告图错乱的问题
--bug=1015370 --user=刘瑞斌 【性能测试】导出报告后查看pdf报告,显示内容不对 https://www.tapd.cn/55049933/s/1212803
This commit is contained in:
parent
7fa7a76938
commit
20c69b4be7
@ -271,7 +271,7 @@ export function exportPdf(name, canvasList) {
|
||||
let blankHeight = a4Height - currentHeight;
|
||||
|
||||
if (leftHeight > blankHeight) {
|
||||
if (blankHeight < 200) {
|
||||
if (blankHeight < 300) {
|
||||
pdf.addPage();
|
||||
currentHeight = 0;
|
||||
}
|
||||
@ -285,10 +285,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
Block a user