summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/view_form.js
diff options
context:
space:
mode:
authorDenis Ledoux <dle@odoo.com>2014-11-05 13:36:20 +0100
committerDenis Ledoux <dle@odoo.com>2014-11-05 13:38:49 +0100
commitcd69dee3f2c7a69ca2732688e1a0989473479711 (patch)
tree6947ca3c5288e2ee08b0b2e1ce5ef5b79b7a6137 /addons/web/static/src/js/view_form.js
parent61a8971db510dbb0e087bba09858fe8b94c7b16d (diff)
[FIX] web: inhibit on change flag when validating editable list
To valid all editable list line, we iterate on the lines and set the editor form with the line value, using set_value. The _inhibit_on_change_flag should be set to True to avoid triggering on changes events opw-617395
Diffstat (limited to 'addons/web/static/src/js/view_form.js')
-rw-r--r--addons/web/static/src/js/view_form.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js
index f4dd7ec501f..cfada94c4e7 100644
--- a/addons/web/static/src/js/view_form.js
+++ b/addons/web/static/src/js/view_form.js
@@ -3890,7 +3890,9 @@ instance.web.form.One2ManyListView = instance.web.ListView.extend({
return _.every(this.records.records, function(record){
r = record;
_.each(self.editor.form.fields, function(field){
+ field._inhibit_on_change_flag = true;
field.set_value(r.attributes[field.name]);
+ field._inhibit_on_change_flag = false;
});
return _.every(self.editor.form.fields, function(field){
field.process_modifiers();