From bb514316537c875867e444ad1a0fed8b0e820939 Mon Sep 17 00:00:00 2001 From: Martin Trigaux <mat@odoo.com> Date: Wed, 9 Mar 2016 14:28:12 +0100 Subject: [PATCH] [FIX] website_mail: publications of internal notes On the font-end view of project.issue, only the messages of type `note` were display. This excluded the messages recieved via email which makes hard to understand a conversation (e.g. a customer does not sees his own answers). Instead, only filter out the notifications (change of states, responsible...) opw-677426 --- addons/website_mail/models/mail_message.py | 1 - addons/website_mail/views/website_mail.xml | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/addons/website_mail/models/mail_message.py b/addons/website_mail/models/mail_message.py index e43a6eca9c0d..544282fe813a 100644 --- a/addons/website_mail/models/mail_message.py +++ b/addons/website_mail/models/mail_message.py @@ -68,4 +68,3 @@ class MailMessage(osv.Model): if cr.fetchall(): raise AccessError(_('The requested operation cannot be completed due to security restrictions. Please contact your system administrator.\n\n(Document type: %s, Operation: %s)') % (self._description, operation)) return super(MailMessage, self).check_access_rule(cr, uid, ids=ids, operation=operation, context=context) - diff --git a/addons/website_mail/views/website_mail.xml b/addons/website_mail/views/website_mail.xml index 50192030cc2b..d0df8e6b5a1e 100644 --- a/addons/website_mail/views/website_mail.xml +++ b/addons/website_mail/views/website_mail.xml @@ -73,7 +73,7 @@ </t> <t t-foreach="messages" t-as="message"> <t t-if="message.website_published or website.env.user.sudo(website.env.user.id).has_group('base.group_website_publisher')"> - <li class="media" t-if="message.message_type == 'comment'" t-att-id="'message-%s' % message.id"> + <li class="media" t-if="message.message_type != 'notification'" t-att-id="'message-%s' % message.id"> <div class="media-body"> <img class="media-object pull-left img-circle" t-attf-src="/mail/#{message.model}/#{message.res_id}/avatar/#{message.author_id.id}" style="width: 50px; margin-right: 10px;"/> -- GitLab