[FW][FIX] mail: correctly format rejection email moderation content

When an incoming email on a channel is rejected, an email is sent to the
original author to inform him of the rejection. This email contains the
original email content added in a generic rejection email.

This original content was however considered as plaintext and escaped. Result
was quite hard to read. As content is sanitized we can safely append it to
the rejection email as valid html.

Task ID 2121319
PR #39986
FW PR #39978

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
This commit is contained in:
Thibault Delavallée
2019-11-08 08:13:33 +00:00
parent 6befb1b400
commit f4ef7cbc5e
+1 -1
View File
@@ -838,7 +838,7 @@ class Message(models.Model):
else:
email_from = self.env.company.catchall
body_html = tools.append_content_to_html('<div>%s</div>' % tools.ustr(comment), msg.body)
body_html = tools.append_content_to_html('<div>%s</div>' % tools.ustr(comment), msg.body, plaintext=False)
vals = {
'subject': subject,
'body_html': body_html,