<t t-name="ViewManager">
<div class="oe_view_manager">
- <div class="oe_view_manager_header">
- <div class="oe_view_manager_row">
- <h2 class="oe_view_title" t-if="widget.flags.display_title !== false">
- <span class="oe_view_title_text"><t t-esc="widget.display_title()"/></span>
- </h2>
- <div class="oe_view_manager_view_search" t-opentag="true"/>
- </div>
- <div class="oe_view_manager_row">
- <div class="oe_view_manager_buttons"/>
- <ul class="oe_view_manager_switch oe_button_group oe_right">
- <t t-if="widget.views_src.length != 1" t-foreach="widget.views_src" t-as="view">
- <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">
- </a></li>
- </t>
- </ul>
- <div class="oe_view_manager_pager"/>
- <div class="oe_view_manager_sidebar"/>
- </div>
- </div>
+ <table class="oe_view_manager_header2">
+ <col width="33%"/>
+ <col width="33%"/>
+ <col width="34%"/>
+ <tr>
+ <td colspan="2">
+ <h2 class="oe_view_title" t-if="widget.flags.display_title !== false">
+ <span class="oe_view_title_text"><t t-esc="widget.display_title()"/></span>
+ </h2>
+ </td>
+ <td> <div class="oe_view_manager_view_search" t-opentag="true"/> </td>
+ </tr>
+ <tr>
+ <td> <div class="oe_view_manager_buttons"/> </td>
+ <td> <div class="oe_view_manager_sidebar"/> </td>
+ <td>
+ <ul class="oe_view_manager_switch oe_button_group oe_right">
+ <t t-if="widget.views_src.length != 1" t-foreach="widget.views_src" t-as="view">
+ <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">
+ </a></li>
+ </t>
+ </ul>
+ <div class="oe_view_manager_pager oe_right"/>
+ </td>
+ </tr>
+ </table>
<div class="oe_view_manager_body">
<t t-foreach="widget.views_src" t-as="view">
<div t-attf-class="oe_view_manager_view_#{view.view_type}"/>
</t>
<t t-name="ViewManagerDebug">
<option value="">Debug View#<t t-esc="view.fields_view.view_id"/></option>
- <option t-if="_.indexOf(['form', 'page'], view_manager.active_view) gt -1" value="perm_read" data-views="form,page">View Log (perm_read)</option>
+ <option t-if="view_manager.active_view === 'form'" value="perm_read" data-views="form,page">View Log (perm_read)</option>
+ <option t-if="view_manager.active_view === 'form'" value="toggle_layout_outline">Toggle Form Layout Outline</option>
<option value="fields">View Fields</option>
<option value="fvg">Fields View Get</option>
<t t-if="view_manager.session.uid === 1">
</div>
</t>
<t t-name="ViewPager">
- <span class="oe_pager_value">
+ <div class="oe_pager_value">
<t t-raw="__content__"/>
- </span>
+ </div>
<ul class="oe_pager_group">
<!--
<button class="oe_button oe_button_pager" type="button" data-pager-action="first">
<button class="oe_dropdown_toggle"><t t-esc="section.label"/></button>
<ul class="oe_dropdown_menu">
<li t-foreach="widget.items[section.name]" t-as="item" t-att-class="item.classname">
- <a class="oe_sidebar_action_a" t-att-title="item.title" href="#" t-att-data-section="section.name" t-att-data-index="item_index">
+ <a class="oe_sidebar_action_a" t-att-title="item.title" t-att-data-section="section.name" t-att-data-index="item_index" t-att-href="item.url" target="_blank">
<t t-raw="item.label"/>
</a>
</li>
+ <li t-if="section.name == 'files'" class="oe_sidebar_add" style="display:none;">
+ Input type file stuff
+ </li>
</ul>
</div>
</t>
</div>
</t>
+<t t-name="Sidebar.attachments">
+ <div class="oe-sidebar-attachments-toolbar">
+ <div class="oe-binary-file-set" style="float: right">
+ <form class="oe-binary-form" t-attf-target="#{element_id}_iframe"
+ method="post" enctype="multipart/form-data" action="/web/binary/upload_attachment">
+ <input type="hidden" name="session_id" t-att-value="session.session_id"/>
+ <input type="hidden" name="callback" t-attf-value="#{element_id}_iframe"/>
+ <input type="hidden" name="model" t-att-value="view.dataset.model"/>
+ <input type="hidden" name="id" t-att-value="view.datarecord.id"/>
+ <button class="oe_button" type="button">
+ <img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16" style="display: none"/>
+ <span>Add</span>
+ </button>
+ <input type="file" class="oe-binary-file" name="ufile" title="Add attachment"
+ t-att-onclick="view.datarecord.id ? null : 'alert(\'No record selected ! You can only attach to existing record.\'); return false;'"/>
+ </form>
+ <iframe t-attf-id="#{element_id}_iframe" t-attf-name="#{element_id}_iframe" style="display: none"/>
+ </div>
+ </div>
+ <br style="clear: both"/>
+ <ul class="oe-sidebar-attachments-items">
+ <li t-foreach="attachments" t-as="attachment">
+ <t t-if="attachment.type == 'binary'" t-set="attachment.url" t-value="_s + '/web/binary/saveas?session_id='
+ + session.session_id + '&model=ir.attachment&id=' + attachment.id
+ + '&field=datas&filename_field=name&t=' + (new Date().getTime())"/>
+ <a class="oe-sidebar-attachments-link" t-att-href="attachment.url" target="_blank">
+ <t t-esc="attachment.name"/>
+ </a>
+ <a href="#" class="oe-sidebar-attachment-delete" t-att-data-id="attachment.id" t-attf-title="Delete the attachment #{attachment.name}">
+ <img t-att-src='_s + "/web/static/src/img/attachments-close.png"' width="15" height="15" border="0"/>
+ </a>
+ </li>
+ </ul>
+</t>
<t t-name="TreeView">
<select t-if="toolbar" style="width: 30%">
</tr>
</tfoot>
</table>
-<t t-name="ListView.buttons">
- <div t-if="!widget.no_leaf and widget.options.action_buttons !== false" class="oe_list_buttons">
+<div t-name="ListView.buttons" class="oe_list_buttons">
+ <t t-if="!widget.no_leaf and widget.options.action_buttons !== false">
<button type="button" class="oe_button oe_list_add" t-if="widget.options.addable">
<t t-esc="widget.options.addable"/>
</button>
<button type="button" class="oe_button oe_list_delete" t-if="widget.options.selectable and widget.options.deletable">
Delete
</button>
- </div>
-</t>
-<t t-name="Listview.pager">
- <div t-if="!widget.no_leaf and widget.options.pager !== false" class="oe_list_pager" t-att-colspan="widget.columns_count">
- <t t-call="ViewPager">
+ </t>
+</div>
+<t t-name="ListView.pager">
+ <div class="oe_list_pager" t-att-colspan="widget.columns_count">
+ <t t-if="!widget.no_leaf and widget.options.pager !== false" t-call="ViewPager">
<span class="oe-pager-state">
</span>
</t>
</td>
</t>
<td t-if="options.deletable" class='oe-record-delete' width="1">
- <button type="button" name="delete"></button>
+ <button type="button" name="delete" class="oe_i">d</button>
</td>
</tr>
<t t-name="FormView">
<div class="oe_formview">
- <div class="oe_form_header">
- <div class="oe_form_buttons" t-if="widget.options.action_buttons !== false">
- <button type="button" class="oe_button oe_form_button_save">Save</button>
- <button type="button" class="oe_button oe_form_button_cancel">Cancel</button>
- </div>
- <div class="oe_form_pager" t-if="widget.options.pager !== false">
- <t t-call="ViewPager">
- <span class="oe_pager_index">0</span><span class="oe_pager_separator"> / </span><span class="oe_pager_count">0</span>
- </t>
- </div>
- <div class="oe_form_sidebar">
- </div>
- </div>
- <div style="clear: both;"/>
- <div class="oe_form_container"/>
- </div>
-</t>
-<t t-name="FormView">
- <div class="oe_formview">
<div class="oe_form_buttons"/>
<div class="oe_form_sidebar"/>
<div class="oe_form_pager"/>
<div class="oe_form_container"/>
</div>
</t>
-<t t-name="FormView.buttons">
- <div class="oe_form_buttons" t-if="widget.options.action_buttons !== false">
+<div t-name="FormView.buttons" class="oe_form_buttons">
+ <t t-if="widget.options.action_buttons !== false">
<span class="oe_form_buttons_view">
<button type="button" class="oe_button oe_form_button_edit">Edit</button>
<button type="button" class="oe_button oe_form_button_create">Create</button>
<button type="button" class="oe_button oe_form_button_save">Save</button>
<button type="button" class="oe_button oe_form_button_cancel">Cancel</button>
</span>
- </div>
-</t>
+ </t>
+</div>
<t t-name="FormView.pager">
- <div class="oe_form_pager" t-if="widget.options.pager !== false">
- <t t-call="ViewPager">
+ <div class="oe_form_pager">
+ <t t-if="widget.options.pager !== false" t-call="ViewPager">
<span class="oe_pager_index">0</span><span class="oe_pager_separator"> / </span><span class="oe_pager_count">0</span>
</t>
</div>
</t>
-<t t-name="FormView.sidebar.attachments">
- <div class="oe-sidebar-attachments-toolbar">
- <div class="oe-binary-file-set" style="float: right">
- <form class="oe-binary-form" t-attf-target="#{element_id}_iframe"
- method="post" enctype="multipart/form-data" action="/web/binary/upload_attachment">
- <input type="hidden" name="session_id" t-att-value="session.session_id"/>
- <input type="hidden" name="callback" t-attf-value="#{element_id}_iframe"/>
- <input type="hidden" name="model" t-att-value="view.dataset.model"/>
- <input type="hidden" name="id" t-att-value="view.datarecord.id"/>
- <button class="oe_button" type="button">
- <img t-att-src='_s + "/web/static/src/img/throbber.gif"' width="16" height="16" style="display: none"/>
- <span>Add</span>
- </button>
- <input type="file" class="oe-binary-file" name="ufile" title="Add attachment"
- t-att-onclick="view.datarecord.id ? null : 'alert(\'No record selected ! You can only attach to existing record.\'); return false;'"/>
- </form>
- <iframe t-attf-id="#{element_id}_iframe" t-attf-name="#{element_id}_iframe" style="display: none"/>
- </div>
- </div>
- <br style="clear: both"/>
- <ul class="oe-sidebar-attachments-items">
- <li t-foreach="attachments" t-as="attachment">
- <t t-if="attachment.type == 'binary'" t-set="attachment.url" t-value="_s + '/web/binary/saveas?session_id='
- + session.session_id + '&model=ir.attachment&id=' + attachment.id
- + '&field=datas&filename_field=name&t=' + (new Date().getTime())"/>
- <a class="oe-sidebar-attachments-link" t-att-href="attachment.url" target="_blank">
- <t t-esc="attachment.name"/>
- </a>
- <a href="#" class="oe-sidebar-attachment-delete" t-att-data-id="attachment.id" t-attf-title="Delete the attachment #{attachment.name}">
- <img t-att-src='_s + "/web/static/src/img/attachments-close.png"' width="15" height="15" border="0"/>
- </a>
- </li>
- </ul>
-</t>
<form t-name="FormView.set_default" class="oe_forms oe_frame">
<t t-set="args" t-value="widget.dialog_options.args"/>
<table style="width: 100%">
</table>
</form>
+<t t-name="FormRenderingForm.manual">
+ <div class="oe_form_manual_layout"/>
+</t>
<t t-name="FormRenderingForm">
<div class="oe_form_sheetbg">
- <div class="oe_form_sheet oe_form_sheet_width">
- <group t-if="legacy_mode" col="4"/>
+ <div t-attf-class="oe_form_sheet oe_form_sheet_width #{classnames}">
+ <group col="4"/>
</div>
</div>
</t>
<t t-name="FormRenderingGroup">
<t t-set="table">
- <table border="0" cellpadding="0" cellspacing="0" width="100%"/>
+ <table border="0" cellpadding="0" cellspacing="0" width="100%" t-att-class="classnames"/>
</t>
<t t-if="string">
<fieldset class="oe_group_box">
</t>
<t t-name="FormRenderingNotebook">
<div>
- <ul class="oe_form_notebook">
+ <ul t-attf-class="oe_form_notebook #{classnames}">
<li t-foreach="pages" t-as="page">
<a t-attf-href="##{page.id}">
<t t-esc="page.string"/>
</div>
</t>
<t t-name="FormRenderingNotebookPage">
- <div class="oe_form_notebook_page" t-att-id="id">
- <group t-if="legacy_mode" col="4"/>
+ <div t-attf-class="oe_form_notebook_page #{classnames}" t-att-id="id">
+ <group t-if="layout === 'auto'" col="4"/>
</div>
</t>
<t t-name="FormRenderingSeparator">
- <div class="oe_horizontal_separator">
+ <div t-attf-class="oe_horizontal_separator #{classnames}">
<t t-esc="string"/>
</div>
</t>
<t t-name="FormRenderingLabel">
<label t-att-for="_for"
t-att-title="help"
- t-attf-class="oe_form_label#{help ? '_help' : ''} oe_align_#{align}">
+ t-attf-class="#{classnames} oe_form_label#{help ? '_help' : ''} oe_align_#{align}">
<t t-esc="string"/>
<span t-if="help">?</span>
: