summaryrefslogtreecommitdiff
path: root/addons/website_crm/static
diff options
context:
space:
mode:
authorXavier Morel <xmo@odoo.com>2015-09-04 09:30:23 +0200
committerXavier Morel <xmo@odoo.com>2015-09-04 12:59:27 +0200
commit4d44b33ffea0358d3c700a85b48e5eae5224af84 (patch)
treeb51cbb66b57259850634b43d1feb1202f451ff79 /addons/website_crm/static
parent3658a894bc75724a5b976f3dc1200623e845cb3c (diff)
[IMP] crm & hr_recruitment tours: remove unnecessary tours
To check for result of a tour, would run a second tour performing JSON-RPC calls to check if the first tour had correctly impacted the database. Tours are expensive, an empty tour takes ~6s without doing anything. Replace second tour by regular ORM calls.
Diffstat (limited to 'addons/website_crm/static')
-rw-r--r--addons/website_crm/static/src/js/website_crm_tour.js45
1 files changed, 1 insertions, 44 deletions
diff --git a/addons/website_crm/static/src/js/website_crm_tour.js b/addons/website_crm/static/src/js/website_crm_tour.js
index e17c0dafac6..576d5e6c6c9 100644
--- a/addons/website_crm/static/src/js/website_crm_tour.js
+++ b/addons/website_crm/static/src/js/website_crm_tour.js
@@ -42,7 +42,7 @@ odoo.define('website_crm.tour', function(require) {
{
title: "Complete Subject",
element: "textarea[name=description]",
- sampleText: "Even more useless message"
+ sampleText: "### TOUR DATA ###"
},
{
title: "Send the form",
@@ -54,49 +54,6 @@ odoo.define('website_crm.tour', function(require) {
}
]
});
-
- Tour.register({
- id: 'website_crm_tour_results',
- name: "Test the contact us form created records",
- path: '',
- mode: 'test',
- steps: [
- {
- title: "Check crm.lead record has been created",
- waitFor: ".o-apps",
- onload: function (tour) {
- var leadDef = new Model("crm.lead").call(
- "search_read",
- [
- [
- ['contact_name', '=' , 'John Smith'],
- ['phone' , '=' , '118.218'],
- ['email_from' , '=' , 'john@smith.com'],
- ['partner_name', '=' , 'Odoo S.A.'],
- ['name' , '=' , 'Useless message'],
- ['description' , 'like', 'Even more useless message']
- ],
- []
- ]
- );
- var success = function(model, data) {
- if(data.length) {
- $('body').append('<div id="website_form_success_test_tour_'+model+'"></div>');
- }
- };
- leadDef.then(_.bind(success, this, 'crm_lead'));
- }
- },
- {
- title: "Check crm.lead record has been created",
- waitFor: "#website_form_success_test_tour_crm_lead"
- },
- {
- title: "Final Step",
- waitFor: "html"
- }
- ]
- });
});
return {};