From d41ed40c70faa9b30144c070a06fe2f07f15084b Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Fri, 2 Sep 2016 11:11:54 +0100 Subject: [IMP] web, website: adapt tour launching to new system * The debug manager contains a feature to launch tours, adapt it to new web_tour.tour system * The website help menu allowed to relaunch tutorial tour in debug mode. This feature is not adapted to new tour system and was useless in the first place (debug mode in frontend is barely used anyway). -> remove the website help menu and the feature --- addons/web_tour/static/src/js/debug_manager.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'addons/web_tour/static/src/js/debug_manager.js') diff --git a/addons/web_tour/static/src/js/debug_manager.js b/addons/web_tour/static/src/js/debug_manager.js index 3e23207462c..70f323de3bb 100644 --- a/addons/web_tour/static/src/js/debug_manager.js +++ b/addons/web_tour/static/src/js/debug_manager.js @@ -1,7 +1,9 @@ odoo.define('web_tour.DebugManager', function (require) { "use strict"; +var core = require("web.core"); var DebugManager = require('web.DebugManager'); +var Dialog = require("web.Dialog"); var Model = require('web.Model'); var tour = require('web_tour.tour'); @@ -23,6 +25,19 @@ DebugManager.include({ }); } }, + start_tour: function() { + var dialog = new Dialog(this, { + title: 'Tours', + $content: core.qweb.render('WebClient.DebugManager.ToursDialog', { + tours: tour.tours + }), + }).open(); + + dialog.$('.o_start_tour').on('click', function(e) { + e.preventDefault(); + tour.run($(e.target).data('name')); + }); + }, }); }); -- cgit v1.2.3