Skip to content

Commit

Permalink
Merge PR #1249 into 15.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Nov 15, 2023
2 parents 938f9ec + dd8677b commit 0455e92
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion email_template_qweb/models/mail_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,11 @@ def generate_email(self, res_ids, fields):
not fields or "body_html" in fields
):
for record in self_with_lang.env[self.model].browse(res_id):
body_html = self_with_lang.body_view_id._render(
values = self_with_lang._render_eval_context()
values.update(
{"object": record, "email_template": self_with_lang}
)
body_html = self_with_lang.body_view_id._render(values)
# Some wizards, like when sending a sales order, need this
# fix to display accents correctly
body_html = tools.ustr(body_html)
Expand Down

0 comments on commit 0455e92

Please sign in to comment.