[MERGE] [FIX] mail: attachments in pure email mass mailing.
authorThibault Delavallée <tde@openerp.com>
Fri, 29 Nov 2013 09:44:06 +0000 (10:44 +0100)
committerThibault Delavallée <tde@openerp.com>
Fri, 29 Nov 2013 09:44:06 +0000 (10:44 +0100)
commit3a47a73272cece0bdb6569bf558880a7d3bd61e8
tree8fa08d62d46c69f9fb54a80a9b30d9f26f198894
parent702b9c2e1bba826b29e9d9157b42c583f72d8d5b
parent5859d84dc1af5c0eed462f47b11894f875ec13cf
[MERGE] [FIX] mail: attachments in pure email mass mailing.

When generating pure email mass mailing, the values are directly sent to mail_mail.create() instead of going through mail_thread.message_post(). We therefore have to process attachments (coming from email_template, as a list of tuples (attachment_name, b64-encoded attachment_content)) as well as attachment_ids, like it is done in message_post.
As this behavior is the same as the one already implemented for message_post, this feature has been moved into its dedicated method called by message_post or called before going into mail_mail.create(), depending on the mailing type.

[FIX] email_template: when generating reports in batch, correctly attach the generate attachments to the various record ids we are iterating on.

bzr revid: tde@openerp.com-20131129094406-90cijc5ac4pmp4y7