diff options
| author | Antoine Guenet <age@odoo.com> | 2019-03-08 11:57:09 +0000 |
|---|---|---|
| committer | Antoine Guenet <age@odoo.com> | 2019-03-18 09:32:14 +0000 |
| commit | becfef8f7bb885da6ceff437f68bb6d43e59efce (patch) | |
| tree | bd35b7472a78e670e3f077188c558442055bedea /addons/website/static/src/js/tours | |
| parent | 7e96d485c7d91e5fcb3ee59c71ecb5d76827298f (diff) | |
[FIX] web_editor: properly start website edit mode as restricted editor
It was impossible to open the website's edit mode as a user with
"restricted editor" permissions. The reason was that wysiwyg_multizone
was trying to manipulate data that is not injected into the html node
when `editable` is false (see `website.layout` template).
closes odoo/odoo#31702
Signed-off-by: Pierre Paridans <pparidans@users.noreply.github.com>
Diffstat (limited to 'addons/website/static/src/js/tours')
| -rw-r--r-- | addons/website/static/src/js/tours/restricted_editor.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/addons/website/static/src/js/tours/restricted_editor.js b/addons/website/static/src/js/tours/restricted_editor.js new file mode 100644 index 00000000000..10f24291be8 --- /dev/null +++ b/addons/website/static/src/js/tours/restricted_editor.js @@ -0,0 +1,17 @@ +odoo.define("website.tour.restricted_editor", function (require) { +"use strict"; + +var tour = require("web_tour.tour"); + +tour.register("restricted_editor", { + test: true, + url: "/", +}, [{ + trigger: 'a[data-action=edit]', + content: "Click \"EDIT\" button of website as Restricted Editor", + extra_trigger: ".homepage", +}, { + trigger: '#oe_snippets.o_loaded', + content: "Check that the snippets loaded properly", +}]); +}); |
