[FIX] thunderbird: changes in history() of partner.py
authorRifakat Haradwala (Open ERP) <rha@tinyerp.com>
Thu, 21 Apr 2011 09:53:16 +0000 (15:23 +0530)
committerRifakat Haradwala (Open ERP) <rha@tinyerp.com>
Thu, 21 Apr 2011 09:53:16 +0000 (15:23 +0530)
bzr revid: rha@tinyerp.com-20110421095316-zccag93g4spnzeja

addons/thunderbird/partner/partner.py

index 7476255..d67238d 100644 (file)
@@ -87,13 +87,16 @@ class thunderbird_partner(osv.osv_memory):
                 res['res_id'] = res_id\r
                 obj_attch.create(cr, uid, res)\r
             threads = self.pool.get(model).browse(cr, uid, res_id)\r
-            thread_pool.history(cr, uid, [threads], subject,\r
-                            email=msg.get('to', False),\r
-                            details=msg.get('body', False),\r
-                            email_from=msg.get('from', False),\r
-                            message_id= msg.get('message-id', False),\r
-                            attach= msg.get('attachments', {}),\r
-                            email_date= msg.get('date', False))\r
+            thread_pool.history(cr, uid, [threads], _('receive'), history=True,\r
+                            subject = msg.get('subject'),\r
+                            email = msg.get('to'),\r
+                            details = msg.get('body'),\r
+                            email_from = msg.get('from'),\r
+                            email_cc = msg.get('cc'),\r
+                            message_id = msg.get('message-id'),\r
+                            references = msg.get('references', False) or msg.get('in-reply-to', False),\r
+                            attach = msg.get('attachments', {}),\r
+                            email_date = msg.get('date'))\r
             res_ids.append(res_id)\r
         return len(res_ids)\r
 \r