diff --git a/report_context/__manifest__.py b/report_context/__manifest__.py index 174504e158..edfa406a39 100644 --- a/report_context/__manifest__.py +++ b/report_context/__manifest__.py @@ -5,7 +5,7 @@ "name": "Report Context", "summary": """ Adding context to reports""", - "version": "14.0.1.0.2", + "version": "16.0.1.0.0", "license": "AGPL-3", "author": "Creu Blanca,Odoo Community Association (OCA)", "website": "https://github.com/OCA/reporting-engine", diff --git a/report_context/controllers/main.py b/report_context/controllers/main.py index ab9f604a2e..287fb329cb 100644 --- a/report_context/controllers/main.py +++ b/report_context/controllers/main.py @@ -4,7 +4,7 @@ from odoo.http import request, route -from odoo.addons.web.controllers import main as report +from odoo.addons.web.controllers import report as report class ReportController(report.ReportController): diff --git a/report_context/data/config_parameter.xml b/report_context/data/config_parameter.xml index b8439bc64e..05aab14f76 100644 --- a/report_context/data/config_parameter.xml +++ b/report_context/data/config_parameter.xml @@ -1,13 +1,11 @@ - - + + id="report_default_context" + model="ir.config_parameter" + forcecreate="True" + > report.default.context {} - diff --git a/report_context/models/ir_actions_report.py b/report_context/models/ir_actions_report.py index 1ce760c795..6f5017060a 100644 --- a/report_context/models/ir_actions_report.py +++ b/report_context/models/ir_actions_report.py @@ -29,9 +29,9 @@ def _get_context(self): context.update(self.env.context) return context - def _render(self, res_ids, data=None): + def _render(self, report_ref, res_ids, data=None): return super(IrActionsReport, self.with_context(self._get_context()))._render( - res_ids, data=data + report_ref, res_ids, data=data ) def report_action(self, docids, data=None, config=True):