[IMP] Oops sorry forgot to remove the prints and improved code.

bzr revid: psa@tinyerp.com-20130315124843-xtp19rbm2cvyfb67
This commit is contained in:
Paramjit Singh Sahota
2013-03-15 18:18:43 +05:30
parent b5df63291a
commit 0abe605544
2 changed files with 3 additions and 5 deletions
-2
View File
@@ -163,7 +163,6 @@ class mail_thread(osv.AbstractModel):
return res
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')
@@ -172,7 +171,6 @@ class mail_thread(osv.AbstractModel):
('res_id', 'in', ids),
('res_model', '=', self._name),
], 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
+3 -3
View File
@@ -112,9 +112,9 @@ openerp_mail_followers = function(session, mail) {
on_apply_subtype: function(id, partner_id) {
var check_list = new Array();
_($('.oe_edit_actions input[type="checkbox"]')).each(function (records) {
if ($(records).is(':checked')) {
check_list.push(parseInt($(records).data('id')));
_($('.oe_edit_actions input[type="checkbox"]')).each(function (record) {
if ($(record).is(':checked')) {
check_list.push(parseInt($(record).data('id')));
}
});