From 0c2bbf6da689912df3574bccfa779fa9e9971ca2 Mon Sep 17 00:00:00 2001 From: Yannick Tivisse Date: Wed, 17 Feb 2016 13:01:10 +0100 Subject: [PATCH] [FIX] website_project_issue: Don't always display 'View Issue' This override was always sending the document to all the recipients. If the user is only a follower, he sees the button but cannot access to My Account as he's not a user. --- addons/website_project_issue/models/project_issue.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/addons/website_project_issue/models/project_issue.py b/addons/website_project_issue/models/project_issue.py index 90238037a6e..a3dd4170826 100644 --- a/addons/website_project_issue/models/project_issue.py +++ b/addons/website_project_issue/models/project_issue.py @@ -19,14 +19,3 @@ class Issue(models.Model): 'target': 'self', 'res_id': self.id, } - - @api.multi - def _notification_get_recipient_groups(self, message, recipients): - """ Override to set the access button: everyone can see an access button - on their notification email. It will lead on the website view of the - post. """ - res = super(Issue, self)._notification_get_recipient_groups(message, recipients) - access_action = self._notification_link_helper('view', model=message.model, res_id=message.res_id) - for category, data in res.iteritems(): - res[category]['button_access'] = {'url': access_action, 'title': _('View Issue')} - return res