diff options
| author | Nicolas Lempereur <nle@odoo.com> | 2021-02-16 13:58:36 +0000 |
|---|---|---|
| committer | Nicolas Lempereur <nle@odoo.com> | 2021-02-16 14:02:42 +0000 |
| commit | 5324f7a6aa757ff6a728258ea1877ded4a6f86cd (patch) | |
| tree | 0605adf1cb8071b3e23c80fcc9f2a22ae848a7e7 /addons/web_editor | |
| parent | 329f65df4dbf3d6d67c563d5d3b902f2c60343f7 (diff) | |
[FIX] web_editor: stop loading button once ace saved
When we edit a view with ace in eg. studio, if it works the saved button
would never be enabled again because of missing callback.
Match the behavior of dom.addButtonLoadingEffect other usage (80592abd).
opw-2457046
closes odoo/odoo#66269
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Diffstat (limited to 'addons/web_editor')
| -rw-r--r-- | addons/web_editor/static/src/js/common/ace.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/web_editor/static/src/js/common/ace.js b/addons/web_editor/static/src/js/common/ace.js index 769b4f33023..439a27d55cc 100644 --- a/addons/web_editor/static/src/js/common/ace.js +++ b/addons/web_editor/static/src/js/common/ace.js @@ -914,7 +914,7 @@ var ViewEditor = Widget.extend({ */ _onSaveClick: function (ev) { const restore = dom.addButtonLoadingEffect(ev.currentTarget); - this._saveResources().guardedCatch(restore); + this._saveResources().then(restore).guardedCatch(restore); }, /** * Called when the user wants to switch from xml to scss or vice-versa -> |
