|
@@ -343,14 +343,14 @@ func Report2pdfAndJpeg(reportUrl string, reportId, reportType int) {
|
|
|
|
|
|
// 7/10为A4的比例,不需要重新算
|
|
|
if freeRatio != "" && freeRatio != "7/10" {
|
|
|
- h, e := calculateReportPdfHeight(pcHeight, freeRatio)
|
|
|
+ h, e := calculateReportPdfHeight(pcWidth, freeRatio)
|
|
|
if e != nil {
|
|
|
err = fmt.Errorf("重新计算PDF生成高度失败, %v", e)
|
|
|
return
|
|
|
}
|
|
|
pcHeight = h
|
|
|
|
|
|
- hm, e := calculateReportPdfHeight(mobileHeight, freeRatio)
|
|
|
+ hm, e := calculateReportPdfHeight(mobileWidth, freeRatio)
|
|
|
if e != nil {
|
|
|
err = fmt.Errorf("重新计算移动端PDF生成高度失败, %v", e)
|
|
|
return
|