[REM] Dashboard: Removed creatable option (requested by fp)
bzr revid: fme@openerp.com-20120910093152-r14olqa181obp7f2
This commit is contained in:
parent
dc6a6f793c
commit
585dce207d
|
@ -220,23 +220,6 @@ instance.web.form.DashBoard = instance.web.form.FormWidget.extend({
|
|||
am.do_action = function (action) {
|
||||
self.do_action(action);
|
||||
};
|
||||
if (action_attrs.creatable && action_attrs.creatable !== 'false') {
|
||||
var action_id = parseInt(action_attrs.creatable, 10);
|
||||
$action.parent().find('button.oe_dashboard_button_create').click(function() {
|
||||
if (isNaN(action_id)) {
|
||||
action_orig.flags.default_view = 'form';
|
||||
self.do_action(action_orig);
|
||||
} else {
|
||||
self.rpc('/web/action/load', {
|
||||
action_id: action_id
|
||||
}, function(result) {
|
||||
result.result.flags = result.result.flags || {};
|
||||
result.result.flags.default_view = 'form';
|
||||
self.do_action(result.result);
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
if (am.inner_widget) {
|
||||
var new_form_action = function(id, editable) {
|
||||
var new_views = [];
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
<span class="oe_header_txt"> <t t-esc="action.attrs.string"/> </span>
|
||||
<input class = "oe_header_text" type="text"/>
|
||||
<t t-if="!action.attrs.string">&nbsp;</t>
|
||||
<button t-if="action.attrs.creatable and action.attrs.creatable !== 'false'" class="oe_button oe_button_create">Create</button>
|
||||
<span class='oe_icon oe_close'></span>
|
||||
<span class='oe_icon oe_minimize oe_fold' t-if="!action.attrs.fold"></span>
|
||||
<span class='oe_icon oe_maximize oe_fold' t-if="action.attrs.fold"></span>
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<field name="inherit_id" ref="hr.board_hr_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/board/column[1]" position="inside">
|
||||
<action name="%(action_my_expense)d" string="My Expenses" creatable="true"/>
|
||||
<action name="%(action_my_expense)d" string="My Expenses"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
@ -62,7 +62,7 @@
|
|||
<form string="Purchase Dashboard" version="7.0">
|
||||
<board style="2-1">
|
||||
<column>
|
||||
<action name="%(purchase_draft)d" string="Request for Quotations" creatable="true"/>
|
||||
<action name="%(purchase_draft)d" string="Request for Quotations"/>
|
||||
</column>
|
||||
<column>
|
||||
<action name="%(action_purchase_order_monthly_categ_graph)d" string="Monthly Purchases by Category"/>
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
<form string="Sales Dashboard" version="7.0">
|
||||
<board style="2-1">
|
||||
<column>
|
||||
<action name="%(action_quotation_for_sale)d" string="My Quotations" creatable="true"/>
|
||||
<action name="%(action_quotation_for_sale)d" string="My Quotations"/>
|
||||
</column>
|
||||
<column>
|
||||
<action name="%(action_turnover_by_month)d" string="Monthly Turnover"/>
|
||||
|
|
Loading…
Reference in New Issue