From d9287caf9408bb4ff85ad734cbca08e44321e205 Mon Sep 17 00:00:00 2001 From: Martin Trigaux Date: Fri, 14 Feb 2020 11:22:15 +0100 Subject: [IMP] *: convert to private methods render, render_template, load, activity_schedule_with_view, get_website_pages should all be private: It should not be possible to render an aribtrary template only with its name or id Still need to render some qweb views from js so the method render_template is kept public. This explains why the website editor still need read access on ir.ui.view as we want to allow any snippet to be rendered. --- odoo/addons/base/wizard/base_document_layout.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'odoo/addons/base/wizard/base_document_layout.py') diff --git a/odoo/addons/base/wizard/base_document_layout.py b/odoo/addons/base/wizard/base_document_layout.py index d380c1c49a6..5232acb7f06 100644 --- a/odoo/addons/base/wizard/base_document_layout.py +++ b/odoo/addons/base/wizard/base_document_layout.py @@ -64,7 +64,7 @@ class BaseDocumentLayout(models.TransientModel): for wizard in self: if wizard.report_layout_id: ir_qweb = wizard.env['ir.qweb'] - wizard.preview = ir_qweb.render('base.layout_preview', {'company': wizard}) + wizard.preview = ir_qweb._render('base.layout_preview', {'company': wizard}) else: wizard.preview = False -- cgit v1.2.3