summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/views/basic/basic_model.js
diff options
context:
space:
mode:
authorAdrian Torres <adt@odoo.com>2018-01-26 16:02:24 +0100
committerGitHub <noreply@github.com>2018-01-26 16:02:24 +0100
commita094095ef3c0be08adfaee69f9865465e3813d46 (patch)
treec42644c5866af1591ef7e3dd4bf7ef55ac9dc097 /addons/web/static/src/js/views/basic/basic_model.js
parent4a409fb4bfcf911b3ad1a8df8c401131f303ab49 (diff)
[IMP] mail: check if template can be rendered on write (#20834)
* [IMP] mail: check if template can be rendered on write Before this commit, whenever a user would send an email from a template containing mako python expressions and those expressions contained syntax errors, the mail would still be sent but the body would be empty, this was intended behavior but due to an increase in complaints of empty mails being sent, the behavior was reviewed. This commit improves on this behavior by: 1. Rendering the template on write (save) 2. Checking if the template rendered successfully 3. Raising a UserError if the rendering failed The end result is a modal box showing an error to the user whenever he either saves an mail.template with python syntax error in mako snippers or when a mail with mako snippets is rendered on-the-fly (wizard).
Diffstat (limited to 'addons/web/static/src/js/views/basic/basic_model.js')
0 files changed, 0 insertions, 0 deletions