Skip to content
Snippets Groups Projects
Commit c9f5a502 authored by Hubert Van de Walle (huvw)'s avatar Hubert Van de Walle (huvw)
Browse files

[REV] account: revert b324ba12


It was preventing custom reports from being printed

opw-2625480

closes odoo/odoo#75499

Signed-off-by: default avatarFlorian Gilbert <FlorianGilbert@users.noreply.github.com>
parent 03cd92df
Branches
Tags
No related merge requests found
......@@ -33,9 +33,3 @@ class IrActionsReport(models.Model):
if attachment:
attachment.register_as_main_attachment(force=False)
return res
@api.model
def render_qweb_pdf(self, res_ids=None, data=None):
if self.model == 'account.move' and any(not m.is_invoice(include_receipts=True) for m in self.env[self.model].browse(res_ids)):
raise UserError(_("Only invoices could be printed."))
return super(IrActionsReport, self).render_qweb_pdf(res_ids, data)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment