Skip to content
Permalink
Browse files

[IMP] sms: allow to send SMS to oneself

Currently discuss post (through mail or sms) does not allow the author
to be notified of its content, as

  * he posted it and is therefore already updated;
  * it could create email loops;

However with SMS one could easily try to send SMS to himself using the
sms composer that is different from the mail composer. In that case
just use the ``mail_notify_author`` context key allowing to bypass the
"no author notification" rule.

Task ID 2091685
PR #40650
  • Loading branch information
Florimond authored and tde-banana-odoo committed Nov 21, 2019
1 parent 56e47c5 commit a188cedad2e60e1d9c45bb3e0b9c8fa4b6b1505a
Showing with 2 additions and 0 deletions.
  1. +2 −0 addons/sms/wizard/sms_composer.py
@@ -314,4 +314,6 @@ def _get_records(self):
records = self.env[self.res_model].browse(self.res_id)
else:
records = self.env[self.res_model].browse(literal_eval(self.res_ids or '[]'))

records = records.with_context(mail_notify_author=True)
return records

0 comments on commit a188ced

Please sign in to comment.
You can’t perform that action at this time.