FIX; Whatsapp issue
This commit is contained in:
parent
a801a30488
commit
a42d6449cf
|
|
@ -202,6 +202,7 @@ class DiscussChannel(models.Model):
|
||||||
)
|
)
|
||||||
if partners_to_notify == channel.whatsapp_partner_id and wa_account_id.notify_user_ids.partner_id:
|
if partners_to_notify == channel.whatsapp_partner_id and wa_account_id.notify_user_ids.partner_id:
|
||||||
partners_to_notify += wa_account_id.notify_user_ids.partner_id
|
partners_to_notify += wa_account_id.notify_user_ids.partner_id
|
||||||
|
partners_to_notify = self.env['res.partner'].browse(list(set(partners_to_notify.ids)))
|
||||||
channel.channel_member_ids = [Command.clear()] + [Command.create({'partner_id': partner.id}) for partner in partners_to_notify]
|
channel.channel_member_ids = [Command.clear()] + [Command.create({'partner_id': partner.id}) for partner in partners_to_notify]
|
||||||
channel._broadcast(partners_to_notify.ids)
|
channel._broadcast(partners_to_notify.ids)
|
||||||
return channel
|
return channel
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue