[FIX] base: wkhtml2pdf multiple documents

Steps to reproduce:
- set up a header with company logo
- print 20 sale orders in arabic

Bug:
header disapears on most pages

Fix:
add a setting to allow users to increase the delay before printing

opw-3217155

closes odoo/odoo#122983

X-original-commit: 68f7cbd15df7839aab146023399da1570b12b441
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Walid Hanniche (waha) <waha@odoo.com>
This commit is contained in:
Walid
2023-05-31 02:27:50 +02:00
parent 25cfb97f7e
commit fa66af2c47
+2 -1
View File
@@ -290,7 +290,8 @@ class IrActionsReport(models.Model):
command_args.extend(['--disable-smart-shrinking'])
# Add extra time to allow the page to render
command_args.extend(['--javascript-delay', '1000'])
delay = self.env['ir.config_parameter'].sudo().get_param('report.print_delay', '1000')
command_args.extend(['--javascript-delay', delay])
if landscape:
command_args.extend(['--orientation', 'landscape'])