[FIX] when performing name_get on m2o fields being written to BufferedDataSet, ignore m2o fields with 'false' value as well as those not being written at all

bzr revid: xmo@openerp.com-20111013125858-pboz81w3s58lk2rl
This commit is contained in:
Xavier Morel 2011-10-13 14:58:58 +02:00
parent 1635fcc568
commit 322d20d53c
1 changed files with 1 additions and 1 deletions

View File

@ -654,7 +654,7 @@ openerp.web.BufferedDataSet = openerp.web.DataSetStatic.extend({
.filter(function (field) {
// keep m2o fields which are in the data dict
return field.descriptor.type === 'many2one' &&
field.key in data;
data[field.key];
}).pluck('key')
.value();
var name_gets = _(fields_to_fix).map(function (field) {