diff --git a/sao/src/model.js b/sao/src/model.js index 15f3cfe784..6c45308b9b 100644 --- a/sao/src/model.js +++ b/sao/src/model.js @@ -2559,7 +2559,11 @@ } const record2 = group.get(vals.id); if (record2) { - record2.set_on_change(vals); + let to_update = Object.fromEntries( + Object.entries(vals).filter( + ([k, v]) => !Object.prototype.hasOwnProperty.call(vals_to_set, k) + )); + record2.set_on_change(to_update); } } } diff --git a/tryton/tryton/gui/window/view_form/model/field.py b/tryton/tryton/gui/window/view_form/model/field.py index 05ca2d1fe4..51fd9ef330 100644 --- a/tryton/tryton/gui/window/view_form/model/field.py +++ b/tryton/tryton/gui/window/view_form/model/field.py @@ -888,7 +888,10 @@ class O2MField(Field): continue record2 = group.get(vals['id']) if record2 is not None: - record2.set_on_change(vals) + to_set = { + k: v for k, v in vals.items + if k not in vals_to_set} + record2.set_on_change(to_set) def validation_domains(self, record, pre_validate=None): screen_domain, attr_domain = self.domains_get(record, pre_validate)