[FIX] mail.compose.message in email_template: var typo
authorThibault Delavallée <tde@openerp.com>
Thu, 6 Jun 2013 13:08:51 +0000 (15:08 +0200)
committerThibault Delavallée <tde@openerp.com>
Thu, 6 Jun 2013 13:08:51 +0000 (15:08 +0200)
bzr revid: tde@openerp.com-20130606130851-h5jswklvvz98enue

addons/email_template/wizard/mail_compose_message.py

index 6fbc541..746c2cc 100644 (file)
@@ -64,7 +64,7 @@ class mail_compose_message(osv.TransientModel):
                 continue
             new_attachment_ids = []
             for attachment in wizard.attachment_ids:
-                if attachment in wizard.template.attachment_ids:
+                if attachment in wizard.template_id.attachment_ids:
                     new_attachment_ids.append(self.pool.get('ir.attachment').copy(cr, uid, attachment.id, {'res_model': 'mail.compose.message', 'res_id': wizard.id}, context=context))
                 else:
                     new_attachment_ids.append(attachment.id)