[IMP] Kanan quick create action should also repect the create tag on view
bzr revid: jam@tinyerp.com-20120816102758-2swimfa9dxu3uotv
This commit is contained in:
parent
cf464eb273
commit
4c9205ff4a
|
@ -514,7 +514,12 @@ instance.web_kanban.KanbanGroup = instance.web.Widget.extend({
|
|||
self.view.dataset.ids.push(id);
|
||||
self.do_add_records(records, true);
|
||||
});
|
||||
}
|
||||
},
|
||||
_is_action_enabled: function(action) {
|
||||
if (_.has(this.fields_view.arch.attrs, action))
|
||||
return JSON.parse(this.fields_view.arch.attrs[action]);
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
||||
instance.web_kanban.KanbanRecord = instance.web.Widget.extend({
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
<td class="oe_kanban_group_header">
|
||||
<t t-if="widget.view.group_by">
|
||||
<div class="oe_kanban_header">
|
||||
<t t-if="widget.view._is_quick_create_enabled()">
|
||||
<t t-if="widget.view._is_quick_create_enabled() and widget.view._is_action_enabled('create')">
|
||||
<div class="oe_kanban_add oe_e">]</div>
|
||||
</t>
|
||||
<div class="oe_fold_column">
|
||||
|
|
Loading…
Reference in New Issue