[FIX] report_qweb_encrypt: conflict with bank statement

pull/573/head
ps-tubtim 2022-01-07 11:25:50 +07:00
parent 93a005f241
commit 948f5dab65
1 changed files with 2 additions and 0 deletions

View File

@ -34,6 +34,8 @@ class IrActionsReport(models.Model):
document, ttype = super(IrActionsReport, self)._render_qweb_pdf(
res_ids=res_ids, data=data
)
if isinstance(res_ids, int):
res_ids = [res_ids]
password = self._get_pdf_password(res_ids[:1])
document = self._encrypt_pdf(document, password)
return document, ttype