[FIX] Avoid rpc errors on actions.act.url@target='self'

bzr revid: fme@openerp.com-20131118102112-znm2mza36md6896n
This commit is contained in:
Fabien Meghazi 2013-11-18 11:21:12 +01:00
parent 6f10f3ae24
commit bb9c83714a
1 changed files with 5 additions and 1 deletions

View File

@ -510,7 +510,11 @@ instance.web.ActionManager = instance.web.Widget.extend({
});
},
ir_actions_act_url: function (action) {
window.open(action.url, action.target === 'self' ? '_self' : '_blank');
if (action.target === 'self') {
instance.web.redirect(action.url);
} else {
window.open(action.url, '_blank');
}
return $.when();
},
});