From fd9d9ce171c01d6e3ed985528e393dee7c0b67da Mon Sep 17 00:00:00 2001 From: Aaron Bohy Date: Tue, 5 Jul 2016 08:47:34 +0200 Subject: [PATCH] [FIX] crm, project, sale: make tours work in community The step consisting to go back to the app switcher doesn't work in community, obviously, so this commit make it active in enterprise only. Also make the Settings app selector more robust by accessing it through its xmlid, as we do for other apps and menus. --- addons/crm/data/tour_data.xml | 3 +++ addons/crm/static/src/js/tour.js | 3 ++- addons/project/static/src/js/tour.js | 3 ++- addons/project/views/tour_views.xml | 3 +++ addons/sale/static/src/js/tour.js | 3 ++- addons/sale/tour_view.xml | 3 +++ 6 files changed, 15 insertions(+), 3 deletions(-) diff --git a/addons/crm/data/tour_data.xml b/addons/crm/data/tour_data.xml index 1af27969465..f274a2ec169 100644 --- a/addons/crm/data/tour_data.xml +++ b/addons/crm/data/tour_data.xml @@ -4,4 +4,7 @@ + + + diff --git a/addons/crm/static/src/js/tour.js b/addons/crm/static/src/js/tour.js index 4da2586bc07..48cf6b11958 100644 --- a/addons/crm/static/src/js/tour.js +++ b/addons/crm/static/src/js/tour.js @@ -51,9 +51,10 @@ tour.register('crm_tour', [{ }, { trigger: ".o_main_navbar .o_menu_toggle", content: _t('Click the Home icon to navigate across apps.'), + edition: "enterprise", position: "bottom" }, { - trigger: ".o_apps .o_app:last", + trigger: '.o_app[data-menu-xmlid="base.menu_administration"], .oe_menu_toggler[data-menu-xmlid="base.menu_administration"]', content: _t("Configuration options are available in the Settings app."), position: "bottom" }, { diff --git a/addons/project/static/src/js/tour.js b/addons/project/static/src/js/tour.js index b50e6a10cec..44d82251ed4 100644 --- a/addons/project/static/src/js/tour.js +++ b/addons/project/static/src/js/tour.js @@ -71,9 +71,10 @@ tour.register('project_tour', [{ }, { trigger: ".o_main_navbar .o_menu_toggle", content: _t('Click the Home icon to navigate across apps.'), + edition: "enterprise", position: "bottom" }, { - trigger: ".o_apps .o_app:last", + trigger: '.o_app[data-menu-xmlid="base.menu_administration"], .oe_menu_toggler[data-menu-xmlid="base.menu_administration"]', content: _t("Configuration options are available in the Settings app."), position: "bottom" }, { diff --git a/addons/project/views/tour_views.xml b/addons/project/views/tour_views.xml index afd0c089d93..541c4e0f251 100644 --- a/addons/project/views/tour_views.xml +++ b/addons/project/views/tour_views.xml @@ -7,4 +7,7 @@ + + + diff --git a/addons/sale/static/src/js/tour.js b/addons/sale/static/src/js/tour.js index 93be459b890..6c2e037a592 100644 --- a/addons/sale/static/src/js/tour.js +++ b/addons/sale/static/src/js/tour.js @@ -32,9 +32,10 @@ tour.register('sale_tour', [{ }, { trigger: ".o_main_navbar .o_menu_toggle", content: _t('Click the Home icon to navigate across apps.'), + edition: "enterprise", position: "bottom" }, { - trigger: ".o_apps .o_app:last", + trigger: '.o_app[data-menu-xmlid="base.menu_administration"], .oe_menu_toggler[data-menu-xmlid="base.menu_administration"]', content: _t("Configuration options are available in the Settings app."), position: "bottom" }, { diff --git a/addons/sale/tour_view.xml b/addons/sale/tour_view.xml index 46bf5241960..447ed474eab 100644 --- a/addons/sale/tour_view.xml +++ b/addons/sale/tour_view.xml @@ -7,4 +7,7 @@ + + +