[ADD] Added 'open' action to kanban card links
bzr revid: fme@openerp.com-20120829114713-kj9c0vsxtn504li3
This commit is contained in:
parent
b745a2038a
commit
848c16e6d0
|
@ -121,7 +121,7 @@ instance.web_kanban.KanbanView = instance.web.View.extend({
|
|||
case 'button':
|
||||
case 'a':
|
||||
var type = node.attrs.type || '';
|
||||
if (_.indexOf('action,object,edit,delete'.split(','), type) !== -1) {
|
||||
if (_.indexOf('action,object,edit,open,delete'.split(','), type) !== -1) {
|
||||
_.each(node.attrs, function(v, k) {
|
||||
if (_.indexOf('icon,type,name,args,string,context,states,kanban_states'.split(','), k) != -1) {
|
||||
node.attrs['data-' + k] = v;
|
||||
|
@ -827,6 +827,9 @@ instance.web_kanban.KanbanRecord = instance.web.Widget.extend({
|
|||
do_action_edit: function($action) {
|
||||
this.view.open_record(this.id, true);
|
||||
},
|
||||
do_action_open: function($action) {
|
||||
this.view.open_record(this.id);
|
||||
},
|
||||
do_action_object: function ($action) {
|
||||
var button_attrs = $action.data();
|
||||
this.view.do_execute_action(button_attrs, this.view.dataset, this.id, this.do_reload);
|
||||
|
|
Loading…
Reference in New Issue