[FIX] mail: add access_token for image from base64 and cid

This commit is contained in:
Christophe Matthieu
2018-07-11 15:38:59 +02:00
parent 3472a34e8a
commit 50ab181762
+1 -1
View File
@@ -1770,7 +1770,7 @@ class MailThread(models.AbstractModel):
if not attachment:
attachment = fname_mapping.get(node.get('data-filename'), '')
if attachment:
node.set('src', '/web/image/%s' % attachment.id)
node.set('src', '/web/image/%s?access_token=%s' % (attachment.id, attachment.access_token))
postprocessed = True
if postprocessed:
body = lxml.html.tostring(root, pretty_print=False, encoding='UTF-8')