summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/view_form.js
diff options
context:
space:
mode:
authorniv-openerp <nicolas.vanhoren@openerp.com>2012-02-14 17:15:58 +0100
committerniv-openerp <nicolas.vanhoren@openerp.com>2012-02-14 17:15:58 +0100
commitcf6b9b6e3e9f0778fe57c8d2fd53f7b9d742290d (patch)
tree541bc163c68ee1e0273ff8ca9a8f9d6319855152 /addons/web/static/src/js/view_form.js
parent471d403d818c44cc08300b9a3fb77f4f71e894ef (diff)
[fix] complex bug in BufferedDataSet
lp bug: https://launchpad.net/bugs/925345 fixed bzr revid: nicolas.vanhoren@openerp.com-20120214161558-k634bkwbwq0vk58p
Diffstat (limited to 'addons/web/static/src/js/view_form.js')
-rw-r--r--addons/web/static/src/js/view_form.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js
index ff0ef5e5fea..8c9b99a02a2 100644
--- a/addons/web/static/src/js/view_form.js
+++ b/addons/web/static/src/js/view_form.js
@@ -2394,13 +2394,13 @@ openerp.web.form.FieldOne2Many = openerp.web.form.Field.extend({
obj['id'] = _.uniqueId(self.dataset.virtual_id_prefix);
obj.defaults = {};
self.dataset.to_create.push(obj);
- self.dataset.cache.push(_.clone(obj));
+ self.dataset.cache.push(_.extend(_.clone(obj), {values: _.clone(command[2])}));
ids.push(obj.id);
return;
case commands.UPDATE:
obj['id'] = command[1];
self.dataset.to_write.push(obj);
- self.dataset.cache.push(_.clone(obj));
+ self.dataset.cache.push(_.extend(_.clone(obj), {values: _.clone(command[2])}));
ids.push(obj.id);
return;
case commands.DELETE: