Odoo Help

0

How do you use the message_subscribe_udpate_subtypes method?

By
Richmond Ang
on 5/15/14, 2:49 AM 637 views

In the https://doc.openerp.com/trunk/mail/mail_subtype/ page:

There is this code:

def message_subscribe_udpate_subtypes(self, cr, uid, ids, user_id, subtype_ids,context=None):

followers_obj = self.pool.get('mail.followers') followers_ids = followers_obj.search(cr, uid, [('res_model', '=', self._name), ('res_id', 'in', ids)]) return followers_obj.write(cr, uid, followers_ids, {'subtype_ids': [(6, 0 , subtype_ids)]}, context = context)

What is the meaning of  [(6, 0 , subtype_ids)] and how do I use it for my custom message subtypes?

I need to check some of the items in the list by default when a user is added as a follower.

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

Register

Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)

Stats

Asked: 5/15/14, 2:49 AM
Seen: 637 times
Last updated: 3/16/15, 8:10 AM