0f89c449c69399b71f3b1ff66cb8cc55ba7c1397
[odoo/odoo.git] / addons / website / views / website_templates.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <!-- vim:fdn=3:
3 -->
4 <openerp>
5     <data>
6
7 <!-- Layout and generic templates -->
8
9 <template id="website.theme" name="Theme">
10     <link id="bootstrap_css" rel='stylesheet' href='/web/static/lib/bootstrap/css/bootstrap.css' t-ignore="true"/>
11     <link id="website_css" rel='stylesheet' href='/website/static/src/css/website.css' t-ignore="true"/>
12 </template>
13
14 <template id="website.submenu" name="Submenu">
15     <li t-if="not submenu.child_id" t-att-class="
16         ((submenu.url != '/' and request.httprequest.path.startswith(submenu.url)) or
17          request.httprequest.path == submenu.url) and 'active'
18         ">
19         <a t-att-href="(website.menu_id.child_id[0] == submenu) and '/' or submenu.url" t-ignore="true" t-att-target="'blank' if submenu.new_window else None">
20             <span t-field="submenu.name"/>
21         </a>
22     </li>
23     <li t-if="submenu.child_id" t-attf-class="dropdown #{
24         ((submenu.url != '/' and [1 for submenu in submenu.child_id if request.httprequest.path.startswith(submenu.url)]) or
25          request.httprequest.path == submenu.url) and 'active'
26         }">
27         <a class="dropdown-toggle" data-toggle="dropdown" href="#">
28             <span t-field="submenu.name"/> <span class="caret" t-ignore="true"></span>
29         </a>
30         <ul class="dropdown-menu" role="menu">
31             <t t-foreach="submenu.child_id" t-as="submenu">
32                 <t t-call="website.submenu"/>
33             </t>
34         </ul>
35     </li>
36 </template>
37
38 <template id="layout" name="Main layout">&lt;!DOCTYPE html&gt;
39     <html t-att-lang="lang and lang.replace('_', '-')"
40           t-att-data-website-id="website.id if editable else None"
41           t-att-data-editable="'1' if editable else None"
42           t-att-data-translatable="'1' if translatable else None"
43           t-att-data-view-xmlid="xmlid if editable else None"
44           t-att-data-main-object="repr(main_object) if editable else None"
45           t-att-data-oe-company-name="res_company.name">
46         <head>
47             <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
48             <script type="text/javascript" src="/web/static/src/js/watch.js"></script>
49             <t t-if="main_object and 'website_meta_title' in main_object">
50                 <t t-set="title" t-value="main_object.website_meta_title"/>
51             </t>
52             <t t-if="not title and main_object and 'name' in main_object">
53                 <t t-set="additional_title" t-value="main_object.name"/>
54             </t>
55             <t t-if="not title">
56                 <t t-set="title"><t t-raw="res_company.name"/><t t-if="additional_title"> - <t t-raw="additional_title"/></t></t>
57             </t>
58             <meta name="viewport" content="initial-scale=1"/>
59             <meta name="description" t-att-content="main_object and 'website_meta_description' in main_object
60                 and main_object.website_meta_description or website_meta_description"/>
61             <meta name="keywords" t-att-content="main_object and 'website_meta_keywords' in main_object
62                 and main_object.website_meta_keywords or website_meta_keywords"/>
63             <title><t t-esc="title"/></title>
64
65             <!-- Load stylesheets before scripts to avoid blocking -->
66             <link rel='stylesheet' href='/web/static/lib/fontawesome/css/font-awesome.css'/>
67
68             <t t-call="website.theme"/>
69
70             <script type="text/javascript" src="/web/static/lib/es5-shim/es5-shim.min.js"></script>
71             <script type="text/javascript" src="/web/static/lib/underscore/underscore.js"></script>
72             <script type="text/javascript" src="/web/static/lib/underscore.string/lib/underscore.string.js"></script>
73             <script type="text/javascript" src="/web/static/lib/jquery/jquery.js"></script>
74             <script type="text/javascript" src="/web/static/lib/jquery.form/jquery.form.js"></script>
75             <script type="text/javascript">
76                 // Bootstrap and jQuery UI conflicts
77                 $.fn.bstooltip = $.fn.tooltip;
78                 $.fn.bsbutton = $.fn.button;
79             </script>
80
81             <script type="text/javascript" src="/web/static/lib/qweb/qweb2.js"></script>
82             <script type="text/javascript" src="/web/static/src/js/openerpframework.js"></script>
83
84             <script type="text/javascript" src="/website/static/src/js/website.js"></script>
85
86             <script t-if="not translatable" type="text/javascript" src="/website/static/src/js/website.snippets.animation.js"></script>
87             <script type="text/javascript" src="/web/static/lib/bootstrap/js/bootstrap.js"></script>
88
89             <t t-raw="head or ''" name='layout_head'/>
90         </head>
91         <body>
92             <div id="wrapwrap">
93                 <header>
94                     <div class="navbar navbar-default navbar-static-top">
95                         <div class="container">
96                             <div class="navbar-header">
97                                 <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-top-collapse">
98                                     <span class="sr-only">Toggle navigation</span>
99                                     <span class="icon-bar"></span>
100                                     <span class="icon-bar"></span>
101                                     <span class="icon-bar"></span>
102                                 </button>
103                                 <a class="navbar-brand" href="/" t-field="res_company.name"/>
104                             </div>
105                             <div class="collapse navbar-collapse navbar-top-collapse">
106                                 <ul class="nav navbar-nav navbar-right" id="top_menu">
107                                     <t t-foreach="website.menu_id.child_id" t-as="submenu">
108                                         <t t-call="website.submenu"/>
109                                     </t>
110                                     <li class="divider" groups="base.group_user,base.group_portal" t-ignore="true"/>
111                                     <li class="dropdown" t-ignore="true" groups="base.group_user,base.group_portal">
112                                         <a href="#" class="dropdown-toggle" data-toggle="dropdown">
113                                             <b>
114                                                 <span t-esc="user_id.name"/>
115                                                 <span class="caret"></span>
116                                             </b>
117                                         </a>
118                                         <ul class="dropdown-menu js_usermenu" role="menu">
119                                             <li><a href="/web" role="menuitem">My Account</a></li>
120                                             <li class="divider"/>
121                                             <li><a t-attf-href="/web/session/logout?redirect=/" role="menuitem">Logout</a></li>
122                                         </ul>
123                                     </li>
124                                 </ul>
125                             </div>
126                         </div>
127                     </div>
128                 </header>
129                 <main>
130                     <t t-raw="0"/>
131                 </main>
132                 <footer>
133                     <div class="container hidden-print" id="footer_container">
134                         <div class="row">
135                             <div class="col-md-3" name="product">
136                                 <h4>Our products &amp; Services</h4>
137                                 <ul class="list-unstyled" name="products">
138                                     <li><a href="/">Home</a></li>
139                                 </ul>
140                             </div>
141                             <div class="col-md-3" name="info">
142                                 <h4 name="info_title">Connect with us</h4>
143                                 <ul class="list-unstyled">
144                                     <li><a href="/page/website.contactus">Contact us</a></li>
145                                 </ul>
146                                 <ul class="list-unstyled">
147                                     <li t-ignore="true"><i class="fa fa-phone"></i> <span t-field="res_company.phone"></span></li>
148                                     <li t-ignore="true"><i class="fa fa-envelope"></i>  <span t-field="res_company.email"></span></li>
149                                 </ul>
150                                 <h2>
151                                     <a t-att-href="website.social_facebook" t-if="website.social_facebook"><i class="fa fa-facebook-square"/></a>
152                                     <a t-att-href="website.social_twitter" t-if="website.social_twitter"><i class="fa fa-twitter"/></a>
153                                     <a t-att-href="website.social_linkedin" t-if="website.social_linkedin"><i class="fa fa-linkedin"/></a>
154                                     <a t-att-href="website.social_youtube" t-if="website.social_youtube"><i class="fa fa-youtube-play"/></a>
155                                     <a t-att-href="website.social_googleplus" t-if="website.social_googleplus"><i class="fa fa-google-plus-square"/></a>
156                                     <a t-att-href="website.social_github" t-if="website.social_github"><i class="fa fa-github"/></a>
157                                 </h2>
158                             </div>
159                             <div class="col-md-5 col-lg-offset-1">
160                                 <div>
161                                     <h4>
162                                         <span t-field="res_company.name">Your Company</span>
163                                         <small> - <a href="/page/website.aboutus">About us</a></small>
164                                     </h4>
165                                     <p>
166                                         We are a team of passionate people whose goal is to improve everyone's
167                                         life through disruptive products. We build great products to solve your
168                                         business problems.
169                                     </p>
170                                     <p>
171                                         Our products are designed for small to medium size companies willing to optimize
172                                         their performance.
173                                     </p>
174                                 </div>
175                                 <t t-set="languages" t-value="website.get_languages()"/>
176                                 <ul class="list-inline js_language_selector mt16" t-if="(len(languages) &gt; 1 or editable)">
177                                     <li t-foreach="languages" t-as="lg">
178                                         <a t-att-href="url_for('', lang=lg[0]) + '?' + keep_query()"
179                                            t-att-data-default-lang="editable and 'true' if lg[0] == website.default_lang_code else None">
180                                             <t t-esc="lg[1].split('/').pop()"/>
181                                         </a>
182                                     </li>
183                                     <li groups="base.group_website_publisher">
184                                         <t t-set="url_return" t-value="url_for('', '[lang]') + '?' + keep_query()"/>
185                                         <a t-attf-href="/web#action=base.action_view_base_language_install&amp;website_id=#{website.id}&amp;url_return=#{url_return}">
186                                             <i class="fa fa-plus-circle"/>
187                                             Add a language...
188                                         </a>
189                                     </li>
190                                 </ul>
191                             </div>
192                         </div>
193                     </div>
194                     <div class="container mt16 mb8">
195                         <div class="pull-right" t-ignore="true" t-if="not editable">
196                             Create a <a href="http://openerp.com/apps/website">free website</a> with
197                             <a class="label label-danger" href="https://openerp.com/apps/website">OpenERP</a>
198                         </div>
199                         <div class="pull-left text-muted">
200                             Copyright &amp;copy; <span t-field="res_company.name">Company name</span>
201                         </div>
202                     </div>
203                 </footer>
204             </div>
205             <t t-if="website.google_analytics_key">
206                 <script>
207                     (function(b,o,i,l,e,r){b.GoogleAnalyticsObject=l;b[l]||(b[l]=
208                     function(){(b[l].q=b[l].q||[]).push(arguments)});b[l].l=+new Date;
209                     e=o.createElement(i);r=o.getElementsByTagName(i)[0];
210                     e.src='//www.google-analytics.com/analytics.js';
211                     r.parentNode.insertBefore(e,r)}(window,document,'script','ga'));
212                     ga('create','<t t-esc="website.google_analytics_key"/>');ga('send','pageview');
213                 </script>
214             </t>
215         </body>
216     </html>
217 </template>
218
219 <template id="layout_logo_show" inherit_id="website.layout" inherit_option_id="website.layout" name="Show Logo">
220     <xpath expr="//header//a[@class='navbar-brand']" position="replace">
221         <a href="/" class="navbar-brand logo">
222             <img src="/logo.png"/>
223         </a>
224     </xpath>
225 </template>
226
227 <template id="editor_head" inherit_id="website.layout" name="Editor" groups="base.group_website_publisher">
228     <xpath expr="//body" position="attributes">
229         <attribute name="style">padding-top: 51px;</attribute>
230     </xpath>
231     <xpath expr="//body" position="inside">
232         <div id="website-top-navbar-placeholder" class="navbar navbar-inverse navbar-fixed-top hidden-xs">
233             <div class="navbar-header">
234                 <form class="navbar-form navbar-left">
235                     <button type="button" class="btn btn-primary">Edit</button>
236                 </form>
237             </div>
238             <div class="collapse navbar-collapse navbar-edit-collapse">
239                 <ul class="nav navbar-nav navbar-right">
240                     <li><a href="#" onclick="return false;"><i class="fa fa-mobile" title="Mobile preview"/></a></li>
241                     <li class="divider-vertical"/>
242                     <li><a href="#" onclick="return false;"><span title="Promote page on the web">Promote</span></a></li>
243                     <li class="dropdown">
244                         <a href="#" onclick="return false;">Content <span class="caret"/></a>
245                     </li>
246                     <li class="dropdown">
247                         <a href="#" onclick="return false;">Customize <span class="caret"/></a>
248                     </li>
249                     <li class="dropdown">
250                         <a href="#" onclick="return false;">Help <span class="caret"/></a>
251                     </li>
252                 </ul>
253             </div>
254         </div>
255     </xpath>
256     <xpath expr='//script[@src="/web/static/lib/bootstrap/js/bootstrap.js"]' position="before">
257         <link rel='stylesheet' href='/website/static/src/css/snippets.css'/>
258         <link rel='stylesheet' href='/website/static/src/css/editor.css'/>
259         <link rel='stylesheet' href='/website/static/lib/bootstrap-tour/bootstrap-tour.css'/>
260
261
262         <link rel="stylesheet" href="/web/static/lib/select2/select2.css"/>
263         <link rel="stylesheet" href="/website/static/lib/select2-bootstrap-css/select2-bootstrap.css"/>
264         <link rel='stylesheet' href="/web/static/lib/jquery.ui/css/smoothness/jquery-ui-1.9.1.custom.css"/>
265
266         <script type="text/javascript" src="/web/static/lib/select2/select2.js"></script>
267         <script type="text/javascript" src="/web/static/lib/ckeditor/ckeditor.js"></script>
268         <script t-if="not translatable" type="text/javascript" src="/website/static/lib/ace/ace.js"></script>
269         <script type="text/javascript" src="/website/static/lib/vkbeautify/vkbeautify.0.99.00.beta.js"></script>
270         <script type="text/javascript" src="/web/static/lib/jquery.ui/js/jquery-ui-1.9.1.custom.js"></script>
271         <script type="text/javascript" src="/website/static/lib/bootstrap-tour/bootstrap-tour.js"></script>
272         <!-- mutation observers shim backed by mutation events (8 < IE < 11, Safari < 6, FF < 14, Chrome < 17) -->
273         <script type="text/javascript" src="/website/static/lib//jquery.mjs.nestedSortable/jquery.mjs.nestedSortable.js"></script>
274         <script type="text/javascript" src="/website/static/lib/MutationObservers/test/sidetable.js"></script>
275         <script type="text/javascript" src='/website/static/lib/nearest/jquery.nearest.js'></script>
276         <script type="text/javascript" src="/website/static/lib/MutationObservers/MutationObserver.js"></script>
277
278         <script type="text/javascript" src="/website/static/lib/jquery.placeholder/jquery.placeholder.js"></script>
279
280         <script type="text/javascript" src="/website/static/src/js/website.editor.js"></script>
281         <script type="text/javascript" src="/website/static/src/js/website.editor.newpage.js" groups="base.group_website_designer"></script>
282         <script type="text/javascript" src="/website/static/src/js/website.menu.js" groups="base.group_website_designer"></script>
283         <script type="text/javascript" src="/website/static/src/js/website.mobile.js"></script>
284         <script type="text/javascript" src="/website/static/src/js/website.seo.js"></script>
285         <script type="text/javascript" id="website_tour_js" src="/website/static/src/js/website.tour.js"></script>
286         <script type="text/javascript" src="/website/static/src/js/website.tour.banner.js" groups="base.group_website_designer"></script>
287         <script t-if="not translatable" type="text/javascript" src="/website/static/src/js/website.snippets.editor.js"></script>
288         <script t-if="not translatable" type="text/javascript" src="/website/static/src/js/website.ace.js"></script>
289         <script t-if="translatable" type="text/javascript" src="/website/static/src/js/website.translator.js"></script>
290
291         <script type="text/javascript" src="/website/static/src/js/jQuery.transfo.js"></script>
292     </xpath>
293 </template>
294
295 <template id="debugger" inherit_option_id="website.layout" name="Debugger &amp; Tests">
296     <xpath expr='//t[@name="layout_head"]' position="after">
297         <script type="text/javascript" src="/website/static/src/js/website.tour.js"></script>
298     </xpath>
299 </template>
300
301 <template id="login_layout" inherit_id="web.login_layout" name="Website Login Layout">
302     <xpath expr="t" position="replace">
303         <t t-call="website.layout">
304             <div class="oe_website_login_container" t-raw="0"/>
305         </t>
306     </xpath>
307 </template>
308
309 <template id="show_sign_in" inherit_option_id="website.layout" inherit_id="website.layout" name="Show Sign In" groups="base.group_public">
310     <xpath expr="//ul[@id='top_menu']" position="inside">
311         <li class="divider"/>
312         <li>
313             <a t-attf-href="/web/login">
314                 <b>Sign in</b>
315             </a>
316         </li>
317     </xpath>
318 </template>
319
320 <template id="footer_custom" inherit_option_id="website.layout" name="Custom Footer">
321     <xpath expr="//div[@id='footer_container']" position="before">
322         <div class="oe_structure">
323             <section data-snippet-id='three-columns' class="mt16 mb16">
324                 <div class="container">
325                     <div class="row">
326                         <div class="col-md-4">
327                             <h4 class="mt16">Subtitle</h4>
328                             <p>
329                                 <a href="/">Homepage</a>
330                             </p>
331                         </div>
332                         <div class="col-md-4">
333                             <h4 class="mt16">Subtitle 2</h4>
334                             <p>
335                                 ...
336                             </p>
337                         </div>
338                         <div class="col-md-4">
339                             <h4 class="mt16">Subtitle 3</h4>
340                             <p>
341                                 ...
342                             </p>
343                         </div>
344                     </div>
345                 </div>
346             </section>
347         </div>
348     </xpath>
349     <xpath expr="//div[@id='footer_container']" position="attributes">
350         <attribute name="style">display: none</attribute>
351     </xpath>
352 </template>
353
354 <template id="publish_management">
355     <div groups="base.group_website_publisher" t-ignore="true" class="pull-right css_editable_mode_hidden" t-att-style="style or ''">
356         <div t-attf-class="btn-group js_publish_management #{object.website_published and 'css_published' or 'css_unpublished'}" t-att-data-id="object.id" t-att-data-object="object._name" t-att-data-controller="publish_controller">
357             <button class="btn btn-danger js_publish_btn">Not Published</button>
358             <button class="btn btn-success js_publish_btn">Published</button>
359             <button type="button" t-attf-class="btn btn-default dropdown-toggle" t-att-id="'dopprod-%s' % object.id" data-toggle="dropdown">
360                 <span class="caret"></span>
361             </button>
362             <ul class="dropdown-menu" role="menu" t-att-aria-labelledby="'dopprod-%s' % object.id">
363                 <li>
364                     <a href="#" class="js_publish_btn">
365                         <span class="css_unpublish">Unpublish</span>
366                         <span class="css_publish">Publish</span>
367                     </a>
368                 </li>
369                 <t t-raw="0"/>
370                 <li t-if="publish_edit">
371                     <a t-attf-href="/web#return_label=Website&amp;view_type=form&amp;model=#{object._name}&amp;id=#{object.id}&amp;action=#{action}"
372                     title='Edit in backend'>Edit</a>
373                 </li>
374             </ul>
375         </div>
376     </div>
377 </template>
378
379 <template id="publish_short">
380     <t groups="base.group_website_publisher" t-ignore="true">
381         <div t-attf-class="btn-group pull-right js_publish_management #{object.website_published and 'css_published' or 'css_unpublished'}" t-att-data-id="object.id" t-att-data-object="object._name" t-att-data-controller="publish_controller">
382             <button t-attf-class="btn btn-sm btn-#{object.website_published and 'success' or 'danger'} js_publish_btn">
383                 <span class="css_publish">Not Published</span>
384                 <span class="css_unpublish">Published</span>
385             </button>
386         </div>
387     </t>
388 </template>
389
390 <template id="pager" name="Pager">
391     <ul t-if="pager['page_count'] > 1" t-attf-class="#{ classname or '' } pagination" t-att-style="style or ''">
392         <li t-att-class=" 'disabled' if pager['page']['num'] == 1 else '' ">
393             <a t-att-href=" pager['page_previous']['url'] if pager['page']['num'] != 1 else ''">Prev</a>
394         </li>
395         <t t-foreach="pager['pages']" t-as="page">
396             <li t-att-class=" 'active' if page['num'] == pager['page']['num'] else '' "> <a t-att-href="page['url']" t-raw="page['num']"></a></li>
397         </t>
398         <li t-att-class=" 'disabled' if pager['page']['num'] == pager['page_count'] else '' ">
399             <a t-att-href="pager['page_next']['url'] if pager['page']['num'] != pager['page_count'] else ''">Next</a>
400         </li>
401     </ul>
402 </template>
403
404 <template id="kanban">
405     <t t-set="step"><t t-esc="step or 0"/></t>
406     <t t-set="scope"><t t-esc="scope or 0"/></t>
407     <t t-set="orderby"><t t-esc="orderby or 'name'"/></t>
408     <t t-raw="website.kanban(model, domain, column, template, step=step, scope=scope, orderby=orderby)"/>
409 </template>
410
411 <template id="kanban_contain">
412     <table class="table js_kanban">
413         <thead>
414             <tr>
415                 <t t-set="width" t-value="str(round(100.0 / len(objects), 2)) + '%'"/>
416                 <t t-foreach="objects">
417                     <th t-att-width="width">
418                         <div t-field="column_id.name" class="text-center"></div>
419                     </th>
420                 </t>
421             </tr>
422         </thead>
423         <tbody>
424             <tr>
425                 <t t-foreach="objects">
426                     <td class="js_kanban_col" t-att-data-template="template" t-att-data-domain="domain" t-att-data-page_count="page_count" t-att-data-model="model" t-att-data-step="step" t-att-data-orderby="orderby">
427                         <t t-foreach="object_ids" t-as="object_id">
428                             <t t-call="#{ template }"></t>
429                         </t>
430                         <!-- pager -->
431                         <div t-if="1 != page_end" class="pagination pagination-centered">
432                             <ul>
433                                 <li t-attf-class="prev #{'active' if page == 1 else '' }"> <a t-att-href=" '%s,%s-%s' % (kanban_url, column_id.id, (page &gt; 1 and page-1 or 1)) ">Prev</a></li>
434                                 <t t-foreach="range(page_start, page_end+1)" t-as="p">
435                                     <li t-att-class=" 'active' if page == p else '' "> <a t-att-href=" '%s,%s-%s' % (kanban_url, column_id.id, p)" t-esc="p"></a></li>
436                                 </t>
437                                 <li t-attf-class="next #{'active' if page == page_end else '' }"> <a t-att-href=" '%s,%s-%s' % (kanban_url, column_id.id, (page &lt; page_end and page+1 or page_end) )">Next</a></li>
438                             </ul>
439                         </div>
440                     </td>
441                 </t>
442             </tr>
443         </tbody>
444     </table>
445 </template>
446
447 <!-- Error and special pages -->
448
449 <template id="default_page">
450     <t t-call="website.layout">
451       <div id="wrap" class="oe_structure oe_empty"></div>
452     </t>
453 </template>
454
455 <template id="page_404">
456     <t t-call="website.404">
457         <div class="container">
458             <div class="well mt32">
459                 <p>This page does not exists, but you can create it as you are administrator of this site.</p>
460                 <a class="btn btn-primary" t-attf-href="/website/add/#{ path }">Create Page</a>
461             </div>
462             <div class="text-center text-muted">Edit the content below this line to adapt the default "page not found" page.</div>
463         </div>
464         <hr/>
465     </t>
466 </template>
467
468 <template id="http_error">
469     <t t-call="website.layout">
470         <div id="wrap">
471             <div class="oe_structure">
472                 <h1 class="container mt32"><t t-esc="status_code"/>: <t t-esc="status_message"/></h1>
473             </div>
474
475             <t t-if="editable or request.debug">
476                 <t t-call="website.http_error_debug"/>
477             </t>
478         </div>
479     </t>
480 </template>
481
482 <template id="http_error_debug">
483     <div class="container panel-group mb32 mt32" id="debug_infos">
484         <div class="panel panel-default" t-if="exception">
485             <div class="panel-heading">
486                 <h4 class="panel-title">
487                     <a data-toggle="collapse" data-parent="#debug_infos" href="#error_main">
488                         Error
489                     </a>
490                 </h4>
491             </div>
492             <div id="error_main" class="panel-collapse collapse in">
493                 <div class="panel-body">
494                     <p t-if="website_controller">The following error was raised in the website controller <code t-esc="website_controller"/></p>
495                     <p>
496                         <strong>Error message:</strong>
497                         <pre t-esc="exception.message"/>
498                     </p>
499                 </div>
500             </div>
501         </div>
502         <div class="panel panel-default" t-if="qweb_exception">
503             <div class="panel-heading">
504                 <h4 class="panel-title">
505                     <a data-toggle="collapse" data-parent="#adebug_infos" href="#error_qweb">
506                         QWeb
507                     </a>
508                 </h4>
509             </div>
510             <div id="error_qweb" class="panel-collapse collapse">
511                 <div class="panel-body">
512                     <p t-if="exception.qweb.get('message')">
513                         <strong>Error message:</strong>
514                         <pre t-esc="exception.qweb.get('message')"/>
515                     </p>
516                     <p>
517                         The error occured while rendering the template <code t-esc="qweb_exception.qweb.get('template')"/>
518                         <t t-if="'expression' in qweb_exception.qweb">and evaluating the following expression: <code t-esc="qweb_exception.qweb['expression']"/></t>
519                     </p>
520                     <t t-if="'node' in qweb_exception.qweb">
521                         <pre id="exception_node" t-esc="qweb_exception.qweb['node'].toxml()"/>
522                     </t>
523                 </div>
524             </div>
525         </div>
526         <div class="panel panel-default" t-if="traceback">
527             <div class="panel-heading">
528                 <h4 class="panel-title">
529                     <a data-toggle="collapse" data-parent="#adebug_infos" href="#error_traceback">
530                         Traceback
531                     </a>
532                 </h4>
533             </div>
534             <div id="error_traceback" class="panel-collapse collapse">
535                 <div class="panel-body">
536                     <pre id="exception_traceback" t-esc="traceback"/>
537                 </div>
538             </div>
539         </div>
540     </div>
541 </template>
542
543 <template id="403">
544     <t t-call="website.layout">
545         <div id="wrap">
546             <div class="container">
547                 <h1 class="mt32">403: Forbidden</h1>
548                 <p>The page you were looking for could not be authorized.</p>
549                 <p>Maybe you were looking for one of these popular pages ?</p>
550                 <ul>
551                     <li><a href="/">Homepage</a></li>
552                     <li><a href="/page/website.contactus/">Contact Us</a></li>
553                 </ul>
554             </div>
555             <t t-if="editable or request.debug">
556                 <t t-call="website.http_error_debug"/>
557             </t>
558         </div>
559     </t>
560 </template>
561
562 <template id="404">
563     <t t-call="website.layout">
564         <div id="wrap">
565             <t t-raw="0"/>
566             <div class="oe_structure oe_empty">
567                 <div class="container">
568                     <h1 class="mt32">404: Page not found!</h1>
569                     <p>
570                         The page you were looking for could not be found; it is possible you have
571                         typed the address incorrectly, but it has most probably been removed due
572                         to the recent website reorganisation.
573                     </p>
574                     <p>Maybe you were looking for one of these popular pages ?</p>
575                     <ul>
576                         <li><a href="/">Homepage</a></li>
577                         <li><a href="/page/website.contactus/">Contact Us</a></li>
578                     </ul>
579                 </div>
580             </div>
581
582             <t t-if="request.debug">
583                 <t t-call="website.http_error_debug"/>
584             </t>
585         </div>
586     </t>
587 </template>
588
589 <template id="500">
590     <!-- This template should not use any variable except those provided by website.ir_http._handle_exception -->
591     <html>
592         <head>
593             <title t-esc="status_message">Internal Server Error</title>
594             <link rel='stylesheet' href='/web/static/lib/fontawesome/css/font-awesome.css'/>
595             <link rel='stylesheet' href='/web/static/lib/bootstrap/css/bootstrap.css'/>
596             <link rel='stylesheet' href='/website/static/src/css/website.css'/>
597             <script type="text/javascript" src="/web/static/lib/jquery/jquery.js"></script>
598             <script type="text/javascript" src="/web/static/lib/bootstrap/js/bootstrap.js"></script>
599             <script>
600                 $(document).ready(function() {
601                     var button = $('#reset_templates_button');
602                     button.click(function() {
603                         var dialog = $('#reset_template_confirmation').modal('show');
604                         var input = dialog.find('input[type="text"]').val('').focus();
605                         var dialog_form = dialog.find('form');
606                         dialog_form.submit(function() {
607                             if (input.val() == dialog.find('.confirm_word').text()) {
608                                 dialog.modal('hide');
609                                 button.prop('disabled', true).text('Working...');
610                                 $('#reset_templates_form').trigger('submit');
611                             } else {
612                                 input.val('').focus();
613                             }
614                             return false;
615                         });
616                         return false;
617                     });
618                 });
619             </script>
620         </head>
621         <body>
622             <div id="reset_template_confirmation" class="modal" tabindex="-1" role="dialog" aria-hidden="true" t-ignore="true">
623                 <div class="modal-dialog">
624                     <form class="form-horizontal" role="form">
625                     <div class="modal-content">
626                         <div class="modal-header">
627                             <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
628                             <h3 class="modal-title">Reset templates</h3>
629                         </div>
630                         <div class="modal-body">
631                             <div class="form-group mb0">
632                                 <label for="page-name" class="col-sm-9">
633                                     <p>The selected templates will be reset to their factory settings.</p>
634                                     <p>Type '<i class="confirm_word">yes</i>' in the box below if you want to confirm.</p>
635                                 </label>
636                                 <div class="col-sm-3 mt16">
637                                     <input type="text" class="form-control" required="required" placeholder="yes"/>
638                                 </div>
639                             </div>
640                         </div>
641                         <div class="modal-footer">
642                             <input type="submit" value="Confirm" class="btn btn-primary"/>
643                             <button type="button" class="btn" data-dismiss="modal" aria-hidden="true">Cancel</button>
644                         </div>
645                     </div>
646                     </form>
647                 </div>
648             </div>
649
650             <div id="wrapwrap">
651                 <div class="navbar navbar-default navbar-static-top">
652                     <div class="container">
653                         <div class="collapse navbar-collapse navbar-top-collapse">
654                             <ul class="nav navbar-nav pull-right">
655                                 <li><a href="/">Home</a></li>
656                                 <li><a href="javascript: window.history.back()">Back</a></li>
657                             </ul>
658                         </div>
659                     </div>
660                 </div>
661                 <div class="mb32">
662                     <div class="oe_structure">
663                         <h1 class="container mt32"><t t-esc="status_code"/>: <t t-esc="status_message"/></h1>
664                     </div>
665
666                     <div class="container" t-if="views">
667                         <div class="alert alert-danger" t-if="qweb_exception and editable">
668                             <h4>Template fallback</h4>
669                             <p>An error occured while rendering the template <code t-esc="qweb_exception.qweb['template']"/>.</p>
670                             <p>If this error is caused by a change of yours in the templates, you have the possibility to reset one or more templates to their <strong>factory settings</strong>.</p>
671                             <form action="/website/reset_templates" method="post" id="reset_templates_form">
672                                 <ul class="oe_template_fallback">
673                                     <li t-foreach="views" t-as="view">
674                                         <label>
675                                             <input type="checkbox" name="templates" t-att-value="view.id" t-att-checked="'checked' if view_first else None"/>
676                                             <t t-esc="view.name"/>
677                                         </label>
678                                     </li>
679                                 </ul>
680                                 <input type="hidden" name="redirect" t-att-value="request.httprequest.path"/>
681                                 <button id="reset_templates_button">Reset selected templates</button>
682                             </form>
683                         </div>
684                     </div>
685
686                     <t t-if="editable or request.debug">
687                         <t t-call="website.http_error_debug"/>
688                     </t>
689                 </div>
690             </div>
691         </body>
692     </html>
693 </template>
694
695 <template id="robots">
696 User-agent: *
697 Sitemap: <t t-esc="url_root"/>sitemap.xml
698 </template>
699
700 <template id="sitemap_locs">
701     <url t-foreach="locs" t-as="page">
702         <loc><t t-esc="url_root"/><t t-esc="page['loc']"/></loc><t t-if="page.get('lastmod', False)">
703         <lastmod t-esc="page['lastmod']"/></t><t t-if="page.get('priority', False)">
704         <priority t-esc="page['priority']"/></t><t t-if="page.get('changefreq', False)">
705         <changefreq t-esc="page['changefreq']"/></t>
706     </url>
707 </template>
708
709 <template id="sitemap_xml">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
710 <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
711     <t t-raw="content"/>
712 </urlset>
713 </template>
714
715 <template id="sitemap_index_xml">&lt;?xml version="1.0" encoding="UTF-8"?&gt;
716 <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
717   <sitemap t-foreach="pages" t-as="page">
718     <loc><t t-esc="url_root"/>sitemap-<t t-esc="page"/>.xml</loc>
719   </sitemap>
720 </sitemapindex>
721 </template>
722
723
724 <!-- Actual pages -->
725
726 <template id="homepage" name="Homepage" page="True" priority="29">
727     <t t-call="website.layout">
728       <div id="wrap" class="oe_structure oe_empty"></div>
729     </t>
730 </template>
731
732 <template id="company_description" name="Company Description">
733     <address itemscope="itemscope" itemtype="http://schema.org/Organization">
734         <!-- TODO widget contact must add itemprop attributes -->
735         <div t-field="res_company.partner_id" t-field-options='{
736                 "widget": "contact",
737                 "fields": ["name", "address", "phone", "mobile", "fax", "email"]}'/>
738     </address>
739      <a t-att-href="res_company.google_map_link()" target="_BLANK">
740         <img class="thumbnail img-responsive" t-att-src="res_company.google_map_img()" />
741     </a>
742 </template>
743
744 <template id="contactus" name="Contact us" page="True">
745     <t t-call="website.layout">
746       <div id="wrap">
747         <div class="oe_structure"/>
748         <div class="container">
749             <h1>Contact us</h1>
750             <div class="row">
751                 <div class="col-md-8">
752                     <div class="oe_structure">
753                         <div>
754                             <p>Contact us about anything related to our company or services.</p>
755                             <p>We'll do our best to get back to you as soon as possible.</p>
756                         </div>
757                     </div>
758                     <div class="text-center mt64" name="mail_button">
759                         <a t-attf-href="mailto:{{ res_company.email }}" class="btn btn-primary">Send us an email</a>
760                     </div>
761                 </div>
762                 <div class="col-md-4 mb32">
763                     <div groups="base.group_website_publisher" t-ignore="true" class="pull-right css_editable_mode_hidden" t-att-style="style or ''">
764                         <a class="btn btm-sm btn-default" t-att-href="'/web#return_label=Website&amp;model=%s&amp;id=%s' % (res_company._name, res_company.id)">Change address</a>
765                     </div>
766                     <t t-call="website.company_description"/>
767                 </div>
768             </div>
769         </div>
770         <div class="oe_structure"/>
771       </div>
772     </t>
773 </template>
774
775 <template id="aboutus" name="About us" page="True">
776     <t t-call="website.layout">
777         <div id="wrap">
778             <div class="oe_structure">
779
780                 <section data-snippet-id="title">
781                     <div class="container">
782                         <div class="row">
783                             <div class="col-md-12">
784                                 <h1 class="text-center">About us</h1>
785                                 <h3 class="text-muted text-center">Great products for great people</h3>
786                             </div>
787                         </div>
788                     </div>
789                 </section>
790
791                 <section data-snippet-id="text-image">
792                     <div class="container">
793                         <div class="row">
794                             <div class="col-md-6 mt32">
795                                 <p>
796                                       We are a team of passionate people whose goal is to improve everyone's
797                                       life through disruptive products. We build great products to solve your
798                                       business problems.
799                                 </p>
800                                 <p>
801                                       Our products are designed for small to medium size companies willing to optimize
802                                       their performance.
803                                 </p>
804                             </div>
805                             <div class="col-md-4 col-md-offset-2 mt16 mb16">
806                                 <img src="/website/static/src/img/library/business_conference.jpg" class="img img-responsive shadow" alt="Our Team"/>
807                             </div>
808                         </div>
809                     </div>
810                 </section>
811
812             </div>
813             <div class="oe_structure"></div>
814         </div>
815     </t>
816 </template>
817
818      </data>
819 </openerp>