[IMP] mail: context key for message author subscription

By default the author of a message is always removed from the notified recipients.
However in some cases it is interesting to be able to notify the author. A context
key has been added that handle that case.
This commit is contained in:
Thibault Delavallée
2015-10-05 11:56:05 +02:00
parent 17e562ecef
commit eb7139b01f
+1 -1
View File
@@ -836,7 +836,7 @@ class Message(models.Model):
partners = self_sudo.partner_ids
# remove author from notified partners
if self_sudo.author_id:
if not self._context.get('mail_notify_author', False) and self_sudo.author_id:
partners = partners - self_sudo.author_id
# update message