web_m2x_options: s/ev.handleObj.selector/currentTarget * many2many with `options={'open': True}` it always open the first element with this fix it will open the right one

pull/1718/head
Zakaria Makrelouf 2017-02-02 13:30:29 +01:00 committed by dsolanki
parent 1f9d797746
commit 818ce37523
1 changed files with 1 additions and 1 deletions

View File

@ -412,7 +412,7 @@ odoo.define('web_m2x_options.web_m2x_options', function (require) {
var open = (self.options && self.is_option_set(self.options.open)); var open = (self.options && self.is_option_set(self.options.open));
if(open){ if(open){
self.mutex.exec(function(){ self.mutex.exec(function(){
var id = parseInt($(ev.handleObj.selector).attr('data-id')); var id = parseInt($(ev.currentTarget).data('id'));
self.do_action({ self.do_action({
type: 'ir.actions.act_window', type: 'ir.actions.act_window',
res_model: self.field.relation, res_model: self.field.relation,