summaryrefslogtreecommitdiff
path: root/addons/web/static/src/xml/base.xml
diff options
context:
space:
mode:
authorJigar Amin - OpenERP <jam@tinyerp.com>2012-08-14 18:38:21 +0530
committerJigar Amin - OpenERP <jam@tinyerp.com>2012-08-14 18:38:21 +0530
commit076fdb09940c57c385c3b3f7639bb893464afb69 (patch)
tree7d980e8f9abac524c54773228b06a8c7e62cebe1 /addons/web/static/src/xml/base.xml
parent3e797902fcfb664dc2695e2b09aae9c81a6930ed (diff)
[IMP] views should show the button create/edit/delete/duplicate on the view tag create/edit/delete attributes
bzr revid: jam@tinyerp.com-20120814130821-ret2z62dsthle39p
Diffstat (limited to 'addons/web/static/src/xml/base.xml')
-rw-r--r--addons/web/static/src/xml/base.xml18
1 files changed, 12 insertions, 6 deletions
diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml
index 0eddd914f01..21d006e23ab 100644
--- a/addons/web/static/src/xml/base.xml
+++ b/addons/web/static/src/xml/base.xml
@@ -672,9 +672,11 @@
</table>
<div t-name="ListView.buttons" class="oe_list_buttons">
<t t-if="!widget.no_leaf and widget.options.action_buttons !== false and widget.options.addable">
- <button type="button" class="oe_button oe_list_add oe_highlight">
- <t t-esc="widget.options.addable"/>
- </button>
+ <t t-if="widget._is_action_enabled('create')">
+ <button type="button" class="oe_button oe_list_add oe_highlight">
+ <t t-esc="widget.options.addable"/>
+ </button>
+ </t>
<span class="oe_alternative" t-if="widget.options.import_enabled">
<span class="oe_fade">or</span> <a href="#" class="oe_bold oe_list_button_import">Import</a>
</span>
@@ -747,10 +749,14 @@
<div t-name="FormView.buttons" class="oe_form_buttons">
<t t-if="widget.options.action_buttons !== false">
<span class="oe_form_buttons_view">
- <div style="display: inline-block;"> <!-- required for the bounce effect on button -->
- <button type="button" class="oe_button oe_form_button_edit">Edit</button>
- </div>
+ <t t-if="widget._is_action_enabled('edit')">
+ <div style="display: inline-block;"> <!-- required for the bounce effect on button -->
+ <button type="button" class="oe_button oe_form_button_edit">Edit</button>
+ </div>
+ </t>
+ <t t-if="widget._is_action_enabled('create')">
<button type="button" class="oe_button oe_form_button_create">Create</button>
+ </t>
</span>
<span class="oe_form_buttons_edit">
<button type="button" class="oe_button oe_form_button_save oe_highlight">Save</button> <span class="oe_fade">or</span> <a href="#" class="oe_bold oe_form_button_cancel">Discard</a>