summaryrefslogtreecommitdiff
path: root/addons/fetchmail/fetchmail.py
diff options
context:
space:
mode:
authorFabien Meghazi <fme@openerp.com>2012-10-02 09:49:31 +0200
committerFabien Meghazi <fme@openerp.com>2012-10-02 09:49:31 +0200
commit4d2299adc4e9d7db2cb52a79cf4ab8ebaad707ae (patch)
tree8a45a95b39d3b060fdef188f3da8a70fbfe20ad5 /addons/fetchmail/fetchmail.py
parent32d492acf9db0a57487a1c6c47e4311d842e99f7 (diff)
parenta5fac44994a5d2c0e20cdde0bf72ef152d2342dd (diff)
[MERGE] trunk
bzr revid: fme@openerp.com-20121002074931-845aiqhflw2rqrcn
Diffstat (limited to 'addons/fetchmail/fetchmail.py')
-rw-r--r--addons/fetchmail/fetchmail.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/fetchmail/fetchmail.py b/addons/fetchmail/fetchmail.py
index 70a05c6bd0e..e0023697594 100644
--- a/addons/fetchmail/fetchmail.py
+++ b/addons/fetchmail/fetchmail.py
@@ -195,7 +195,7 @@ openerp_mailgate.py -u %(uid)d -p PASSWORD -o %(model)s -d %(dbname)s --host=HOS
strip_attachments=(not server.attach),
context=context)
if res_id and server.action_id:
- action_pool.run(cr, uid, [server.action_id.id], {'active_id': res_id, 'active_ids':[res_id]})
+ action_pool.run(cr, uid, [server.action_id.id], {'active_id': res_id, 'active_ids':[res_id], 'active_model': context.get("thread_model", False)})
imap_server.store(num, '+FLAGS', '\\Seen')
cr.commit()
count += 1
@@ -220,7 +220,7 @@ openerp_mailgate.py -u %(uid)d -p PASSWORD -o %(model)s -d %(dbname)s --host=HOS
strip_attachments=(not server.attach),
context=context)
if res_id and server.action_id:
- action_pool.run(cr, uid, [server.action_id.id], {'active_id': res_id, 'active_ids':[res_id]})
+ action_pool.run(cr, uid, [server.action_id.id], {'active_id': res_id, 'active_ids':[res_id], 'active_model': context.get("thread_model", False)})
pop_server.dele(num)
cr.commit()
_logger.info("fetched/processed %s email(s) on %s server %s", numMsgs, server.type, server.name)