diff --git a/addons/web_editor/static/src/js/wysiwyg/widgets/link_tools.js b/addons/web_editor/static/src/js/wysiwyg/widgets/link_tools.js index 9d1ecbfbafc..e7abba60cf7 100644 --- a/addons/web_editor/static/src/js/wysiwyg/widgets/link_tools.js +++ b/addons/web_editor/static/src/js/wysiwyg/widgets/link_tools.js @@ -45,7 +45,6 @@ const LinkTools = Link.extend({ * @override */ start: function () { - this.options.wysiwyg.odooEditor.observerUnactive(); this.$link.addClass('oe_edited_link'); this.$button.addClass('active'); return this._super(...arguments); @@ -60,7 +59,6 @@ const LinkTools = Link.extend({ $contents.unwrap(); } this.$button.removeClass('active'); - this.options.wysiwyg.odooEditor.observerActive(); this.applyLinkToDom(this._getData()); if (!this.options.wysiwyg.odooEditor.isDestroyed) { this.options.wysiwyg.odooEditor.historyStep(); @@ -71,9 +69,7 @@ const LinkTools = Link.extend({ applyLinkToDom() { this._observer.disconnect(); - this.options.wysiwyg.odooEditor.observerActive(); this._super(...arguments); - this.options.wysiwyg.odooEditor.observerUnactive(); this._observer.observe(this._link, {subtree: true, childList: true, characterData: true}); }, diff --git a/addons/website/static/tests/tours/website_form_editor.js b/addons/website/static/tests/tours/website_form_editor.js index c3ff35ad6f7..ef1648231b8 100644 --- a/addons/website/static/tests/tours/website_form_editor.js +++ b/addons/website/static/tests/tours/website_form_editor.js @@ -136,10 +136,6 @@ odoo.define('website.tour.form_editor', function (require) { { content: "Form has a model name", trigger: 'section.s_website_form form[data-model_name="mail.mail"]', - }, { - content: "Complete Recipient E-mail", - trigger: '[data-field-name="email_to"] input', - run: 'text_blur test@test.test', }, { content: 'Edit the Phone Number field', trigger: 'input[name="phone"]', @@ -348,7 +344,34 @@ odoo.define('website.tour.form_editor', function (require) { { content: 'Verify that the value has not been deleted', trigger: '.s_website_form_field:eq(0) input[value="John Smith"]', - } + }, + { + content: 'Enter in edit mode again', + trigger: 'a[data-action="edit"]', + run: 'click', + }, + { + content: 'Click on the submit button', + trigger: '.s_website_form_send', + extra_trigger: 'button[data-action="save"]', + run: 'click', + }, + { + content: 'Change the Recipient Email', + trigger: '[data-field-name="email_to"] input', + run: 'text test@test.test', + }, + { + content: 'Save the page', + trigger: 'button[data-action=save]', + run: 'click', + }, + { + content: 'Verify that the recipient email has been saved', + trigger: 'body:not(.editor_enable)', + // We have to this that way because the input type = hidden. + extra_trigger: 'form:has(input[name="email_to"][value="test@test.test"])', + }, ]); tour.register("website_form_editor_tour_submit", {