5077adf6b6373d0af77ddaf1eec393a9875915c3
[odoo/odoo.git] / addons / web / static / src / xml / base.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- vim:fdl=1:
3 -->
4 <templates id="template" xml:space="preserve">
5 <t t-name="EmptyComponent">
6     <div></div>
7 </t>
8 <t t-name="Loading">
9     <div class="oe_loading">
10         Loading...
11     </div>
12 </t>
13 <t t-name="Notification">
14     <div class="oe_notification" t-translation="off">
15         <div id="oe_notification_default">
16             <a class="ui-notify-cross ui-notify-close" href="#">x</a>
17             <h1>#{title}</h1>
18             <p>#{text}</p>
19         </div>
20         <div id="oe_notification_alert" class="ui-state-error">
21             <a class="ui-notify-cross ui-notify-close" href="#">x</a>
22             <span style="float:left; margin:2px 5px 0 0;" class="ui-icon ui-icon-alert"></span>
23             <h1>#{title}</h1>
24             <p>#{text}</p>
25         </div>
26     </div>
27 </t>
28
29 <t t-name="CrashManager.warning">
30     <table cellspacing="0" cellpadding="0" border="0" class="oe-dialog-warning">
31     <tr>
32         <td><img t-att-src='_s + "/web/static/src/img/warning.png"' class="oe-dialog-icon"/></td>
33         <td>
34             <p>
35                 <t t-js="d">
36                     var message = d.message ? d.message : d.error.data.fault_code;
37                     d.html_error = context.engine.tools.html_escape(message)
38                         .replace(/\n/g, '<br/>');
39                 </t>
40                 <t t-raw="html_error"/>
41             </p>
42         </td>
43     </tr>
44     </table>
45 </t>
46 <t t-name="CrashManager.error">
47     <t t-if="!session.openerp_entreprise">
48         <span>Your version of OpenERP is unsupported. Support &amp; maintenance services are available here: <a href="http://www.openerp.com/support-or-publisher-warranty-contract" target="_blank">OpenERP Entreprise</a>.</span>
49     </t>
50     <t t-if="session.openerp_entreprise">
51         <div class="oe_error_send">
52             <div>
53                 <div class="oe_centeralign"><b>OpenERP Enterprise Contract.</b></div>
54                 <div><br/>Your report will be sent to the OpenERP Enterprise team.<br/></div><br/>
55                 <div>
56                     <label>Summary:</label><br/>
57                     <input id="issuename" type="text" class="oe_fielddiv"/>
58                 </div><br/><br/>
59                 <div>
60                     <label>Description:</label><br/>
61                     <textarea id="explanation" rows="6"></textarea>
62                 </div><br/><br/>
63                 <div>
64                     <label>What you did:</label><br/>
65                     <textarea id="remark" rows="6" ></textarea>
66                 </div>
67             </div>
68         </div><br/>
69     </t>
70     <div class="oe_error_detail">
71         <pre><t t-esc="error.message"/></pre>
72         <hr/>
73         <pre><t t-esc="error.data.debug"/></pre>
74     </div>
75 </t>
76
77 <t t-name="Login">
78     <div class="oe_login">
79         <div class="oe_login_bottom"> </div>
80         <div class="oe_login_error_message">Invalid username or password</div>
81         <div class="oe_login_pane">
82             <div class="oe_login_logo"><img src='/web/static/src/img/logo2.png'/></div>
83             <form action="" method="post">
84                 <div class="oe_login_dbpane" >
85                     Database:
86                     <input name="db" t-att-value="widget.selected_db || ''"/>
87                 </div>
88                 <ul>
89                     <li>Username</li>
90                     <li><input type="text" name="login" t-att-value="widget.selected_login || ''" autofocus="autofocus"/></li>
91                     <li>Password</li>
92                     <li><input type="password" name="password" t-att-value="widget.selected_password || ''"/></li>
93                     <li><button name="submit">Log in</button></li>
94                 </ul>
95             </form>
96             <div class="oe_login_footer">
97                 <a href="#" class="oe_login_manage_db">Manage Databases</a> |
98                 <a href="http://www.openerp.com">Powered by <span>OpenERP</span></a>
99             </div>
100         </div>
101     </div>
102 </t>
103 <t t-name="Login.dblist">
104     <select name="db">
105         <t t-foreach="db_list" t-as="db">
106             <t t-if="selected_db === db">
107                 <option t-att-value="db" selected="true">
108                     <t t-esc="db"/></option>
109             </t>
110             <t t-if="selected_db !== db">
111                 <option t-att-value="db"><t t-esc="db"/></option>
112             </t>
113         </t>
114     </select>
115 </t>
116
117 <t t-name="DatabaseManager">
118     <div class="oe_database_manager">
119         <div class="oe_database_manager_menu">
120             <ul class="oe_form_notebook">
121                 <li><a href="#db_create">Create</a></li>
122                 <li><a href="#db_drop">Drop</a></li>
123                 <li><a href="#db_backup">Backup</a></li>
124                 <li><a href="#db_restore">Restore</a></li>
125                 <li><a href="#db_change_password">Password</a></li>
126                 <li><a id="back_to_login" href="#">Back to Login</a></li>
127             </ul>
128             <form id="db_create" name="create_db_form" class="oe_forms" method="POST">
129                 <table align="center" class="db_option_table">
130                     <tr>
131                         <th colspan="2" class="option_string"> CREATE DATABASE </th>
132                     </tr>
133                     <tr>
134                         <td><label for="super_admin_pwd">Master password:</label></td>
135                         <td><input type="password" name="super_admin_pwd" class="required" value="admin"/></td>
136                     </tr>
137                     <tr>
138                         <td><label for="db_name">New database name:</label></td>
139                         <td><input type="text" name="db_name" class="required" matches="^[a-zA-Z][a-zA-Z0-9_]+$"/></td>
140                     </tr>
141                     <tr>
142                         <td><label for="demo_data">Load Demonstration data:</label></td>
143                         <td><input type="checkbox" name="demo_data"/></td>
144                     </tr>
145                     <tr>
146                         <td><label for="db_lang">Default language:</label></td>
147                         <td>
148                             <select name="db_lang" t-if="widget.lang_list">
149                                 <t t-foreach="widget.lang_list" t-as="lang">
150                                     <option t-att-value="lang[0]" t-att-selected="lang[0] === 'en_US' ? 'selected' : undefined"><t t-esc="lang[1]"/></option>
151                                 </t>
152                             </select>
153                         </td>
154                     </tr>
155                     <tr>
156                         <td><label for="create_admin_pwd">Admin password:</label></td>
157                         <td><input type="password" name="create_admin_pwd" class="required"/></td>
158                     </tr>
159                     <tr>
160                         <td><label for="create_confirm_pwd">Confirm password:</label></td>
161                         <td><input type="password" name="create_confirm_pwd" class="required" equalTo="input[name=create_admin_pwd]"/></td>
162                     </tr>
163                     <tr>
164                         <td colspan="2" align="right"><button class="oe_button">Create</button></td>
165                     </tr>
166                 </table>
167             </form>
168             <form id="db_drop" name="drop_db_form" class="oe_forms" method="POST">
169                 <table align="center" class="db_option_table">
170                     <tr>
171                         <th colspan="2" class="option_string"> DROP DATABASE </th>
172                     </tr>
173                     <tr>
174                         <td><label for="drop_db">Database:</label></td>
175                         <td>
176                             <select t-if="widget.db_list" name="drop_db" autofocus="autofocus">
177                                 <t t-foreach="widget.db_list" t-as="db">
178                                     <option t-att-value="db"><t t-esc="db"/></option>
179                                 </t>
180                             </select>
181                             <input t-if="!widget.db_list" name="drop_db" class="required" type="text" autofocus="autofocus"/>
182                         </td>
183                     </tr>
184                     <tr>
185                         <td><label for="drop_password">Master Password:</label></td>
186                         <td><input type="password" name="drop_pwd" class="required"/></td>
187                     </tr>
188                     <tr>
189                         <td colspan="2" align="right"><button class="oe_button">Drop</button></td>
190                     </tr>
191                 </table>
192             </form>
193             <form id="db_backup" name="backup_db_form" class="oe_forms" method="POST" target="backup-target" action="/web/database/backup">
194                 <input type="hidden" name="token"/>
195                 <table align="center" class="db_option_table">
196                     <tr>
197                         <th colspan="2" class="option_string"> BACKUP DATABASE </th>
198                     </tr>
199                     <tr>
200                         <td><label for="backup_db">Database:</label></td>
201                         <td>
202                             <select t-if="widget.db_list" name="backup_db" autofocus="autofocus">
203                                 <t t-foreach="widget.db_list" t-as="db">
204                                     <option t-att-value="db"><t t-esc="db"/></option>
205                                 </t>
206                             </select>
207                             <input t-if="!widget.db_list" name="backup_db" class="required" type="text" autofocus="autofocus"/>
208                         </td>
209                     </tr>
210                     <tr>
211                         <td><label for="backup_pwd">Master Password:</label></td>
212                         <td><input type="password" name="backup_pwd" class="required"/></td>
213                     </tr>
214                     <tr>
215                         <td colspan="2" align="right"><button class="oe_button">Backup</button></td>
216                     </tr>
217                 </table>
218             </form>
219             <form id="db_restore" name="restore_db_form" class="oe_forms" method="POST">
220                 <table align="center" class="db_option_table">
221                     <tr>
222                         <th colspan="2" class="option_string"> RESTORE DATABASE </th>
223                     </tr>
224                     <tr>
225                         <td><label for="restore_db">File:</label></td>
226                         <td><input type="file" name="db_file" class="required" autofocus="autofocus"/></td>
227                     </tr>
228                     <tr>
229                         <td><label for="restore_pwd">Master Password:</label></td>
230                         <td><input type="password" name="restore_pwd" class="required"/></td>
231                     </tr>
232                     <tr>
233                         <td><label for="new_db">New database name:</label></td>
234                         <td><input type="text" name="new_db" class="required"/></td>
235                     </tr>
236                     <tr>
237                         <td colspan="2" align="right"><button class="oe_button">Restore</button></td>
238                     </tr>
239                 </table>
240             </form>
241             <form id="db_change_password" name="change_pwd_form" class="oe_forms" method="POST">
242                 <table align="center" class="db_option_table">
243                     <tr>
244                         <th colspan="2" class="option_string"> CHANGE MASTER PASSWORD </th>
245                     </tr>
246                     <tr>
247                         <td><label for="old_pwd">Master password:</label></td>
248                         <td><input type="password" name="old_pwd" class="required" minlength="1" autofocus="autofocus"/></td>
249                     </tr>
250                     <tr>
251                         <td><label for="new_pwd">New master password:</label></td>
252                         <td><input type="password" name="new_pwd" class="required" minlength="1"/></td>
253                     </tr>
254                     <tr>
255                         <td><label for="confirm_pwd">Confirm new master password:</label></td>
256                         <td><input type="password" name="confirm_pwd" class="required" equalTo="input[name=new_pwd]" minlength="1"/></td>
257                     </tr>
258                     <tr>
259                         <td colspan="2" align="right"><button class="oe_button">Change Password</button></td>
260                     </tr>
261                 </table>
262             </form>
263         </div>
264     </div>
265 </t>
266
267 <t t-name="WebClient">
268     <table class="oe_webclient">
269         <tr>
270             <td colspan="2" class="oe_topbar">
271                 <div class="oe_menu_placeholder"/>
272                 <div class="oe_user_menu_placeholder"/>
273                 <div class="oe_systray"/>
274             </td>
275         </tr>
276         <tr>
277             <td class="oe_leftbar" valign="top">
278                 <a href="#" class="oe_logo"><img t-att-src='_s + "/web/static/src/img/logo.png"'/></a>
279                 <div class="oe_secondary_menus_container"/>
280                 <div class="oe_footer">
281                     Powered by <a href="http://www.openerp.com"><span>Open</span>ERP</a>
282                 </div>
283             </td>
284             <td class="oe_application">
285             </td>
286         </tr>
287     </table>
288 </t>
289
290 <t t-name="Menu">
291     <ul class="oe_menu" t-if="widget.data">
292         <li t-foreach="widget.data.data.children" t-as="menu">
293             <t t-call="Menu.secondary.link"/>
294         </li>
295     </ul>
296 </t>
297 <t t-name="Menu.more">
298     <li class="oe_menu_more_container">
299         <a href="#" class="oe_menu_more_link oe_dropdown_toggle">More</a>
300         <ul class="oe_menu_more" style="display: none;"/>
301     </li>
302 </t>
303 <t t-name="Menu.secondary">
304     <div t-foreach="widget.data.data.children" t-as="menu" style="display: none" class="oe_secondary_menu" t-att-data-menu-parent="menu.id">
305         <t t-foreach="menu.children" t-as="menu">
306             <div class="oe_secondary_menu_section">
307                 <t t-esc="menu.name"/>
308                 <!--
309                     Shall the section be still clickable ?
310                     <t t-call="Menu.secondary.link"/>
311                 -->
312             </div>
313             <t t-call="Menu.secondary.submenu"/>
314         </t>
315     </div>
316 </t>
317 <t t-name="Menu.secondary.submenu">
318     <ul t-if="menu.children.length" class="oe_secondary_submenu">
319         <li t-foreach="menu.children" t-as="menu">
320             <t t-call="Menu.secondary.link"/>
321             <!--<span class="oe_menu_label">8</span>-->
322             <t t-call="Menu.secondary.submenu"/>
323         </li>
324     </ul>
325 </t>
326 <t t-name="Menu.secondary.link">
327     <a href="#"
328         t-att-class="menu.children.length ? 'oe_menu_toggler' : 'oe_menu_leaf'"
329         t-att-data-menu="menu.id"
330         t-att-data-action-model="menu.action ? menu.action.split(',')[0] : ''"
331         t-att-data-action-id="menu.action ? menu.action.split(',')[1] : ''">
332         <t t-esc="menu.name"/>
333         <t t-if="menu.needaction_enabled">
334             <div class="oe_menu_counter">
335                 <t t-esc="menu.needaction_counter"/>
336             </div>
337         </t>
338     </a>
339 </t>
340
341 <t t-name="UserMenu">
342     <ul class="oe_user_menu oe_topbar_item">
343         <li class="oe_dropdown">
344             <a href="#" class="oe_dropdown_toggle">
345                 <img class="oe_topbar_avatar" t-att-data-default-src="_s + '/web/static/src/img/topbar-avatar.png'"/>
346                 <span class="oe_topbar_name"/>
347             </a>
348             <ul class="oe_dropdown_options">
349                 <!--<li><a href="#" data-menu="profile">Profile</a></li>-->
350                 <li><a href="#" data-menu="settings">Settings</a></li>
351                 <li><a href="#" data-menu="logout">Log out</a></li>
352                 <li><hr/></li>
353                 <li><a href="#" data-menu="about">About OpenERP</a></li>
354                 <li><hr/></li>
355             </ul>
356         </li>
357     </ul>
358 </t>
359 <t t-name="UserMenu.shortcut">
360     <li t-foreach="shortcuts" t-as="shortcut">
361         <a href="#" data-menu="shortcut" t-att-data-id="shortcut.res_id" t-att-data-shortcut-id="shortcut.id">
362             <t t-esc="shortcut.name"/>
363         </a>
364     </li>
365 </t>
366 <t t-name="About-Page">
367     <div>
368         <a class="oe_activate_debug_mode" href="?debug" style="float:right; font-size: 80%;">Activate the developper mode</a>
369         <h1 style="margin:0;">OpenERP</h1>
370         <h3 style="margin:15px 0;padding:0;">Version <t t-esc="version_info.version"/></h3>
371         <p>
372             Copyright Â© 2004-TODAY OpenERP SA. All Rights Reserved.<br />
373             OpenERP is a trademark of the <a target="_blank" href="http://openerp.com/" style="text-decoration: underline;">OpenERP SA Company</a>.
374         </p>
375         <p>
376             Licenced under the terms of <a target="_blank" href="http://www.gnu.org/licenses/agpl.html" style="text-decoration: underline;">GNU Affero General Public License</a>
377         </p>
378         <p>
379             For more information visit <a target="_blank" href="http://openerp.com/" style="text-decoration: underline;">OpenERP.com</a>
380         </p>
381     </div>
382 </t>
383 <t t-name="Change_Pwd">
384     <form name="change_password_form" class="oe_forms" method="POST">
385         <table align="center">
386             <tr>
387                 <td><label for="old_pwd">Old Password:</label></td>
388                 <td><input type="password" name="old_pwd"
389                            minlength="1" autofocus="autofocus"/></td>
390             </tr>
391             <tr>
392             <td><label for="new_password">New Password:</label></td>
393             <td><input type="password" name="new_password"
394                        minlength="1" autofocus="autofocus"/></td>
395             </tr>
396             <tr>
397                 <td><label for="confirm_pwd">Confirm Password:</label></td>
398                 <td><input type="password" name="confirm_pwd"
399                              minlength="1"/></td>
400             </tr>
401             <tr>
402                 <td colspan="2" align="right"><button class="oe_button">Change Password</button></td>
403             </tr>
404         </table>
405     </form>
406 </t>
407
408 <t t-name="ViewManager">
409     <div class="oe_view_manager">
410         <div class="oe_view_manager_header">
411             <div class="oe_view_manager_row">
412                 <h2 class="oe_view_title" t-if="widget.flags.display_title !== false">
413                     <span class="oe_view_title_text"><t t-esc="widget.display_title()"/></span>
414                 </h2>
415                 <div class="oe_view_manager_view_search" t-opentag="true"/>
416             </div>
417             <div class="oe_view_manager_row">
418                 <div class="oe_view_manager_buttons"/>
419                 <ul class="oe_view_manager_switch oe_button_group oe_right">
420                     <t t-if="widget.views_src.length != 1" t-foreach="widget.views_src" t-as="view">
421                       <li><a t-attf-class="oe_vm_switch_#{view.view_type} oe_i" t-att-data-view-type="view.view_type" t-att-title="view.label || view.view_type">
422                         </a></li>
423                     </t>
424                 </ul>
425                 <div class="oe_view_manager_pager"/>
426                 <div class="oe_view_manager_sidebar"/>
427             </div>
428         </div>
429         <div class="oe_view_manager_body">
430             <t t-foreach="widget.views_src" t-as="view">
431                 <div t-attf-class="oe_view_manager_view_#{view.view_type}"/>
432             </t>
433         </div>
434     </div>
435 </t>
436 <t t-name="ViewManagerAction" t-extend="ViewManager">
437     <t t-jquery="h2.oe_view_title" t-operation="prepend">
438         <a t-if="widget.flags.display_title !== false" class="oe-shortcut-toggle" title="Add / Remove Shortcut..."
439             href="javascript: void(0)"> </a>
440     </t>
441     <t t-jquery="h2.oe_view_title" t-operation="after">
442         <select t-if="widget.session.debug" class="oe_debug_view"/>
443     </t>
444 </t>
445 <t t-name="ViewManagerDebug">
446     <option value="">Debug View#<t t-esc="view.fields_view.view_id"/></option>
447     <option t-if="_.indexOf(['form', 'page'], view_manager.active_view) gt -1" value="perm_read" data-views="form,page">View Log (perm_read)</option>
448     <option value="fields">View Fields</option>
449     <option value="fvg">Fields View Get</option>
450     <t t-if="view_manager.session.uid === 1">
451         <option value="manage_views">Manage Views</option>
452         <option value="edit" data-model="ir.ui.view" t-att-data-id="view.fields_view.view_id">Edit <t t-esc="_.str.capitalize(view.fields_view.type)"/>View</option>
453         <option t-if="view_manager.searchview" value="edit" data-model="ir.ui.view" t-att-data-id="view_manager.searchview.view_id">Edit SearchView</option>
454         <option t-if="view_manager.action" value="edit" t-att-data-model="view_manager.action.type" t-att-data-id="view_manager.action.id">Edit Action</option>
455         <option value="edit_workflow">Edit Workflow</option>
456     </t>
457 </t>
458 <t t-name="ViewManagerDebugViewLog">
459     <div class="oe_debug_view_log">
460         <label>ID:</label>
461         <span><t t-esc="perm.id"/></span>
462
463         <label>XML ID:</label>
464         <span><t t-esc="perm.xmlid"/></span>
465
466         <label>Creation User:</label>
467         <span><t t-esc="format(perm.create_uid, { 'type' : 'many2one' }, '/')"/></span>
468
469         <label>Creation Date:</label>
470         <span><t t-esc="format(perm.create_date, { 'type' : 'datetime' }, '/')"/></span>
471
472         <label>Latest Modification by:</label>
473         <span><t t-esc="format(perm.write_uid, { 'type' : 'many2one' }, '/')"/></span>
474
475         <label>Latest Modification Date:</label>
476         <span><t t-esc="format(perm.write_date, { 'type' : 'datetime' }, '/')"/></span>
477     </div>
478 </t>
479 <t t-name="ViewPager">
480     <div class="oe_pager_value">
481         <t t-raw="__content__"/>
482     </div>
483     <ul class="oe_pager_group">
484         <!--
485         <button class="oe_button oe_button_pager" type="button" data-pager-action="first">
486             <img t-att-src='_s + "/web/static/src/img/pager_first.png"'/>
487         </button>
488         -->
489         <li>
490             <a class="oe_i" type="button" data-pager-action="previous">(</a>
491         </li>
492         <li>
493             <a class="oe_i" type="button" data-pager-action="next">)</a>
494         </li>
495         <!--
496         <button class="oe_button oe_button_pager" type="button" data-pager-action="last">
497             <img t-att-src='_s + "/web/static/src/img/pager_last.png"'/>
498         </button>
499         -->
500     </ul>
501 </t>
502
503 <t t-name="Sidebar">
504     <div class="oe_sidebar">
505         <t t-foreach="widget.sections" t-as="section">
506             <div class="oe_form_dropdown_section">
507                 <button class="oe_dropdown_toggle"><t t-esc="section.label"/></button>
508                 <ul class="oe_dropdown_menu">
509                     <li t-foreach="widget.items[section.name]" t-as="item" t-att-class="item.classname">
510                         <a class="oe_sidebar_action_a" t-att-title="item.title" href="#" t-att-data-section="section.name" t-att-data-index="item_index">
511                             <t t-raw="item.label"/>
512                         </a>
513                     </li>
514                 </ul>
515             </div>
516         </t>
517     </div>
518 </t>
519
520 <t t-name="TreeView">
521     <select t-if="toolbar" style="width: 30%">
522     </select>
523     <table class="oe-treeview-table">
524         <thead>
525             <tr>
526                 <th t-foreach="fields_view" t-as="field"
527                     t-if="!field.attrs.modifiers.tree_invisible"
528                     class="treeview-header">
529                     <t t-esc="fields[field.attrs.name].string" />
530                 </th>
531             </tr>
532         </thead>
533         <tbody>
534         </tbody>
535     </table>
536 </t>
537 <tr t-name="TreeView.rows"
538         t-foreach="records" t-as="record"
539         t-att-id="'treerow_' + record.id"
540         t-att-data-id="record.id" t-att-data-level="level + 1">
541     <t t-set="children" t-value="record[children_field]"/>
542     <t t-set="class" t-value="children and children.length ? 'treeview-tr' : 'treeview-td'"/>
543     <t t-set="rank" t-value="'oe-treeview-first'"/>
544     <t t-set="style" t-value="'background-position: ' + 19*level + 'px; padding-left: ' + 19*level + 'px;'"/>
545
546     <td t-foreach="fields_view" t-as="field"
547         t-if="!field.attrs.modifiers.tree_invisible"
548         t-att-data-id="record.id"
549         t-att-style="color_for(record) + style "
550         t-attf-class="#{class} #{rank} #{(fields[field.attrs.name].type === 'float') or (fields[field.attrs.name].type === 'integer') ? 'oe-number' : ''}">
551
552         <span t-if="!field.attrs.modifiers.invisible" >
553             <t t-esc="render(record[field.attrs.name], fields[field.attrs.name])" />
554         </span>
555
556         <t t-set="class" t-value="'treeview-td'"/>
557         <t t-set="rank" t-value="''"/>
558         <t t-set="style" t-value="''"/>
559     </td>
560 </tr>
561
562 <table t-name="ListView" class="oe-listview-content">
563     <t t-set="columns_count" t-value="visible_columns.length + (options.selectable ? 1 : 0) + (options.deletable ? 1 : 0) + (options.isClarkGable ? 1 : 0)"/>
564     <thead>
565         <tr t-if="options.action_buttons !== false or options.pager !== false">
566             <th t-att-colspan="columns_count">
567                 <div class="oe_list_buttons"/>
568                 <div class="oe_list_sidebar"/>
569                 <div class="oe_list_pager"/>
570             </th>
571         </tr>
572         <tr t-if="options.header" class="oe-listview-header-columns">
573             <t t-foreach="columns" t-as="column">
574                 <th t-if="column.meta">
575                     <t t-esc="column.string"/>
576                 </th>
577             </t>
578             <th t-if="options.selectable" width="1"  >
579                 <input type="checkbox" class="all-record-selector"/>
580             </th>
581             <th t-if="options.isClarkGable" width="1"></th>
582             <t t-foreach="columns" t-as="column">
583                 <th t-if="!column.meta and column.invisible !== '1'" t-att-data-id="column.id"
584                     t-att-class="((options.sortable and column.tag !== 'button') ? 'oe-sortable' : null)">
585                     <t t-if="column.tag !== 'button'"><t t-esc="column.string"/></t>
586                 </th>
587             </t>
588             <th t-if="options.deletable" width="1"/>
589         </tr>
590     </thead>
591     <tfoot>
592         <tr>
593             <td t-if="options.selectable"/>
594             <td t-if="options.isClarkGable"/>
595             <td t-foreach="aggregate_columns" t-as="column" class="oe-list-footer oe-number"
596                 t-att-data-field="column.id" t-att-title="column.label">
597             </td>
598             <td t-if="options.deletable"/>
599         </tr>
600     </tfoot>
601 </table>
602 <t t-name="ListView.buttons">
603     <div t-if="!widget.no_leaf and widget.options.action_buttons !== false" class="oe_list_buttons">
604         <button type="button" class="oe_button oe_list_add" t-if="widget.options.addable">
605             <t t-esc="widget.options.addable"/>
606         </button>
607         <button type="button" class="oe_button oe_list_delete" t-if="widget.options.selectable and widget.options.deletable">
608             Delete
609         </button>
610     </div>
611 </t>
612 <t t-name="Listview.pager">
613     <div t-if="!widget.no_leaf and widget.options.pager !== false" class="oe_list_pager" t-att-colspan="widget.columns_count">
614         <t t-call="ViewPager">
615             <span class="oe-pager-state">
616             </span>
617         </t>
618     </div>
619 </t>
620 <t t-name="ListView.rows" t-foreach="records.length" t-as="index">
621     <t t-call="ListView.row">
622         <t t-set="record" t-value="records.at(index)"/>
623         <t t-set="row_parity" t-value="index_parity"/>
624     </t>
625 </t>
626 <tr t-name="ListView.row" t-att-class="row_parity"
627         t-att-data-id="record.get('id')"
628         t-att-style="view.color_for(record)">
629     <t t-foreach="columns" t-as="column">
630         <td t-if="column.meta">
631
632         </td>
633     </t>
634     <th t-if="options.selectable" class="oe-record-selector" width="1">
635         <t t-set="checked" t-value="options.select_view_id == record.get('id') ? 'checked' : null"/>
636         <input t-if="options.radio" type="radio" name="radiogroup" t-att-checked="checked"/>
637         <input t-if="!options.radio" type="checkbox" name="radiogroup" t-att-checked="checked"/>
638     </th>
639     <th t-if="options.isClarkGable" class="oe-record-edit-link" width="1">
640         <img src="/web/static/src/img/pencil.gif" width="12" height="12" class="oe-record-edit-link-img"/>
641     </th>
642     <t t-foreach="columns" t-as="column">
643         <t t-set="align" t-value="column.type === 'integer' or column.type == 'float'"/>
644         <td t-if="!column.meta and column.invisible !== '1'" t-att-title="column.help"
645             t-att-class="'oe-field-cell' + (align ? ' oe-number' : '')
646                          + (column.tag === 'button' ? ' oe-button' : '')"
647             t-att-data-field="column.id">
648             <t t-raw="render_cell(record, column)"/>
649         </td>
650     </t>
651     <td t-if="options.deletable" class='oe-record-delete' width="1">
652         <button type="button" name="delete"></button>
653     </td>
654 </tr>
655
656 <t t-name="FormView">
657     <div class="oe_formview">
658         <div class="oe_form_header">
659             <div class="oe_form_buttons" t-if="widget.options.action_buttons !== false">
660                 <button type="button" class="oe_button oe_form_button_save">Save</button>
661                 <button type="button" class="oe_button oe_form_button_cancel">Cancel</button>
662             </div>
663             <div class="oe_form_pager" t-if="widget.options.pager !== false">
664                 <t t-call="ViewPager">
665                     <span class="oe_pager_index">0</span><span class="oe_pager_separator"> / </span><span class="oe_pager_count">0</span>
666                 </t>
667             </div>
668             <div class="oe_form_sidebar">
669             </div>
670         </div>
671         <div style="clear: both;"/>
672         <div class="oe_form_container"/>
673     </div>
674 </t>
675 <t t-name="FormView">
676     <div class="oe_formview">
677         <div class="oe_form_buttons"/>
678         <div class="oe_form_sidebar"/>
679         <div class="oe_form_pager"/>
680         <div class="oe_form_container"/>
681     </div>
682 </t>
683 <t t-name="FormView.buttons">
684     <div class="oe_form_buttons" t-if="widget.options.action_buttons !== false">
685         <span class="oe_form_buttons_view">
686             <button type="button" class="oe_button oe_form_button_edit">Edit</button>
687             <button type="button" class="oe_button oe_form_button_create">Create</button>
688             <button type="button" class="oe_button oe_form_button_duplicate">Duplicate</button>
689             <button type="button" class="oe_button oe_form_button_delete">Delete</button>
690         </span>
691         <span class="oe_form_buttons_edit">
692             <button type="button" class="oe_button oe_form_button_save">Save</button>
693             <button type="button" class="oe_button oe_form_button_cancel">Cancel</button>
694         </span>
695     </div>
696 </t>
697 <t t-name="FormView.pager">
698     <div class="oe_form_pager" t-if="widget.options.pager !== false">
699         <t t-call="ViewPager">
700             <span class="oe_pager_index">0</span><span class="oe_pager_separator"> / </span><span class="oe_pager_count">0</span>
701         </t>
702     </div>
703 </t>
704 <t t-name="FormView.sidebar.attachments">
705     <div class="oe-sidebar-attachments-toolbar">
706         <div class="oe-binary-file-set" style="float: right">
707             <form class="oe-binary-form" t-attf-target="#{element_id}_iframe"
708                 method="post" enctype="multipart/form-data" action="/web/binary/upload_attachment">
709                 <input type="hidden" name="session_id" t-att-value="session.session_id"/>
710                 <input type="hidden" name="callback" t-attf-value="#{element_id}_iframe"/>
711                 <input type="hidden" name="model" t-att-value="view.dataset.model"/>
712                 <input type="hidden" name="id" t-att-value="view.datarecord.id"/>
713                 <button class="oe_button" type="button">
714                     <img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16" style="display: none"/>
715                     <span>Add</span>
716                 </button>
717                 <input type="file" class="oe-binary-file" name="ufile" title="Add attachment"
718                     t-att-onclick="view.datarecord.id ? null : 'alert(\'No record selected ! You can only attach to existing record.\'); return false;'"/>
719             </form>
720             <iframe t-attf-id="#{element_id}_iframe" t-attf-name="#{element_id}_iframe" style="display: none"/>
721         </div>
722     </div>
723     <br style="clear: both"/>
724     <ul class="oe-sidebar-attachments-items">
725         <li t-foreach="attachments" t-as="attachment">
726             <t t-if="attachment.type == 'binary'" t-set="attachment.url" t-value="_s + '/web/binary/saveas?session_id='
727                 + session.session_id + '&amp;model=ir.attachment&amp;id=' + attachment.id
728                 + '&amp;field=datas&amp;filename_field=name&amp;t=' + (new Date().getTime())"/>
729             <a class="oe-sidebar-attachments-link" t-att-href="attachment.url" target="_blank">
730                 <t t-esc="attachment.name"/>
731             </a>
732             <a href="#" class="oe-sidebar-attachment-delete" t-att-data-id="attachment.id" t-attf-title="Delete the attachment #{attachment.name}">
733                 <img t-att-src='_s + "/web/static/src/img/attachments-close.png"' width="15" height="15" border="0"/>
734             </a>
735         </li>
736     </ul>
737 </t>
738 <form t-name="FormView.set_default" class="oe_forms oe_frame">
739     <t t-set="args" t-value="widget.dialog_options.args"/>
740     <table style="width: 100%">
741         <tr>
742             <td>
743                 <label for="formview_default_fields"
744                        class="oe_label oe_align_right">
745                     Default:
746                 </label>
747             </td>
748             <td class="oe_form_required">
749                 <select id="formview_default_fields">
750                     <option value=""/>
751                     <option t-foreach="args.fields" t-as="field"
752                             t-att-value="field.name">
753                         <t t-esc="field.string"/> = <t t-esc="field.displayed"/>
754                     </option>
755                 </select>
756             </td>
757         </tr>
758         <tr t-if="args.conditions.length">
759             <td>
760                 <label for="formview_default_conditions"
761                        class="oe_label oe_align_right">
762                     Condition:
763                 </label>
764             </td>
765             <td>
766                 <select id="formview_default_conditions">
767                     <option value=""/>
768                     <option t-foreach="args.conditions" t-as="cond"
769                             t-att-value="cond.name + '=' + cond.value">
770                         <t t-esc="cond.string"/>=<t t-esc="cond.displayed"/>
771                     </option>
772                 </select>
773             </td>
774         </tr>
775         <tr>
776             <td colspan="2">
777                 <input type="radio" id="formview_default_self"
778                        value="self" name="scope" checked="checked"/>
779                 <label for="formview_default_self" class="oe_label"
780                        style="display: inline;">
781                     Only you
782                 </label>
783                 <br/>
784                 <input type="radio" id="formview_default_all"
785                        value="all" name="scope"/>
786                 <label for="formview_default_all" class="oe_label"
787                        style="display: inline;">
788                     All users
789                 </label>
790             </td>
791         </tr>
792     </table>
793 </form>
794
795 <t t-name="FormRenderingForm">
796     <div class="oe_form_sheetbg">
797         <div class="oe_form_sheet oe_form_sheet_width">
798             <group t-if="legacy_mode" col="4"/>
799         </div>
800     </div>
801 </t>
802 <t t-name="FormRenderingGroup">
803     <t t-set="table">
804         <table border="0" cellpadding="0" cellspacing="0" width="100%"/>
805     </t>
806     <t t-if="string">
807         <fieldset class="oe_group_box">
808             <legend><t t-esc="string"/></legend>
809             <t t-raw="table"/>
810         </fieldset>
811     </t>
812     <t t-if="!string">
813         <t t-raw="table"/>
814     </t>
815 </t>
816 <t t-name="FormRenderingNotebook">
817     <div>
818         <ul class="oe_form_notebook">
819             <li t-foreach="pages" t-as="page">
820                 <a t-attf-href="##{page.id}">
821                     <t t-esc="page.string"/>
822                 </a>
823             </li>
824         </ul>
825     </div>
826 </t>
827 <t t-name="FormRenderingNotebookPage">
828     <div class="oe_form_notebook_page" t-att-id="id">
829         <group t-if="legacy_mode" col="4"/>
830     </div>
831 </t>
832 <t t-name="FormRenderingSeparator">
833     <div class="oe_horizontal_separator">
834         <t t-esc="string"/>
835     </div>
836 </t>
837 <t t-name="FormRenderingLabel">
838     <label  t-att-for="_for"
839             t-att-title="help"
840             t-attf-class="oe_form_label#{help ? '_help' : ''} oe_align_#{align}">
841         <t t-esc="string"/>
842         <span t-if="help">?</span>
843         :
844     </label>
845 </t>
846
847 <t t-name="Widget">
848     Unhandled widget
849     <t t-js="dict">console.warn('Unhandled widget', dict.widget);</t>
850 </t>
851 <t t-name="WidgetLabel.tooltip">
852     <div class="oe_tooltip_string" t-if="widget.string">
853         <t t-esc="widget.node.attrs.string"/> <t t-if="debug and widget.nolabel">(nolabel)</t>
854     </div>
855     <p t-if="widget.help" class="oe_tooltip_help"><t t-esc="widget.help"/></p>
856     <ul t-if="debug" class="oe_tooltip_technical">
857         <li data-item="field" t-if="widget.name">
858             <span class="oe_tooltip_technical_title">Field:</span>
859             <t t-esc="widget.name"/>
860         </li>
861         <li data-item="object" t-if="widget.view and widget.view.fields_view">
862             <span class="oe_tooltip_technical_title">Object:</span>
863             <t t-esc="widget.view.fields_view.model"/>
864         </li>
865         <li data-item="type" t-if="widget.field">
866             <span class="oe_tooltip_technical_title">Type:</span>
867             <t t-esc="widget.field.type"/>
868         </li>
869         <li t-if="widget.node.attrs.widget" data-item="widget">
870             <span class="oe_tooltip_technical_title">Widget:</span>
871             <t t-esc="widget.node.attrs.widget"/>
872         </li>
873         <li t-if="widget.node.attrs.size || (widget.field and widget.field.size)" data-item="size">
874             <span class="oe_tooltip_technical_title">Size:</span>
875             <t t-esc="widget.node.attrs.size || widget.field.size"/>
876         </li>
877         <li t-if="widget.node.attrs.context" data-item="context">
878             <span class="oe_tooltip_technical_title">Context:</span>
879             <t t-esc="widget.node.attrs.context_string"/>
880         </li>
881         <li t-if="widget.node.attrs.domain" data-item="domain">
882             <span class="oe_tooltip_technical_title">Domain:</span>
883             <t t-esc="widget.node.attrs.domain_string"/>
884         </li>
885         <li t-if="widget.node.attrs.modifiers and widget.node.attrs.modifiers != '{}'" data-item="modifiers">
886             <span class="oe_tooltip_technical_title">Modifiers:</span>
887             <t t-esc="widget.node.attrs.modifiers"/>
888         </li>
889         <li t-if="widget.field and widget.field.change_default" data-item="change_default">
890             <span class="oe_tooltip_technical_title">Change default:</span>
891             Yes
892         </li>
893         <li t-if="widget.node.attrs.on_change" data-item="on_change">
894             <span class="oe_tooltip_technical_title">On change:</span>
895             <t t-esc="widget.node.attrs.on_change"/>
896         </li>
897         <li t-if="widget.field and widget.field.relation" data-item="relation">
898             <span class="oe_tooltip_technical_title">Relation:</span>
899             <t t-esc="widget.field.relation"/>
900         </li>
901         <li t-if="widget.field and widget.field.selection" data-item="selection">
902             <span class="oe_tooltip_technical_title">Selection:</span>
903             <ul>
904                 <li t-foreach="widget.field.selection" t-as="option">
905                     [<t t-esc="option[0]"/>]
906                     <t t-if="option[1]"> - </t>
907                     <t t-esc="option[1]"/>
908                 </li>
909             </ul>
910         </li>
911     </ul>
912 </t>
913 <t t-name="FieldChar">
914     <t t-if="!widget.get('effective_readonly')">
915         <div class="oe_form_field_char">
916             <input t-att-type="widget.password ? 'password' : 'text'"
917                 t-att-id="widget.id_for_label"
918                 t-att-tabindex="widget.node.attrs.tabindex"
919                 t-att-autofocus="widget.node.attrs.autofocus"
920                 t-attf-class="field_char #{widget.is_field_number ? 'oe-number' : ''}"
921             /><img class="oe_field_translate oe_input_icon" t-if="widget.field.translate" t-att-src='_s + "/web/static/src/img/icons/terp-translate.png"' width="16" height="16" border="0"/>
922         </div>
923     </t>
924     <t t-if="widget.get('effective_readonly')">
925         <div t-attf-class="oe_form_field_char #{widget.is_field_number ? 'oe-number' : ''}">
926         </div>
927     </t>
928 </t>
929 <t t-name="FieldEmail">
930     <t t-if="!widget.get('effective_readonly')">
931         <table class="oe_form_field_email" cellpadding="0" cellspacing="0" border="0">
932         <tr>
933             <td>
934                 <input type="text"
935                     t-att-id="widget.id_for_label"
936                     t-att-tabindex="widget.node.attrs.tabindex"
937                     t-att-autofocus="widget.node.attrs.autofocus"
938                 />
939             </td>
940             <td width="16">
941                 <button class="oe_button oe_field_button" tabindex="-1" type="button" title="Send an e-mail with your default e-mail client">
942                     <img t-att-src='_s + "/web/static/src/img/icons/terp-mail-message-new.png"'/>
943                 </button>
944             </td>
945         </tr>
946         </table>
947     </t>
948     <t t-if="widget.get('effective_readonly')">
949         <div>
950             <a href="#" class="oe_form_uri"/>
951         </div>
952     </t>
953 </t>
954 <t t-name="FieldUrl">
955     <t t-if="!widget.get('effective_readonly')">
956         <table class="oe_form_field_url" cellpadding="0" cellspacing="0" border="0">
957         <tr>
958             <td>
959                 <input type="text"
960                     t-att-id="widget.id_for_label"
961                     t-att-tabindex="widget.node.attrs.tabindex"
962                     t-att-autofocus="widget.node.attrs.autofocus"
963                 />
964             </td>
965             <td width="16">
966                 <button class="oe_button oe_field_button" tabindex="-1" type="button" title="Open this resource">
967                     <img t-att-src='_s + "/web/static/src/img/icons/gtk-ok.png"'/>
968                 </button>
969             </td>
970         </tr>
971         </table>
972     </t>
973     <t t-if="widget.get('effective_readonly')">
974         <div>
975             <a href="#" class="oe_form_uri"/>
976         </div>
977     </t>
978 </t>
979 <t t-name="FieldText">
980     <t t-if="!widget.get('effective_readonly')">
981         <div class="oe_form_field_text">
982             <textarea rows="6"
983                 t-att-name="widget.name"
984                 class="field_text"
985                 t-att-tabindex="widget.node.attrs.tabindex"
986                 t-att-autofocus="widget.node.attrs.autofocus"
987             ></textarea><img class="oe_field_translate oe_input_icon" t-if="widget.field.translate" t-att-src='_s + "/web/static/src/img/icons/terp-translate.png"' width="16" height="16" border="0"/>
988         </div>
989     </t>
990 </t>
991 <t t-name="web.datetimepicker">
992     <div class="oe_datepicker_root oe_form_field_datetime">
993         <input type="text" class="oe_datepicker_container" disabled="disabled" style="display: none;"/>
994         <input type="text"
995             t-att-name="widget.name"
996             t-attf-class="oe_datepicker_master field_#{widget.type_of_date}"
997         /><img class="oe_input_icon oe_datepicker_trigger" t-att-src='_s + "/web/static/src/img/ui/field_calendar.png"'
998              title="Select date" width="16" height="16" border="0"/>
999     </div>
1000 </t>
1001 <t t-name="FieldSelection">
1002     <t t-if="!widget.get('effective_readonly')">
1003         <div class="oe_form_field_selection">
1004             <select
1005                 t-att-name="widget.name"
1006                 t-att-tabindex="widget.node.attrs.tabindex"
1007                 t-att-autofocus="widget.node.attrs.autofocus"
1008                 t-att-id="widget.id_for_label">
1009                     <t t-foreach="widget.values" t-as="option">
1010                         <option><t t-esc="option[1]"/></option>
1011                     </t>
1012             </select>
1013         </div>
1014     </t>
1015     <t t-if="widget.get('effective_readonly')">
1016         <div class="field_selection">
1017         </div>
1018     </t>
1019 </t>
1020 <t t-name="FieldMany2One">
1021     <t t-if="!widget.get('effective_readonly')">
1022         <table class="oe_form_field_many2one" cellpadding="0" cellspacing="0" border="0">
1023         <tr>
1024             <td valign="top">
1025                 <input type="text"
1026                     t-att-id="widget.id_for_label"
1027                     t-att-tabindex="widget.node.attrs.tabindex"
1028                     t-att-autofocus="widget.node.attrs.autofocus"
1029                 />
1030                 <span class="oe-m2o-drop-down-button">
1031                     <img t-att-src='_s + "/web/static/src/img/down-arrow.png"' /></span>
1032             </td>
1033             <td width="16">
1034                 <button class="oe_button oe_field_button oe-m2o-cm-button">
1035                     <img t-att-src='_s + "/web/static/src/img/icons/gtk-go-forward.png"'/>
1036                 </button>
1037             </td>
1038         </tr>
1039         </table>
1040     </t>
1041     <t t-if="widget.get('effective_readonly')">
1042         <div>
1043             <a href="#" class="oe_form_uri"/>
1044         </div>
1045     </t>
1046 </t>
1047 <t t-name="FieldReference">
1048     <t t-if="!widget.get('effective_readonly')">
1049         <table class="oe_form_field_reference oe_frame oe_forms" border="0" cellpadding="0" cellspacing="0">
1050         <tr>
1051             <td t-attf-class="oe_form_frame_cell oe_form_selection oe_form_view_reference_selection">
1052             </td>
1053             <td t-attf-class="oe_form_frame_cell oe_form_many2one oe_form_view_reference_m2o" nowrap="true" style="display: none">
1054             </td>
1055         </tr>
1056         </table>
1057     </t>
1058     <t t-if="widget.get('effective_readonly')">
1059         <a href="#" class="oe_form_uri"/>
1060     </t>
1061 </t>
1062 <t t-name="FieldBoolean">
1063     <span class="oe_form_field_boolean">
1064         <input type="checkbox"
1065             t-att-id="widget.id_for_label"
1066             t-att-name="widget.name"
1067             t-att-tabindex="widget.node.attrs.tabindex"
1068             t-att-autofocus="widget.node.attrs.autofocus"
1069             class="field_boolean"/>
1070     </span>
1071 </t>
1072 <t t-name="FieldProgressBar">
1073     <div class="oe_form_field_progressbar" t-opentag="true">
1074         <span></span>
1075     </div>
1076 </t>
1077 <t t-name="FieldStatus.content">
1078     <ul class="oe-arrow-list">
1079         <t t-set="size" t-value="widget.to_show.length"/>
1080         <t t-foreach="_.range(size)" t-as="i">
1081             <li t-att-class="widget.to_show[i][0] === widget.selected_value ? 'oe-arrow-list-selected' : ''">
1082                 <span class="oe-arrow-list-before" t-if="i &gt; 0"></span><span><t t-esc="widget.to_show[i][1]"/></span><span class="oe-arrow-list-after" t-if="i &lt; size - 1"></span>
1083             </li>
1084         </t>
1085     </ul>
1086 </t>
1087 <t t-name="FieldStatus.content">
1088     <ul class="oe_form_steps">
1089         <t t-set="size" t-value="widget.to_show.length"/>
1090         <t t-foreach="_.range(size)" t-as="i">
1091             <li t-att-class="widget.to_show[i][0] === widget.selected_value ? 'oe_form_steps_active' : ''">
1092                 <t t-esc="widget.to_show[i][1]"/>
1093                 <img t-att-src='_s + "/web/static/src/img/form_steps.png"' class="oe_form_steps_arrow" t-if="i &lt; size - 1"/>
1094             </li>
1095         </t>
1096     </ul>
1097 </t>
1098 <t t-name="FieldBinaryImage">
1099     <table cellpadding="0" cellspacing="0" border="0" width="100%">
1100     <tr>
1101         <td class="oe_form_field-binary-image-placeholder" align="center">
1102
1103         </td>
1104     </tr>
1105     <tr>
1106         <td align="center" valign="bottom" height="25">
1107             <div class="oe-binary">
1108                 <table cellspacing="0" cellpadding="0" border="0">
1109                 <tr>
1110                     <td>
1111                         <div class="oe-binary-file-set">
1112                             <form class="oe-binary-form" t-att-target="widget.iframe"
1113                                 method="post" enctype="multipart/form-data" action="/web/binary/upload">
1114                                 <input type="hidden" name="session_id" value=""/>
1115                                 <input type="hidden" name="callback" t-att-value="widget.iframe"/>
1116                                 <button class="oe_button" type="button" title="Set Image">
1117                                     <img t-att-src='_s + "/web/static/src/img/icons/STOCK_DIRECTORY.png"'/>
1118                                 </button>
1119                                 <input type="file" class="oe-binary-file" name="ufile"
1120                                     t-att-tabindex="widget.node.attrs.tabindex"
1121                                     t-att-autofocus="widget.node.attrs.autofocus"
1122                                 />
1123                             </form>
1124                         </div>
1125                     </td>
1126                     <td>
1127                         <button class="oe_button oe-binary-file-clear" type="button" title="Clear">
1128                             <img t-att-src='_s + "/web/static/src/img/icons/STOCK_MISSING_IMAGE.png"'/>
1129                         </button>
1130                     </td>
1131                 </tr>
1132                 </table>
1133             </div>
1134             <div class="oe-binary-progress" style="display: none">
1135                 <img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16"/>
1136                 <b>Uploading ...</b>
1137             </div>
1138             <iframe t-att-id="widget.iframe" t-att-name="widget.iframe" style="display: none"/>
1139         </td>
1140     </tr>
1141     </table>
1142 </t>
1143 <t t-name="FieldBinaryImage-img">
1144     <img t-att-src='url' class="oe-binary-image field_image"
1145         t-att-border="widget.readonly ? 0 : 1"
1146         t-att-name="widget.name"
1147         t-att-width="widget.node.attrs.img_width || widget.node.attrs.width"
1148         t-att-height="widget.node.attrs.img_height || widget.node.attrs.height"
1149         t-att-style="'max-width: ' + (widget.$element.width() > 60 ? widget.$element.width() : 60) + 'px'"
1150     />
1151 </t>
1152 <t t-name="FieldBinaryFile">
1153     <t t-if="!widget.get('effective_readonly')">
1154         <table class="oe_form_field_binary" cellpadding="0" cellspacing="0" border="0">
1155         <tr>
1156             <td>
1157                 <input type="text" size="1" readonly="readonly"
1158                     t-att-name="widget.name"
1159                     t-att-tabindex="widget.node.attrs.tabindex"
1160                     t-att-autofocus="widget.node.attrs.autofocus"
1161                     class="field_binary"
1162                 />
1163             </td>
1164             <td class="oe-binary" nowrap="true">
1165                 <table cellspacing="0" cellpadding="0" border="0">
1166                 <tr>
1167                     <td>
1168                         <div class="oe-binary-file-set" style="width: 80px; height:22px;">
1169                             <form class="oe-binary-form" t-att-target="widget.iframe"
1170                                 method="post" enctype="multipart/form-data" action="/web/binary/upload">
1171                                 <input type="hidden" name="session_id" value=""/>
1172                                 <input type="hidden" name="callback" t-att-value="widget.iframe"/>
1173                                 <button class="oe_button oe_field_button" type="button" title="Set Image">
1174                                     <img t-att-src='_s + "/web/static/src/img/icons/STOCK_DIRECTORY.png"'/>
1175                                     <span>Select</span>
1176                                 </button>
1177                                 <input type="file" class="oe-binary-file" name="ufile"/>
1178                             </form>
1179                         </div>
1180                     </td>
1181                     <td>
1182                         <button class="oe_button oe-binary-file-save" type="button" title="Save As">
1183                             <img t-att-src='_s + "/web/static/src/img/icons/gtk-save.png"'/>
1184                             <span>Save As</span>
1185                         </button>
1186                     </td>
1187                     <td>
1188                         <button class="oe_button oe-binary-file-clear" type="button" title="Clear">
1189                             <img t-att-src='_s + "/web/static/src/img/icons/STOCK_MISSING_IMAGE.png"'/>
1190                             <span>Clear</span>
1191                         </button>
1192                     </td>
1193                 </tr>
1194                 </table>
1195             </td>
1196             <td class="oe-binary-progress" style="display: none" nowrap="true">
1197                 <img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16"/>
1198                 <b>Uploading ...</b>
1199                 <iframe t-att-id="widget.iframe" t-att-name="widget.iframe" style="display: none"/>
1200             </td>
1201         </tr>
1202         </table>
1203     </t>
1204     <t t-if="widget.get('effective_readonly')">
1205         <div>
1206             <a href="javascript:void(0)" class="oe_form_uri"/>
1207         </div>
1208     </t>
1209 </t>
1210 <t t-name="WidgetButton">
1211     <button type="button" class="oe_button oe_form_button"
1212         t-att-tabindex="widget.node.attrs.tabindex"
1213         t-att-autofocus="widget.node.attrs.autofocus">
1214         <img t-if="widget.node.attrs.icon" t-att-src="_s + '/web/static/src/img/icons/' + widget.node.attrs.icon + '.png'" width="16" height="16"/>
1215         <span t-if="widget.string"><t t-esc="widget.string"/></span>
1216     </button>
1217 </t>
1218 <t t-name="WidgetButton.tooltip" t-extend="WidgetLabel.tooltip">
1219     <t t-jquery="div.oe_tooltip_string" t-operation="replace">
1220         <div class="oe_tooltip_string" t-if="debug || widget.string">
1221             <t t-if="debug">
1222                 Button
1223                 <t t-if="widget.string">: </t>
1224                 <t t-if="!widget.string"> (no string)</t>
1225             </t>
1226             <t t-esc="widget.string"/>
1227         </div>
1228     </t>
1229     <t t-jquery="ul.oe_tooltip_technical" t-operation="append">
1230         <li t-if="widget.node.attrs.special" data-item="special">
1231             <span class="oe_tooltip_technical_title">Special:</span>
1232             <t t-esc="widget.node.attrs.special"/>
1233         </li>
1234         <t t-set="button_type" t-value="widget.node.attrs.type"/>
1235         <li t-if="button_type" data-item="button_type">
1236             <span class="oe_tooltip_technical_title">Button Type:</span>
1237             <t t-esc="button_type"/>
1238         </li>
1239         <li t-if="button_type === 'object'" data-item="button_method">
1240             <span class="oe_tooltip_technical_title">Method:</span>
1241             <t t-esc="widget.node.attrs.name"/>
1242         </li>
1243         <li t-if="button_type === 'action'" data-item="button_action">
1244             <span class="oe_tooltip_technical_title">Action ID:</span>
1245             <t t-esc="widget.node.attrs.name"/>
1246         </li>
1247     </t>
1248 </t>
1249
1250 <t t-name="TranslateDialog">
1251     <table t-if="widget.view.translatable_fields" class="oe_form oe_translation_form" border="0" cellpadding="0" cellspacing="0" width="100%">
1252     <tr>
1253         <td class="oe_form_separator" width="1%" nowrap="nowrap">
1254             <div class="oe_horizontal_separator">Field</div>
1255         </td>
1256         <th t-foreach="widget.languages" align="left">
1257             <div class="oe_horizontal_separator"><t t-esc="name"/></div>
1258         </th>
1259     </tr>
1260     <tr t-foreach="widget.view.translatable_fields" t-as="field" t-att-data-field="field.name">
1261         <td class="oe_form_group_cell" width="1%" nowrap="nowrap">
1262             <label class="oe_label"><t t-esc="field.node.attrs.string"/>:</label>
1263         </td>
1264         <td t-foreach="widget.languages" t-as="lg" class="oe_form_group_cell">
1265             <input t-if="field.type == 'char'" type="text" t-attf-name="#{lg.code}-#{field.name}" value="" data-value="" class="oe_trad_field" style="width: 100%"/>
1266             <textarea t-if="field.type == 'text'" t-attf-name="#{lg.code}-#{field.name}" data-value="" class="oe_trad_field" style="width: 100%"></textarea>
1267         </td>
1268     </tr>
1269     </table>
1270 </t>
1271
1272 <t t-name="One2Many.viewmanager" t-extend="ViewManager">
1273     <t t-jquery="span.oe_view_title_text" t-operation="replace"/>
1274
1275     <t t-jquery=".oe-view-manager-header">
1276         this.attr('t-if', 'views.length != 1');
1277     </t>
1278 </t>
1279 <t t-name="One2Many.formview" t-extend="FormView">
1280     <t t-jquery=".oe_form_buttons" t-operation="inner">
1281         <button type="button" class="oe_button oe_form_button_create">Add</button>
1282     </t>
1283 </t>
1284 <t t-name="One2Many.listview" t-extend="ListView">
1285     <t t-jquery="thead.ui-widget-header > tr:first">
1286         this.removeAttr('t-if');
1287     </t>
1288
1289     <t t-jquery="tfoot &gt; tr:last-child" t-operation="replace"/>
1290
1291     <t t-jquery="td.oe-actions">
1292         this.removeAttr('t-if');
1293     </t>
1294     <t t-jquery="td.oe-actions" t-operation="prepend">
1295         <h3 class="oe_view_title"><t t-esc="fields_view.arch.attrs.string"/></h3>
1296     </t>
1297 </t>
1298
1299 <div t-name="SearchView" class="oe_searchview">
1300 </div>
1301 <t t-name="SearchView.managed-filters">
1302     <option class="oe-filters-title" value="">Filters</option>
1303     <optgroup label="-- Filters --">
1304         <t t-foreach="filters" t-as="filter">
1305             <option t-attf-value="get:#{filter_index}"
1306                     t-att-disabled="filter.disabled and 'disabled'"
1307                     t-att-title="filter.disabled and disabled_filter_message">
1308                 <t t-esc="filter.name"/>
1309             </option>
1310         </t>
1311     </optgroup>
1312     <optgroup label="-- Actions --">
1313         <option value="advanced_filter">Add Advanced Filter</option>
1314         <option value="save_filter">Save Filter</option>
1315         <option value="add_to_dashboard">Add to Dashboard</option>
1316         <option value="manage_filters">Manage Filters</option>
1317     </optgroup>
1318 </t>
1319 <t t-name="SearchView.managed-filters.add">
1320     <div>
1321         <p>Filter Name:</p>
1322         <input type="text"/>
1323         <p>(Any existing filter with the same name will be replaced)</p>
1324     </div>
1325 </t>
1326 <t t-name="SearchView.add_to_dashboard">
1327     <div class="oe_forms">
1328         <p><b>Select Dashboard to add this filter to:</b></p>
1329         <select style="width: 100%; margin-right: 1em;">
1330             <option t-foreach="dashboards" t-as="menu" t-att-value="menu.id" t-att-selected="(menu.id == selected_menu_id) || undefined"><t t-esc="menu.name"/></option>
1331         </select>
1332         <p><b>Title of new Dashboard item:</b></p>
1333         <input type="text" style="width: 100%; margin-right: 1em;"/>
1334     </div>
1335 </t>
1336 <t t-name="SearchView.render_lines">
1337     <table class="oe-searchview-render-line" border="0" cellspacing="0" cellpadding="0"
1338            t-foreach="lines" t-as="line">
1339         <tr>
1340             <td t-foreach="line" t-as="widget" class="oe_searchview_field">
1341                 <t t-raw="widget.render(defaults)"/>
1342             </td>
1343         </tr>
1344     </table>
1345 </t>
1346 <button t-name="SearchView.filter" type="button"
1347         t-att-id="element_id"
1348         t-att-title="attrs.help"
1349         t-att-class="classes.join(' ')"
1350         t-att-style="style"
1351         t-att-autofocus="attrs.default_focus === '1' ? 'autofocus' : undefined">
1352     <img t-att-src="_s + '/web/static/src/img/icons/' + (attrs.icon || 'gtk-home') + '.png'" width="16" height="16"/>
1353     <br t-if="attrs.string"/>
1354     <t t-esc="attrs.string"/>
1355 </button>
1356 <ul t-name="SearchView.filters">
1357     <li t-foreach="widget.filters" t-as="filter">
1358         <t t-esc="filter.attrs.string or filter.attrs.name or 'Ω'"/>
1359     </li>
1360 </ul>
1361 <t t-name="SearchView.filters.facet">
1362     <div class="category oe_filter_category"><t t-esc="facet.get('category')"/></div>
1363
1364     <t t-set="val" t-value="facet.get('json')"/>
1365
1366     <div t-if="!(val instanceof Array)" class="search_facet_input_container">
1367         <t t-esc="facet.get('value')"/>
1368     </div>
1369     <t t-if="val instanceof Array">
1370         <div class="search_facet_input_container"
1371                 t-foreach="facet.get('json')" t-as="filter">
1372             <t t-esc="filter.attrs.string || filter.attrs.name"/>
1373         </div>
1374     </t>
1375
1376     <div class="search_facet_remove VS-icon VS-icon-cancel"/>
1377 </t>
1378 <t t-name="SearchView.field">
1379     <label t-att-class="'oe_label' + (attrs.help ? '_help' : '')"
1380            t-att-title="attrs.help"
1381            t-att-for="element_id"
1382            t-att-style="style">
1383         <t t-esc="attrs.string || attrs.name"/>
1384         <span t-if="attrs.help">?</span>
1385     </label>
1386     <div t-att-style="style">
1387         <input type="text" size="15" t-att-name="attrs.name"
1388                t-att-autofocus="attrs.default_focus === '1' ? 'autofocus' : undefined"
1389                t-att-id="element_id"
1390                t-att-value="defaults[attrs.name] || ''"/>
1391         <t t-if="filters.length" t-raw="filters.render(defaults)"/>
1392     </div>
1393 </t>
1394 <t t-name="SearchView.date">
1395     <label t-att-class="'oe_label' + (attrs.help ? '_help' : '')"
1396            t-att-title="attrs.help"
1397            t-att-for="element_id"
1398            t-att-style="style">
1399         <t t-esc="attrs.string || attrs.name"/>
1400         <span t-if="attrs.help">?</span>
1401     </label>
1402     <div t-att-style="style">
1403         <span t-att-id="element_id"/>
1404         <t t-if="filters.length" t-raw="filters.render(defaults)"/>
1405     </div>
1406 </t>
1407 <t t-name="SearchView.field.selection">
1408     <label t-att-title="attrs.help"
1409            t-att-class="'oe_label' + (attrs.help ? '_help' : '')"
1410            t-att-for="element_id"
1411            t-att-style="style">
1412         <t t-esc="attrs.string || attrs.name"/>
1413         <span t-if="attrs.help">?</span>
1414     </label>
1415     <div t-att-style="style">
1416         <select t-att-name="attrs.name" t-att-id="element_id"
1417                 t-att-autofocus="attrs.default_focus === '1' || undefined">
1418             <option t-if="prepend_empty"/>
1419             <t t-foreach="attrs.selection" t-as="option">
1420                 <t t-set="selected" t-value="defaults[attrs.name] === option[0]"/>
1421                 <option t-if="selected"
1422                         t-attf-selected="selected"
1423                         t-att-value="option_index">
1424                     <t t-esc="option[1]"/>
1425                 </option>
1426                 <option t-if="!selected" t-att-value="option_index">
1427                     <t t-esc="option[1]"/>
1428                 </option>
1429             </t>
1430         </select>
1431         <t t-if="filters.length" t-raw="filters.render(defaults)"/>
1432     </div>
1433 </t>
1434 <t t-name="SearchView.util.expand">
1435     <div t-att-class="'searchview_group ' + (expand == '0' ? 'folded' : 'expanded')">
1436         <a t-if="label" class="searchview_group_string" href="#">
1437             <t t-esc="label"/>
1438         </a>
1439         <div class="searchview_group_content">
1440             <t t-raw="content"/>
1441         </div>
1442     </div>
1443 </t>
1444 <t t-name="SearchView.group">
1445     <t t-call="SearchView.util.expand">
1446         <t t-set="expand" t-value="attrs.expand"/>
1447         <t t-set="label" t-value="attrs.string"/>
1448         <t t-set="content">
1449             <t t-call="SearchView.render_lines"/>
1450         </t>
1451     </t>
1452 </t>
1453 <div t-name="SearchView.advanced" class="oe_searchview_advanced">
1454     <h4>Advanced Search...</h4>
1455     <form>
1456         <ul>
1457
1458         </ul>
1459         <button class="oe_add_condition" type="button">Add a condition</button>
1460         <button class="oe_apply" type="submit">Apply</button>
1461     </form>
1462 </div>
1463 <t t-name="SearchView.extended_search.proposition">
1464     <li>
1465         <select class="searchview_extended_prop_field">
1466             <t t-foreach="widget.attrs.fields" t-as="field">
1467                 <option t-if="typeof field.store === 'undefined' || field.store || field.fnct_search"
1468                         t-att="{'selected': field === widget.attrs.selected ? 'selected' : null}"
1469                         t-att-value="field.name">
1470                     <t t-esc="field.string"/>
1471                 </option>
1472             </t>
1473         </select>
1474         <select class="searchview_extended_prop_op"/>
1475         <span class="searchview_extended_prop_value"/>
1476         <a class="searchview_extended_delete_prop"
1477                 href="javascript:void(0)"><span> </span></a>
1478     </li>
1479 </t>
1480 <t t-name="SearchView.extended_search.proposition.char">
1481     <input t-att-id="widget.element_id" class="field_char"/>
1482 </t>
1483 <t t-name="SearchView.extended_search.proposition.empty">
1484     <span t-att-id="widget.element_id"></span>
1485 </t>
1486 <t t-name="SearchView.extended_search.proposition.integer">
1487     <input type="number" t-att-id="widget.element_id" class="field_integer" step="1"/>
1488 </t>
1489 <t t-name="SearchView.extended_search.proposition.float">
1490     <input type="number" t-att-id="widget.element_id" class="field_float" step="0.01"/>
1491 </t>
1492 <t t-name="SearchView.extended_search.proposition.boolean">
1493 </t>
1494 <t t-name="SearchView.extended_search.proposition.selection">
1495     <select t-att-id="widget.element_id">
1496         <t t-foreach="widget.field.selection" t-as="element">
1497         <option t-att-value="element[0]"><t t-esc="element[1]"/></option>
1498         </t>
1499     </select>
1500 </t>
1501 <t t-name="SelectCreatePopup">
1502     <div>
1503         <table style="width:100%">
1504             <tr style="width:100%">
1505                 <td style="width:100%">
1506                     <div class="oe-select-create-popup-view-search" style="width:100%"></div>
1507                 </td>
1508             </tr>
1509             <tr style="width:100%">
1510                 <td style="width:100%">
1511                     <div class="oe-select-create-popup-view-list" style="width:100%"></div>
1512                 </td>
1513             </tr>
1514         </table>
1515         <div class="oe-select-create-popup-view-form" style="width:100%"></div>
1516     </div>
1517 </t>
1518 <t t-name="SelectCreatePopup.search.buttons">
1519     <button type="button" class="oe_button oe_selectcreatepopup-search-select" disabled="disabled">Select</button>
1520     <button type="button" class="oe_button oe_selectcreatepopup-search-close">Cancel</button>
1521 </t>
1522 <t t-name="SelectCreatePopup.form.buttons">
1523     <t t-if="widget.options.disable_multiple_selection">
1524         <button type="button" class="oe_button oe_selectcreatepopup-form-save">Save</button>
1525     </t>
1526     <t t-if="! widget.options.disable_multiple_selection">
1527         <button type="button" class="oe_button oe_selectcreatepopup-form-save-new">Save &amp; New</button>
1528         <button type="button" class="oe_button oe_selectcreatepopup-form-save">Save &amp; Close</button>
1529     </t>
1530     <button type="button" class="oe_button oe_selectcreatepopup-form-close">Cancel</button>
1531 </t>
1532 <t t-name="FormOpenPopup">
1533     <div>
1534         <div class="oe-form-open-popup-form-view" style="width:100%"></div>
1535     </div>
1536 </t>
1537 <t t-name="FormOpenPopup.form.buttons">
1538     <button type="button" class="oe_button oe_formopenpopup-form-save">Save</button>
1539     <button type="button" class="oe_button oe_formopenpopup-form-close">Cancel</button>
1540 </t>
1541 <t t-extend="ListView.row">
1542     <!-- adds back padding to row being rendered after edition, if necessary
1543          (if not deletable add back padding), otherwise the row being added is
1544          missing columns
1545      -->
1546     <t t-jquery="&gt; :last" t-operation="after">
1547         <td t-if="edited and !options.deletable" class="oe-listview-padding"/>
1548     </t>
1549 </t>
1550
1551 <t t-name="view_editor">
1552     <table class="oe_view_editor">
1553         <t t-call="view_editor.row"/>
1554     </table>
1555 </t>
1556 <t t-name="view_editor.row">
1557     <tr  t-att-id="'viewedit-' + rec.id"  t-att-level="rec.level" t-foreach="data" t-as="rec">
1558         <td width="90%">
1559             <table class="oe_view_editor_field">
1560                 <tr>
1561                     <td width="16px" t-att-style="'background-position: ' + 20*rec.level + 'px; padding-left: ' + 20*rec.level + 'px'">
1562                         <img t-if="rec.child_id.length" t-att-id="'parentimg-' + rec.id"
1563                             src="/web/static/src/img/collapse.gif" width="16" height="16" border="0"/>
1564                     </td>
1565                     <td style="cursor: pointer;">
1566                         <a style="text-decoration:none" href="javascript:void(0);">
1567                             <t t-esc="rec.name"/>
1568                         </a>
1569                     </td>
1570                 </tr>
1571             </table>
1572         </td>
1573         <td width="2%">
1574             <img t-if="rec.att_list.length"
1575                 id="side-add" src="/web/static/src/img/icons/gtk-add.png" style="cursor: pointer;"/>
1576         </td>
1577         <td width="2%">
1578             <img  id="side-remove" src="/web/static/src/img/icons/gtk-remove.png" style="cursor: pointer;"/>
1579         </td>
1580         <td width="2%">
1581             <img t-if="rec.att_list.length and !_.include(no_properties, rec.att_list[0])"
1582                 id="side-edit" src="/web/static/src/img/icons/gtk-edit.png" style="cursor: pointer;"/>
1583         </td>
1584         <td width="2%">
1585             <img t-if="rec.att_list.length"
1586                 id="side-up" src="/web/static/src/img/icons/gtk-go-up.png" style="cursor: pointer;"/>
1587         </td>
1588         <td width="2%">
1589             <img t-if="rec.att_list.length"
1590                 id="side-down" src="/web/static/src/img/icons/gtk-go-down.png" style="cursor: pointer;"/>
1591         </td>
1592         <t t-if="rec.child_id.length">
1593             <t t-set="data" t-value="rec.child_id"/>
1594             <t t-call="view_editor.row"/>
1595         </t>
1596     </tr>
1597 </t>
1598 <t t-name="vieweditor_char">
1599     <input type="text" t-att-id="widget.name" class="field_char" size="50"/>
1600 </t>
1601 <t t-name="vieweditor_selection">
1602     <select t-att-id="widget.name" >
1603         <t t-if="widget.selection" t-foreach="widget.selection" t-as="option">
1604             <option
1605                 t-att-value="typeof option === 'object' ? option[0] : option">
1606                 <t t-esc="typeof option === 'object' ? option[1] : option"/>
1607             </option>
1608         </t>
1609     </select>
1610 </t>
1611 <t t-name="vieweditor_boolean">
1612     <input type="checkbox" t-att-id="widget.name"/>
1613 </t>
1614
1615 <t t-name="ExportView">
1616     <a id="exportview" href="javascript: void(0)" style="text-decoration: none;color: #3D3D3D;">Export</a>
1617 </t>
1618 <table t-name="ExportTreeView" class="oe-export"
1619        style="background-color: #F3F3F3;">
1620     <tr>
1621         <td colspan="3">
1622             This wizard will export all data that matches the current search criteria to a CSV file.
1623             You can export all data or only the fields that can be reimported after modification.
1624         </td>
1625     </tr>
1626     <tr>
1627         <td colspan="3">
1628             <label for="import_compat">Export Type:</label>
1629             <select id="import_compat" name="import_compat">
1630                 <option value="yes">Import Compatible Export</option>
1631                 <option value="">Export all Data</option>
1632             </select>
1633
1634             <label for="export_format">Export Formats</label>
1635             <select id="export_format" name="export_format"></select>
1636         </td>
1637     </tr>
1638
1639     <tr>
1640         <th>Available fields</th>
1641         <th/>
1642         <th>
1643             Fields to export
1644             <a style="color: blue; text-decoration: none;" href="#" id="export_new_list">Save fields list</a>
1645             <div id="savenewlist"></div>
1646             <div id="ExistsExportList"></div>
1647         </th>
1648     </tr>
1649     <tr style="height: 400px;">
1650         <td class="oe_export_fields_selector_left">
1651             <div id="left_field_panel">
1652             </div>
1653         </td>
1654         <td class="oe_export_fields_selector_center">
1655             <!-- TODO: replace ids by 'oe_*' classes -->
1656             <button class="oe_button" id="add_field">Add</button>
1657             <button class="oe_button" id="remove_field">Remove</button>
1658             <button class="oe_button" id="remove_all_field">Remove All</button>
1659         </td>
1660         <td class="oe_export_fields_selector_right">
1661             <select name="fields_list" id="fields_list"
1662                     multiple="multiple"></select>
1663         </td>
1664     </tr>
1665 </table>
1666 <table t-name="ExportTreeView-Secondary"
1667        id="field-tree-structure" class="oe_export_fields_selector_export"
1668        cellspacing="0" cellpadding="0">
1669     <tr><th class="oe_export_tree_header"> Name </th></tr>
1670     <t t-call="ExportTreeView-Secondary.children"/>
1671 </table>
1672 <tr t-name="ExportTreeView-Secondary.children"
1673     t-foreach="fields" t-as="field"
1674     t-att-id="'treerow-' + field.id" class="oe_export_row">
1675     <td>
1676         <table class="tree_grid" border="0">
1677             <tr class="oe_export_row">
1678                 <t t-foreach="(field.id).split('/')" t-as="level" >
1679                     <t t-if="(field.id).split('/')[0] != level">
1680                         <td width="18" t-translation="off">&amp;nbsp;</td>
1681                     </t>
1682                 </t>
1683                 <td valign="top" align="left" style="cursor: pointer;" width="18">
1684                     <t t-if="field.children">
1685                         <t t-if="(field.id).split('/').length != 3">
1686                             <img t-att-id="'parentimg-' + field.id" t-att-src='_s + "/web/static/src/img/expand.gif"' width="16" height="16" border="0"/>
1687                         </t>
1688                     </t>
1689                 </td>
1690                 <td id="tree-column" valign="middle" align="left" style="cursor: pointer;">
1691                     <a t-att-id="'export-' + field.id"  t-att-string="field.string" href="javascript: void(0);" style="text-decoration: none;">
1692                         <t t-esc="field.string"/>
1693                     </a>
1694                 </td>
1695             </tr>
1696         </table>
1697     </td>
1698 </tr>
1699 <t t-name="ExportNewList">
1700     <tr>
1701         <th><label>Save as:</label></th>
1702         <td><input size="10" type="text" id="savelist_name"/></td>
1703         <td><button class="oe_button oe_export_button_export" id="add_export_list">Ok</button></td>
1704     </tr>
1705 </t>
1706 <t t-name="Exists.ExportList">
1707     <label for="saved_export_list">Saved exports:</label>
1708
1709     <select id="saved_export_list">
1710         <option></option>
1711         <t t-foreach="existing_exports" t-as="export">
1712             <option t-att-value="export.id"><t t-esc="export.name"/></option>
1713         </t>
1714     </select>
1715     <button class="oe_button oe_export_button_export" id="delete_export_list" type="button">Delete</button>
1716 </t>
1717
1718 <t t-name="ImportView">
1719     <a id="importview" href="javascript: void(0)" style="text-decoration: none;color: #3D3D3D;">Import</a>
1720 </t>
1721 <t t-name="ImportDataView">
1722 <form name="import_data" id="import_data" action="" method="post" enctype="multipart/form-data"
1723         class="oe-import oe-import-no-result">
1724     <input type="hidden" name="session_id" t-att-value="widget.session.session_id"/>
1725     <h2 class="separator horizontal">1. Import a .CSV file</h2>
1726     <p>Select a .CSV file to import. If you need a sample of file to import,
1727        you should use the export tool with the "Import Compatible" option.
1728     </p>
1729     <p>
1730         <label for="csvfile">CSV File:</label>
1731         <input type="file" id="csvfile" size="50" name="csvfile"/>
1732     </p>
1733     <h2 class="separator horizontal oe-import-result">2. Check your file format</h2>
1734     <div id="result" class="oe-import-result"></div>
1735     <fieldset class="oe-closed oe-import-result">
1736         <legend>Import Options</legend>
1737         <table>
1738             <tr>
1739                 <td colspan="4">
1740                     <label for="file_has_headers">Does your file have titles?</label>
1741                     <input type="checkbox" checked="checked"
1742                            id="file_has_headers"/>
1743                 </td>
1744             </tr>
1745             <tr>
1746                 <td><label for="csv_separator">Separator:</label></td>
1747                 <td><input type="text" name="csvsep" id="csv_separator" value=","/></td>
1748                 <td><label for="csv_delimiter">Delimiter:</label></td>
1749                 <td><input type="text" name="csvdel" id="csv_delimiter" value='"'/></td>
1750             </tr>
1751             <tr>
1752                 <td><label for="csv_encoding">Encoding:</label></td>
1753                 <td>
1754                     <select name="csvcode" id="csv_encoding">
1755                         <option value="utf-8">UTF-8</option>
1756                         <option value="latin1">Latin 1</option>
1757                     </select>
1758                 </td>
1759                 <td><label for="csv_skip" title="For use if CSV files have titles on multiple lines, skips more than a single line during import">
1760                     Lines to skip<sup>?</sup>:</label></td>
1761                 <td><input type="number" id="csv_skip" value="0" min="0"/></td>
1762             </tr>
1763         </table>
1764     </fieldset>
1765 </form>
1766 </t>
1767 <t t-name="ImportView.result">
1768     <table class="oe_import_grid" width="100%" style="margin: 5px 0;">
1769         <tr t-if="headers" class="oe_import_grid-header">
1770             <td t-foreach="headers" t-as="header" class="oe_import_grid-cell">
1771                 <t t-esc="header"/></td>
1772         </tr>
1773         <tr>
1774             <td t-foreach="records[0]" t-as="column">
1775                 <input class="sel_fields" placeholder="--- Don't Import ---"/><span class="oe-m2o-drop-down-button">
1776                         <img t-att-src='_s + "/web/static/src/img/down-arrow.png"' /></span>
1777             </td>
1778         </tr>
1779         <tr t-foreach="records" t-as="record" class="oe_import_grid-row">
1780             <td t-foreach="record" t-as="cell" class="oe_import_grid-cell">
1781                 <t t-esc="cell"/></td>
1782         </tr>
1783     </table>
1784 </t>
1785 <t t-name="ImportView.error">
1786     <p style="white-space:pre;">The import failed due to:<t t-esc="error.message"/></p>
1787     <t t-if="error.preview">
1788         <p>Here is a preview of the file we could not import:</p>
1789         <pre><t t-esc="error.preview"/></pre>
1790     </t>
1791 </t>
1792
1793 </templates>