[FIX] account_financial_report: use proper methods to set context
This commit is contained in:
committed by
chaule97
parent
6d80804d4a
commit
132df3a92e
@@ -6,7 +6,7 @@
|
|||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||||
{
|
{
|
||||||
"name": "Account Financial Reports",
|
"name": "Account Financial Reports",
|
||||||
"version": "14.0.2.0.0",
|
"version": "14.0.2.0.1",
|
||||||
"category": "Reporting",
|
"category": "Reporting",
|
||||||
"summary": "OCA Financial Reports",
|
"summary": "OCA Financial Reports",
|
||||||
"author": "Camptocamp SA,"
|
"author": "Camptocamp SA,"
|
||||||
|
|||||||
@@ -13,13 +13,13 @@ class IrActionsReport(models.Model):
|
|||||||
return dict(self.env.context or {}, lang=lang) if lang else False
|
return dict(self.env.context or {}, lang=lang) if lang else False
|
||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
def render_qweb_html(self, docids, data=None):
|
def _render_qweb_html(self, docids, data=None):
|
||||||
context = self._prepare_account_financial_report_context(data)
|
context = self._prepare_account_financial_report_context(data)
|
||||||
obj = self.with_context(context) if context else self
|
obj = self.with_context(context) if context else self
|
||||||
return super(IrActionsReport, obj).render_qweb_html(docids, data)
|
return super(IrActionsReport, obj)._render_qweb_html(docids, data)
|
||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
def render_xlsx(self, docids, data):
|
def _render_xlsx(self, docids, data):
|
||||||
context = self._prepare_account_financial_report_context(data)
|
context = self._prepare_account_financial_report_context(data)
|
||||||
obj = self.with_context(context) if context else self
|
obj = self.with_context(context) if context else self
|
||||||
return super(IrActionsReport, obj).render_xlsx(docids, data)
|
return super(IrActionsReport, obj)._render_xlsx(docids, data)
|
||||||
|
|||||||
Reference in New Issue
Block a user