-
-
Notifications
You must be signed in to change notification settings - Fork 194
Description
Module
brand_external_layout
Describe the bug
Error when printing a PDF report with external layout (e.g. invoice pdf). Odoo added a field to res.company which is used in the external report XML, but the field doesn't exist yet on res.brand.
odoo/odoo@5db133d
To Reproduce
16.0
possible other versions if this field is backported
Steps to reproduce the behavior:
- Print any external report
Error log
RPC_ERROR
Odoo Server Error
Traceback (most recent call last):
File "<199>", line 302, in template_199
File "<199>", line 75, in template_199_content
AttributeError: 'res.brand' object has no attribute 'is_company_details_empty'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/odoo/src/odoo/addons/web/controllers/report.py", line 113, in report_download
response = self.report_routes(reportname, docids=docids, converter=converter, context=context)
File "/home/odoo/src/odoo/odoo/http.py", line 697, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "/home/odoo/src/odoo/addons/web/controllers/report.py", line 42, in report_routes
pdf = report.with_context(context)._render_qweb_pdf(reportname, docids, data=data)[0]
File "/home/odoo/src/odoo/addons/account/models/ir_actions_report.py", line 61, in _render_qweb_pdf
return super()._render_qweb_pdf(report_ref, res_ids=res_ids, data=data)
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 807, in _render_qweb_pdf
collected_streams = self._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
File "/home/odoo/src/odoo/addons/account_edi_ubl_cii/models/ir_actions_report.py", line 58, in _render_qweb_pdf_prepare_streams
collected_streams = super()._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
File "/home/odoo/src/odoo/addons/account_edi/models/ir_actions_report.py", line 14, in _render_qweb_pdf_prepare_streams
collected_streams = super()._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
File "/home/odoo/src/odoo/addons/account/models/ir_actions_report.py", line 20, in _render_qweb_pdf_prepare_streams
return super()._render_qweb_pdf_prepare_streams(report_ref, data, res_ids=res_ids)
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 708, in _render_qweb_pdf_prepare_streams
html = self.with_context(**additional_context)._render_qweb_html(report_ref, res_ids_wo_stream, data=data)[0]
File "/home/odoo/src/enterprise/web_studio/models/ir_actions_report.py", line 19, in _render_qweb_html
return super(IrActionsReport, self)._render_qweb_html(report_ref, docids, data)
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 884, in _render_qweb_html
return self._render_template(report.report_name, data), 'html'
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_actions_report.py", line 623, in _render_template
return view_obj._render_template(template, values).encode()
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_ui_view.py", line 2128, in _render_template
return self.env['ir.qweb']._render(template, values)
File "/home/odoo/src/odoo/odoo/tools/profiler.py", line 292, in _tracked_method_render
return method_render(self, template, values, **options)
File "/home/odoo/src/odoo/odoo/addons/base/models/ir_qweb.py", line 580, in _render
result = ''.join(rendering)
File "<694>", line 90, in template_694
File "<694>", line 72, in template_694_content
File "<694>", line 60, in template_694_t_call_0
File "<690>", line 2108, in template_690
File "<690>", line 2097, in template_690_content
File "<202>", line 150, in template_202
File "<202>", line 106, in template_202_content
File "<199>", line 308, in template_199
odoo.addons.base.models.ir_qweb.QWebException: Error while render the template
AttributeError: 'res.brand' object has no attribute 'is_company_details_empty'
Template: web.external_layout_boxed
Path: /t/div[1]/div/div/div[2]/div[2]/ul/li[1]
Node: