From 3247400291145de4896972d8b06e768554b8cdd2 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Tue, 5 Jul 2016 12:34:53 +0200 Subject: [PATCH] [IMP] website(_*): tours * Adapt modals for new pages/product/... to leave some space for tour tips on the right * Remove the "click on add page" step which was the start of each tours and leave it to be the last of the website tour * Change position of some tips * Remove step "click on parent button" in website tour as it is not necessary anymore * Remove the possibility to skip the frontend tours --- addons/website/static/src/js/website.tour.banner.js | 11 +++-------- addons/website/static/src/xml/website.xml | 2 +- .../website_blog/static/src/js/website.tour.blog.js | 9 ++------- .../website_event/static/src/js/website.tour.event.js | 9 ++------- .../website_forum/static/src/js/website_tour_forum.js | 9 ++------- .../static/src/js/website_sale_tour_shop.js | 9 ++------- 6 files changed, 12 insertions(+), 37 deletions(-) diff --git a/addons/website/static/src/js/website.tour.banner.js b/addons/website/static/src/js/website.tour.banner.js index 5b922fa26d2..9ca3b626fd8 100644 --- a/addons/website/static/src/js/website.tour.banner.js +++ b/addons/website/static/src/js/website.tour.banner.js @@ -115,8 +115,7 @@ odoo.define("website.tour.banner", function (require) { }); tour.register("banner", { - skip_enabled: true, - url: "/page/homepage?debug=assets", + url: "/", }, [{ trigger: "a[data-action=edit]", content: _t("Every page of your website can be modified through the Edit button."), @@ -132,15 +131,11 @@ odoo.define("website.tour.banner", function (require) { content: _t("Click in the title text and start editing it."), position: "left", run: "text", - }, { - trigger: ".oe_snippet_parent", - extra_trigger: "#wrapwrap .s_text_block_image_fw h2:not(:containsExact(\"Headline\"))", - content: _t("Select the parent container to get the global options of the banner."), - position: "left", }, { trigger: ".oe_overlay_options .oe_options", + extra_trigger: "#wrapwrap .s_text_block_image_fw h2:not(:containsExact(\"Headline\"))", content: _t("Customize any block through this menu. Try to change the background of the banner."), - position: "right", + position: "bottom", }, { trigger: "#snippet_structure .oe_snippet:eq(6) .oe_snippet_thumbnail", content: _t("Drag the \"Features\" block and drop it below the banner."), diff --git a/addons/website/static/src/xml/website.xml b/addons/website/static/src/xml/website.xml index ac94e7ba7dd..83cda18373f 100644 --- a/addons/website/static/src/xml/website.xml +++ b/addons/website/static/src/xml/website.xml @@ -21,7 +21,7 @@ -
+
diff --git a/addons/website_blog/static/src/js/website.tour.blog.js b/addons/website_blog/static/src/js/website.tour.blog.js index 83dc4e22ddd..c9a6e0c9a2d 100644 --- a/addons/website_blog/static/src/js/website.tour.blog.js +++ b/addons/website_blog/static/src/js/website.tour.blog.js @@ -129,16 +129,11 @@ odoo.define("website_blog.tour", function (require) { }); tour.register("blog", { - skip_enabled: true, - url: "/blog", + url: "/", }, [{ - trigger: "#oe_main_menu_navbar a[data-action=new_page]", - content: _t("Use this button to create a new blog post like any other document (page, menu, products, event, ...)."), - position: "bottom", - }, { trigger: "a[data-action=new_blog_post]", content: _t("Select this menu item to create a new blog post."), - position: "left", + position: "bottom", }, { trigger: "h1[data-oe-expression=\"blog_post.name\"]", content: _t("Write a title, the subtitle is optional."), diff --git a/addons/website_event/static/src/js/website.tour.event.js b/addons/website_event/static/src/js/website.tour.event.js index 4681b635ba8..3013c62d726 100644 --- a/addons/website_event/static/src/js/website.tour.event.js +++ b/addons/website_event/static/src/js/website.tour.event.js @@ -88,16 +88,11 @@ odoo.define("website_event.tour", function (require) { }); tour.register("event", { - skip_enabled: true, - url: "/event", + url: "/", }, [{ - trigger: "#oe_main_menu_navbar a[data-action=new_page]", - content: _t("This button allows you to create new pages, events, menus, etc."), - position: "bottom", - }, { trigger: "a[data-action=new_event]", content: _t("Click here to create a new event."), - position: "left", + position: "bottom", }, { trigger: ".modal-dialog #editor_new_event input[type=text]", content: _t("Create a name for your new event and click \"Continue\". e.g: Technical Training"), diff --git a/addons/website_forum/static/src/js/website_tour_forum.js b/addons/website_forum/static/src/js/website_tour_forum.js index e6333ac532e..d0d2f2e8d85 100644 --- a/addons/website_forum/static/src/js/website_tour_forum.js +++ b/addons/website_forum/static/src/js/website_tour_forum.js @@ -130,16 +130,11 @@ odoo.define("website_forum.tour_forum", function (require) { }); tour.register("question", { - skip_enabled: true, - url: "/forum", + url: "/", }, [{ - trigger: "#oe_main_menu_navbar a[data-action=new_page]", - content: _t("Use this button to create a new forum like any other document (page, menu, products, event, ...)."), - position: "bottom", - }, { trigger: "a[data-action=new_forum]", content: _t("Select this menu item to create a new forum."), - position: "left", + position: "bottom", }, { trigger: "#editor_new_forum input[type=text]", content: _t("Enter a name for your new forum."), diff --git a/addons/website_sale/static/src/js/website_sale_tour_shop.js b/addons/website_sale/static/src/js/website_sale_tour_shop.js index 775be1ca7c6..e158e795219 100644 --- a/addons/website_sale/static/src/js/website_sale_tour_shop.js +++ b/addons/website_sale/static/src/js/website_sale_tour_shop.js @@ -116,16 +116,11 @@ odoo.define("website_sale.tour_shop", function (require) { }); tour.register("shop", { - skip_enabled: true, - url: "/shop", + url: "/", }, [{ - trigger: "#oe_main_menu_navbar a[data-action=new_page]", - content: _t("You successfully installed the e-commerce.
Click here to add a new product."), - position: "bottom", - }, { trigger: "a[data-action=new_product]", content: _t("Select New Product to create it and manage its properties to boost your sales."), - position: "left", + position: "bottom", }, { trigger: ".modal-dialog #editor_new_product input[type=text]", content: _t("Enter a name for your new product"),