[FIX] handle common case where action_data has no context, and should not be added to the compoundcontext

issue introduced in revision xmo@openerp.com-20111014122020-n3uz31ilemt1lvro

bzr revid: xmo@openerp.com-20111017072401-qfreccymm5bn0g4s
This commit is contained in:
Xavier Morel
2011-10-17 09:24:01 +02:00
parent 2915308f6c
commit 414126e724
+7 -3
View File
@@ -859,10 +859,14 @@ db.web.View = db.web.Widget.extend(/** @lends db.web.View# */{
}],
domains: []
}).pipe(function (results) {
action.context = new db.web.CompoundContext(
results.context, action_data.context);
if (!action_data.context) {
action.context = results.context
} else {
action.context = new db.web.CompoundContext(
results.context, action_data.context);
}
return self.do_action(action, result_handler);
});
}, null);
} else {
return result_handler();
}