From e244fa23ade0944d578e2b843eed856e1c327d57 Mon Sep 17 00:00:00 2001 From: Gorash Date: Mon, 6 May 2019 10:32:42 +0000 Subject: [PATCH] [FIX] web_editor: drop an image in the 'mail.compose.message' modal Issue: Can not drop an image into the modal's editor because the server request a positional res_id arguments. closes odoo/odoo#33232 Signed-off-by: Pierre Paridans --- addons/web_editor/static/src/js/wysiwyg/plugin/dropzone.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web_editor/static/src/js/wysiwyg/plugin/dropzone.js b/addons/web_editor/static/src/js/wysiwyg/plugin/dropzone.js index 3990ce4208e..d3dc044c005 100644 --- a/addons/web_editor/static/src/js/wysiwyg/plugin/dropzone.js +++ b/addons/web_editor/static/src/js/wysiwyg/plugin/dropzone.js @@ -150,7 +150,7 @@ var DropzonePlugin = Plugins.dropzone.extend({ route: '/web_editor/add_image_base64', params: { res_model: options.res_model, - res_id: options.res_id, + res_id: options.res_id || 0, image_base64: imageBase64.split(';base64,').pop(), filename: fileName, },