|
@@ -163,6 +163,7 @@ async def main():
|
|
|
await asyncio.sleep(10)
|
|
|
|
|
|
await page.pdf({
|
|
|
+ 'width': "%s",
|
|
|
'path': "%s",
|
|
|
'printBackground': True,
|
|
|
'format': "A2",
|
|
@@ -186,7 +187,7 @@ finally:
|
|
|
loop.close()
|
|
|
`
|
|
|
|
|
|
- pyCode = fmt.Sprintf(pyCode, utils.ChromePath, width, reportUrl, filePath)
|
|
|
+ pyCode = fmt.Sprintf(pyCode, utils.ChromePath, width, reportUrl, width, filePath)
|
|
|
utils.FileLog.Info("pdf pyCode: \n" + pyCode)
|
|
|
cmd := exec.Command("python3", "-c", pyCode)
|
|
|
output, e := cmd.CombinedOutput()
|