Do not send value for readonly Many2Many

In contrary to One2Many, Many2Many can not be modified when they are readonly.
But Many2Many inherit from One2Many so we must exclude them explicitly from
the test.

issue8323
review275371002
This commit is contained in:
Cédric Krier
2019-05-06 13:37:21 +02:00
parent e45f3409d4
commit b3e5ee2a9a
+2 -1
View File
@@ -794,7 +794,8 @@
}
var field = this.model.fields[name];
if (field.description.readonly &&
!(field instanceof Sao.field.One2Many)) {
!((field instanceof Sao.field.One2Many) &&
!(field instanceof Sao.field.Many2Many))) {
continue;
}
if ((this._changed[name] === undefined) && this.id >= 0) {