From 3751379f1e9a4c215fb6eb898b4ccc67659b9ace Mon Sep 17 00:00:00 2001 From: stephanchrst Date: Tue, 10 May 2022 21:51:50 +0700 Subject: initial commit 2 --- .../static/src/js/tours/crm_iap_lead.js | 41 ++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 addons/crm_iap_lead/static/src/js/tours/crm_iap_lead.js (limited to 'addons/crm_iap_lead/static/src/js/tours') diff --git a/addons/crm_iap_lead/static/src/js/tours/crm_iap_lead.js b/addons/crm_iap_lead/static/src/js/tours/crm_iap_lead.js new file mode 100644 index 00000000..577b6cd1 --- /dev/null +++ b/addons/crm_iap_lead/static/src/js/tours/crm_iap_lead.js @@ -0,0 +1,41 @@ +odoo.define('crm_iap_lead.generate_leads_steps', function (require) { +"use strict"; + +var tour = require('web_tour.tour'); +var core = require('web.core'); + +require('crm.tour'); +var _t = core._t; + +var DragOppToWonStepIndex = _.findIndex(tour.tours.crm_tour.steps, function (step) { + return (step.id === 'drag_opportunity_to_won_step'); +}); + +tour.tours.crm_tour.steps.splice(DragOppToWonStepIndex + 1, 0, { + /** + * Add some steps between "Drag your opportunity to Won when you get + * the deal. Congrats !" and "Let’s have a look at an Opportunity." to + * include the steps related to the lead generation (crm_iap_lead). + * This eases the on boarding for the Lead Generation process. + * + */ + trigger: ".o_button_generate_leads", + content: _t("Looking for more opportunities ?
Try the Lead Generation tool."), + position: "bottom", + run: function (actions) { + actions.auto('.o_button_generate_leads'); + }, +}, { + trigger: '.modal-body .o_industry', + content: _t("Which Industry do you want to target?"), + position: "right", +}, { + trigger: '.modal-footer button[name=action_submit]', + content: _t("Now, just let the magic happen!"), + position: "bottom", + run: function (actions) { + actions.auto('.modal-footer button[special=cancel]'); +} +}); + +}); \ No newline at end of file -- cgit v1.2.3