Nimesh Contractor(Open ERP) has proposed merging lp:~openerp-dev/openobject-addons/trunk-bug-1099181-nco into lp:openobject-addons.
Requested reviews: OpenERP Core Team (openerp) Related bugs: Bug #1099181 in OpenERP Addons: "[Trunk/7.0] not using opt_out option and send not wanted email to customer" https://bugs.launchpad.net/openobject-addons/+bug/1099181 For more details, see: https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-1099181-nco/+merge/143446 Hello, Fix the problem of using opt_out option and send not wanted email to customer. Thanks, NCO. -- https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-1099181-nco/+merge/143446 Your team OpenERP R&D Team is subscribed to branch lp:~openerp-dev/openobject-addons/trunk-bug-1099181-nco.
=== modified file 'portal_sale/portal_sale.py' --- portal_sale/portal_sale.py 2012-12-21 11:53:15 +0000 +++ portal_sale/portal_sale.py 2013-01-16 07:54:21 +0000 @@ -59,7 +59,7 @@ assert len(ids) == 1 document = self.browse(cr, uid, ids[0], context=context) partner = document.partner_id - if partner.id not in document.message_follower_ids: + if (partner.id not in document.message_follower_ids) and not partner.opt_out: self.message_subscribe(cr, uid, ids, [partner.id], context=context) user = self.pool.get('res.users').browse(cr, uid, uid, context=context) mail_values = { @@ -120,7 +120,7 @@ # fetch the partner's id and subscribe the partner to the invoice document = self.browse(cr, uid, ids[0], context=context) partner = document.partner_id - if partner.id not in document.message_follower_ids: + if (partner.id not in document.message_follower_ids) and not partner.opt_out: self.message_subscribe(cr, uid, ids, [partner.id], context=context) user = self.pool.get('res.users').browse(cr, uid, uid, context=context) mail_values = {
_______________________________________________ Mailing list: https://launchpad.net/~openerp-dev-gtk Post to : openerp-dev-gtk@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-dev-gtk More help : https://help.launchpad.net/ListHelp