summaryrefslogtreecommitdiff
path: root/addons/snailmail/static/src/xml/thread.xml
diff options
context:
space:
mode:
Diffstat (limited to 'addons/snailmail/static/src/xml/thread.xml')
-rw-r--r--addons/snailmail/static/src/xml/thread.xml37
1 files changed, 37 insertions, 0 deletions
diff --git a/addons/snailmail/static/src/xml/thread.xml b/addons/snailmail/static/src/xml/thread.xml
new file mode 100644
index 00000000000..aeda07445be
--- /dev/null
+++ b/addons/snailmail/static/src/xml/thread.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<template id="template" xml:space="preserve">
+
+ <t t-extend="mail.widget.Thread.Message">
+ <t t-jquery=".o_thread_tooltip_container" t-operation="after">
+ <span t-if="message.getType() === 'snailmail' and options.displaySnailmailIcons" class="o_thread_snailmail_tooltip_container">
+ <t t-set="thread_icon_class" t-value="'o_thread_snailmail_tooltip o_thread_message_snailmail o_thread_message_snailmail_' + message.getSnailmailStatus()" />
+ <t t-if="message.getSnailmailError()">
+ <t t-set="thread_icon_class" t-value="thread_icon_class + ' o_thread_message_snailmail_error'"/>
+ </t>
+ <i t-att-class="thread_icon_class + ' fa fa-paper-plane'" t-att-data-message-id="message.getID()"/>
+ </span>
+ </t>
+ </t>
+
+ <t t-name="snailmail.widget.Thread.Message.SnailmailTooltip">
+ <span class="d-inline-block text-center o_thread_tooltip_snailmail">
+ <t t-if="status === 'sent'">
+ <i class='fa fa-check o_thread_tooltip_snailmail_icon' title="Sent" role="img" aria-label="Sent"/>
+ Sent
+ </t>
+ <t t-elif="status === 'canceled'">
+ <i class='fa fa-trash-o o_thread_tooltip_snailmail_icon' title="Canceled" role="img" aria-label="Canceled"/>
+ Canceled
+ </t>
+ <t t-elif="status === 'pending'">
+ <i class='fa fa-clock-o o_thread_tooltip_snailmail_icon' title="Awaiting Dispatch" role="img" aria-label="Awaiting Dispatch"/>
+ Awaiting Dispatch
+ </t>
+ <t t-else="">
+ <i class='fa fa-exclamation text-danger o_thread_tooltip_snailmail_icon' title="Error" role="img" aria-label="Error"/>
+ Error
+ </t>
+ </span>
+ </t>
+
+</template>