Merge PR #930 into 16.0

Signed-off-by HviorForgeFlow
This commit is contained in:
OCA-git-bot
2024-10-01 13:49:25 +00:00

View File

@@ -34,9 +34,13 @@ def _normalize_filepath(path):
class IrActionsReport(models.Model):
_inherit = "ir.actions.report"
def _is_report_type_signable(self):
self.ensure_one()
return self.report_type == "qweb-pdf"
def _certificate_get(self, report, res_ids):
"""Obtain the proper certificate for the report and the conditions."""
if report.report_type != "qweb-pdf":
if not report._is_report_type_signable():
return False
company_id = self.env.company.id
if res_ids: