diff options
| author | Thanh Dodeur <tso@odoo.com> | 2020-03-26 09:11:30 +0000 |
|---|---|---|
| committer | Thanh Dodeur <tso@odoo.com> | 2020-04-17 11:09:41 +0000 |
| commit | bf97152ce99f84a524ed8773280b4bba8fca38da (patch) | |
| tree | 5776a716c2bdcd06a89170511793a838b860f662 /addons/mail/static/src/xml/thread.xml | |
| parent | a6e96c256ded6bb764d1ab469878ef780ecdbe3c (diff) | |
[REF] mail: removes signature from route params
This commit removes the unnecessary usage of `signature` instead of
`unique` in the route params for `web/image`.
closes odoo/odoo#48437
Related: odoo/enterprise#9501
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
Diffstat (limited to 'addons/mail/static/src/xml/thread.xml')
| -rw-r--r-- | addons/mail/static/src/xml/thread.xml | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/addons/mail/static/src/xml/thread.xml b/addons/mail/static/src/xml/thread.xml index b32b8afa1af..0774be1ccaa 100644 --- a/addons/mail/static/src/xml/thread.xml +++ b/addons/mail/static/src/xml/thread.xml @@ -54,10 +54,13 @@ </div> <div class="o_viewer_img_wrapper"> <div class="o_viewer_zoomer"> - <div t-if="widget.activeAttachment.fileType == 'image'" class="o_loading_img text-center"> - <i class="fa fa-circle-o-notch fa-spin text-gray-light fa-3x fa-fw" role="img" aria-label="Loading" title="Loading"/> - </div> - <img t-if="widget.activeAttachment.fileType === 'image'" class="o_viewer_img" t-attf-src="/web/image/#{widget.activeAttachment.id}?unique=1&signature=#{widget.activeAttachment.checksum}&model=#{model}" alt="Viewer"/> + <t t-if="widget.activeAttachment.fileType === 'image'"> + <div class="o_loading_img text-center"> + <i class="fa fa-circle-o-notch fa-spin text-gray-light fa-3x fa-fw" role="img" aria-label="Loading" title="Loading"/> + </div> + <t t-set="unique" t-value="widget.activeAttachment.checksum ? widget.activeAttachment.checksum.slice(-8) : ''"/> + <img class="o_viewer_img" t-attf-src="/web/image/#{widget.activeAttachment.id}?unique=#{unique}&model=#{model}" alt="Viewer"/> + </t> <iframe t-if="widget.activeAttachment.fileType == 'application/pdf'" class="mt32 o_viewer_pdf" t-attf-src="/web/static/lib/pdfjs/web/viewer.html?file=/web/content/#{widget.activeAttachment.id}?model%3D#{model}" /> <iframe t-if="(widget.activeAttachment.fileType || '').indexOf('text') !== -1" class="mt32 o_viewer_text" t-attf-src="/web/content/#{widget.activeAttachment.id}?model=#{model}" /> <iframe t-if="widget.activeAttachment.fileType == 'youtu'" class="mt32 o_viewer_text" allow="autoplay; encrypted-media" width="560" height="315" t-attf-src="https://www.youtube.com/embed/#{widget.activeAttachment.youtube}"/> |
