[FIX] crm: mailgate: Use the right fields from the header for the 'From' and 'To' fields
bzr revid: stephane@openerp.com-20100512124414-h76qmp00qu6obhfv
This commit is contained in:
parent
6428a5398f
commit
ac53d556db
|
@ -315,7 +315,8 @@ class email_parser(object):
|
|||
'res_id': id
|
||||
}
|
||||
self.rpc('ir.attachment', 'create', data_attach)
|
||||
self.rpc(self.model, 'history', [id], 'Send', True, self._decode_header(msg['From']), body['body'])
|
||||
|
||||
self.rpc(self.model, 'history', [id], 'Send', True, self._decode_header(msg['To']), body['body'], self._decode_header(msg['From']), False, {'model' : self.model})
|
||||
return id
|
||||
|
||||
def msg_send(self, msg, emails, priority=None):
|
||||
|
@ -358,7 +359,8 @@ class email_parser(object):
|
|||
'res_id': id
|
||||
}
|
||||
self.rpc('ir.attachment', 'create', data_attach)
|
||||
self.rpc(self.model, 'history', [id], 'Send', True, self._decode_header(msg['From']), message['body'])
|
||||
|
||||
self.rpc(self.model, 'history', [id], 'Send', True, self._decode_header(msg['To']), message['body'], self._decode_header(msg['From']), False, {'model' : self.model})
|
||||
return id
|
||||
|
||||
def msg_test(self, msg, case_str):
|
||||
|
|
Loading…
Reference in New Issue