From 6a5dc8bcd1310e1cd326026d64769a400a075202 Mon Sep 17 00:00:00 2001 From: Christophe Matthieu Date: Wed, 11 Jul 2018 14:47:33 +0200 Subject: [FIX] mail: remove attachment feature in add followers modal Before this fix, the attachments are don't save to the record and are remove with the wizard. We can't add the attachments to mail.message (like 'mail.compose.message') because it's auto_delete/unlink and the attachments are removed before the recipient can read it. --- addons/web_editor/static/src/js/backend/fields.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'addons/web_editor/static/src/js/backend') diff --git a/addons/web_editor/static/src/js/backend/fields.js b/addons/web_editor/static/src/js/backend/fields.js index cfa88e02f6e..1042c0ae0b4 100644 --- a/addons/web_editor/static/src/js/backend/fields.js +++ b/addons/web_editor/static/src/js/backend/fields.js @@ -136,7 +136,7 @@ var FieldTextHtmlSimple = basic_fields.DebouncedField.extend(TranslatableFieldMi ['color', ['color']], ['para', ['ul', 'ol', 'paragraph']], ['table', ['table']], - ['insert', ['link', 'picture']], + ['insert', this.nodeOptions['no-attachment'] ? ['link'] : ['link', 'picture']], ['history', ['undo', 'redo']] ], prettifyHtml: false, @@ -144,6 +144,7 @@ var FieldTextHtmlSimple = basic_fields.DebouncedField.extend(TranslatableFieldMi inlinemedia: ['p'], lang: "odoo", onChange: this._doDebouncedAction.bind(this), + disableDragAndDrop: !!this.nodeOptions['no-attachment'], }; var fieldNameAttachment =_.chain(this.recordData) -- cgit v1.2.3