projects
/
odoo
/
odoo.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
335e4a8
)
[FIX] website: catch exception on destroy of ckeditor to allow the modifications...
author
Jeremy Kersten
<jke@odoo.com>
Thu, 24 Jul 2014 16:12:32 +0000
(18:12 +0200)
committer
Jeremy Kersten
<jke@odoo.com>
Thu, 24 Jul 2014 16:12:32 +0000
(18:12 +0200)
addons/website/static/src/js/website.editor.js
patch
|
blob
|
history
diff --git
a/addons/website/static/src/js/website.editor.js
b/addons/website/static/src/js/website.editor.js
index
93d7542
..
a05c226
100644
(file)
--- a/
addons/website/static/src/js/website.editor.js
+++ b/
addons/website/static/src/js/website.editor.js
@@
-546,7
+546,13
@@
observer.disconnect();
var editor = this.rte.editor;
var root = editor.element.$;
- editor.destroy();
+ try {
+ editor.destroy();
+ }
+ catch(err) {
+ // Hack to avoid the lost of all changes because ckeditor fails in destroy
+ console.log("Error in editor.destroy() : " + err.toString() + "\n " + err.stack);
+ }
// FIXME: select editables then filter by dirty?
var defs = this.rte.fetch_editables(root)
.filter('.oe_dirty')