From 263e980817ef2a1f35ba3162eddb4fcbf267cff0 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Mon, 29 Jul 2019 09:10:40 +0000 Subject: [PATCH] [FIX] website: restore folded ul option The option which allows to create foldable lists was not working anymore. Taking advantage of https://github.com/odoo/odoo/commit/62a234e6e21397986733152b448e89ee0353dcfb solves the issue. Note: the option should be improved a lot to be more beautiful / useful but this will be a master task. closes odoo/odoo#35249 Signed-off-by: Quentin Smetz (qsm) --- addons/website/static/src/js/editor/snippets.options.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/website/static/src/js/editor/snippets.options.js b/addons/website/static/src/js/editor/snippets.options.js index 16cfaa2f44a..c585241281b 100644 --- a/addons/website/static/src/js/editor/snippets.options.js +++ b/addons/website/static/src/js/editor/snippets.options.js @@ -425,7 +425,9 @@ options.registry.ul = options.Class.extend({ toggleClass: function () { this._super.apply(this, arguments); - this.$target.data('snippet-view').destroy(); + this.trigger_up('animation_stop_demand', { + $target: this.$target, + }); this.$target.find('.o_ul_toggle_self, .o_ul_toggle_next').remove(); this.$target.find('li:has(>ul,>ol)').map(function () {