diff options
| author | Thibault Delavallée <tde@openerp.com> | 2012-02-22 14:35:01 +0100 |
|---|---|---|
| committer | Thibault Delavallée <tde@openerp.com> | 2012-02-22 14:35:01 +0100 |
| commit | d9a3b4b2900a477810c850e80b5cfb6fcbb5407f (patch) | |
| tree | 279a2d23a8e33952ca6f22d92ab6a9820b893117 | |
| parent | bb1b6fe1766ac240e2d6e0154bd0d6dcd4e714e6 (diff) | |
[REF] Cleaned mail.message get_pushed_messages method
bzr revid: tde@openerp.com-20120222133501-it9li0lh8fwvuk4e
| -rw-r--r-- | addons/mail/mail_message.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/addons/mail/mail_message.py b/addons/mail/mail_message.py index f6d7d2c863c..9391a931774 100644 --- a/addons/mail/mail_message.py +++ b/addons/mail/mail_message.py @@ -207,16 +207,13 @@ class mail_message(osv.osv): def get_pushed_messages(self, cr, uid, ids, filter_search=False, context=None): """OpenSocial: wall: get messages to display (=pushed notifications) :param filter_search: TODO - :return: dict { res_model: { res_id: [pushed message list] }} + :return: list of mail.messages, unsorted """ notification_obj = self.pool.get('mail.notification') notification_ids = notification_obj.search(cr, uid, [('user_id', '=', uid)], context=context) notifications = notification_obj.browse(cr, uid, notification_ids, context=context) - msg_ids = [notification.message_id.id for notification in notifications] - msgs = self.read(cr, uid, msg_ids, context=context) - # sort: TODO - + msgs = self.read(cr, uid, msg_ids, context=context) return msgs #------------------------------------------------------ |
