4 var website = openerp.website;
6 var render = website.tour.render;
8 website.EditorBuilderTour = website.EditorTour.extend({
10 name: "Add a new page",
11 init: function (editor) {
13 var $body = $(document.body);
16 stepId: 'welcome-menu-editor',
20 content: "We will show how to edit your website's menu.",
21 template: render('website.tour_popover', { next: "Start Tutorial", end: "Skip It" }),
24 stepId: 'content-menu',
25 element: '#content-menu-button',
28 title: "Edit the content",
29 content: "Click here to edit the menu.",
30 template: render('website.tour_popover'),
34 element: 'a[data-action=edit-structure]',
37 content: "Click here to create a new menu entry and manage options.",
38 template: render('website.tour_popover'),
40 editor.on('tour:menu_editor_dialog_ready', editor, function () {
41 self.movetoStep('add-menu-entry');
46 stepId: 'add-menu-entry',
47 element: 'a.js_add_menu',
49 title: "Add menu entry",
50 content: "Click here to create a new menu entry.",
51 template: render('website.tour_popover'),
53 editor.on('tour:new_menu_entry_dialog_ready', editor, function () {
54 self.movetoStep('enter-entry-name');
59 stepId: 'enter-entry-name',
60 element: '#link-text',
62 title: "Choose a label",
63 content: "This label will appear in the top menu and will be visible by all your audience.\nGive a meaningful name to help your visitors. For instance, 'Photos Gallery'.",
64 template: render('website.tour_popover', { next: "Continue" }),
67 stepId: 'enter-page-name',
70 title: "Link your menu to a 'gallery' page",
71 content: "This page does not exist. Create it by filling the name here. For instance, 'gallery'.",
72 template: render('website.tour_popover', { next: "Continue" }),
76 element: '.modal-footer:last button.btn-primary',
78 title: "Save the page",
79 content: "Save your new page.",
80 template: render('website.tour_popover'),
82 editor.on('tour:new_menu_entry_dialog_closed', editor, function () {
83 self.movetoStep('save-menu');
89 element: '.modal-footer button.btn-primary',
92 title: "Save the menu",
93 content: "Save the menu to edit the Gallery content directly from the interface.",
94 template: render('website.tour_popover'),
101 website.EditorBar.include({
103 this.registerTour(new website.EditorBuilderTour(this));
104 return this._super();