Installation is ok, but when you try to print a sale order with comments it raises an error because de template has an erroneous expression (
)
To Reproduce
Affected versions: 14.0
Steps to reproduce the behavior:
Install module
Create a template from Sales > Configuration > Comments..
Create / edit a sale order and link created comments above.
Print sale order report
Expected behavior
Sale order report must print configured "Comments" (on top/bottom as defined) but it raises an error:
Odoo Server Error
Traceback (most recent call last):
File "/odoo/odoo-server/odoo/addons/base/models/qweb.py", line 331, in _compiled_fn
return compiled(self, append, new, options, log)
File "", line 1, in template_sale_report_saleorder_document_1838
File "", line 2, in body_call_content_1836
File "", line 1, in foreach_1835
AttributeError: 'sale.order' object has no attribute 'render_comment'
Additional context
There are other related modules (account_comment_template) running fine. The problem is in module template (sale_comment_template/views/report_saleorder.xml):
the current code that fails:
<div t-raw="doc.render_comment(comment_template_top)" />
the sugested code than runs:
<div t-raw="comment_template_top.text" />
Module
sale_comment_template
Describe the bug
Installation is ok, but when you try to print a sale order with comments it raises an error because de template has an erroneous expression (
)To Reproduce
Affected versions: 14.0
Steps to reproduce the behavior:
Expected behavior Sale order report must print configured "Comments" (on top/bottom as defined) but it raises an error: Odoo Server Error Traceback (most recent call last): File "/odoo/odoo-server/odoo/addons/base/models/qweb.py", line 331, in _compiled_fn return compiled(self, append, new, options, log) File "", line 1, in template_sale_report_saleorder_document_1838 File "", line 2, in body_call_content_1836 File "", line 1, in foreach_1835 AttributeError: 'sale.order' object has no attribute 'render_comment'
Additional context There are other related modules (account_comment_template) running fine. The problem is in module template (sale_comment_template/views/report_saleorder.xml):
THIS ONE FAILS THIS ONE RUNS