diff --git a/addons/mail/mail_message_subtype.py b/addons/mail/mail_message_subtype.py index 253ec600c6c..bef6e427c3b 100644 --- a/addons/mail/mail_message_subtype.py +++ b/addons/mail/mail_message_subtype.py @@ -22,6 +22,7 @@ from openerp.osv import osv from openerp.osv import fields + class mail_message_subtype(osv.osv): """ Class holding subtype definition for messages. Subtypes allow to tune the follower subscription, allowing only some subtypes to be pushed diff --git a/addons/mail/mail_thread.py b/addons/mail/mail_thread.py index d85e91fa8ba..ab4eead1a6e 100644 --- a/addons/mail/mail_thread.py +++ b/addons/mail/mail_thread.py @@ -162,7 +162,8 @@ class mail_thread(osv.AbstractModel): res[fol.res_id]['message_subtype_data'] = thread_subtype_dict return res - def apply_edited_subtypes(self, cr, uid, ids, partner_id,check_list, context=None): + def apply_edited_subtypes(self, cr, uid, ids, partner_id, check_list, context=None): + print "\n\n uid, ids, partner_id, check_list,,>", uid, ids, partner_id, check_list, """ Apply the edited subtypes of the user.""" fol_obj = self.pool.get('mail.followers') @@ -171,7 +172,8 @@ class mail_thread(osv.AbstractModel): ('res_id', 'in', ids), ('res_model', '=', self._name), ], context=context) - fol_obj.write(cr, uid, fol_ids, {'subtype_ids': [(6, 0, check_list)]}, context=context) + print "\n fol _ids>", fol_ids, check_list + fol_obj.write(cr, uid, fol_ids, {'subtype_ids': [(6,0, check_list)]}, context=context) return True def _search_message_unread(self, cr, uid, obj=None, name=None, domain=None, context=None): diff --git a/addons/mail/static/src/js/mail_followers.js b/addons/mail/static/src/js/mail_followers.js index 0eb864d02da..0bfcbfc29e9 100644 --- a/addons/mail/static/src/js/mail_followers.js +++ b/addons/mail/static/src/js/mail_followers.js @@ -31,7 +31,6 @@ openerp_mail_followers = function(session, mail) { this.ds_model = new session.web.DataSetSearch(this, this.view.model); this.ds_follow = new session.web.DataSetSearch(this, this.field.relation); this.ds_users = new session.web.DataSetSearch(this, 'res.users'); - this.check_access = false; this.value = []; this.followers = []; @@ -87,15 +86,15 @@ openerp_mail_followers = function(session, mail) { var partner_name = $(event.target).siblings('a').text(); var id = this.view.datarecord.id; var res_model = this.view.dataset.model; - var $dialog = session.web.dialog($('