From f5ebe79d3898472ec4f2113336d8103268c5daaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thibault=20Delavall=C3=A9e?= Date: Wed, 12 Sep 2012 13:28:32 +0200 Subject: [PATCH] [FIX] Chatter: attachments are now also cleaned after posting. bzr revid: tde@openerp.com-20120912112832-qy0yhzaee7g0f6p7 --- addons/mail/static/src/js/mail.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/addons/mail/static/src/js/mail.js b/addons/mail/static/src/js/mail.js index 03c79a6b54b..71665bc69fb 100644 --- a/addons/mail/static/src/js/mail.js +++ b/addons/mail/static/src/js/mail.js @@ -205,10 +205,14 @@ openerp.mail = function(session) { this.options.context = _.extend(this.options.context, new_context || {}); this.ds_compose.context = _.extend(this.ds_compose.context, this.options.context); return this.ds_compose.call('default_get', [ - ['subject', 'body_text', 'body', 'attachment_ids', 'partner_ids', 'composition_mode', + ['subject', 'body_text', 'body', 'partner_ids', 'composition_mode', 'use_template', 'template_id', 'model', 'res_id', 'parent_id', 'content_subtype'], this.ds_compose.get_context(), - ]).then( function (result) { self.form_view.on_processed_onchange({'value': result}, []); }); + ]).then( function (result) { + self.form_view.on_processed_onchange({'value': result}, []); + self.attachment_ids = []; + self.display_attachments(); + }); }, /**