From 49cad65ccdc15d6653c4dfb2f3ee548dc50326e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 26 Apr 2017 19:36:21 +0200 Subject: [PATCH] Skip validate only on constant readonly fields A field can be readonly by the domain inversion in the validate method. So it should be validated again in case its domain inversion change and reset it a non-readonly. So only field that are always readonly can be skipped for the validation. issue6448 review37351002 --- tryton/gui/window/view_form/model/record.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tryton/gui/window/view_form/model/record.py b/tryton/gui/window/view_form/model/record.py index 0f65f66166..9d3a0310ef 100644 --- a/tryton/gui/window/view_form/model/record.py +++ b/tryton/gui/window/view_form/model/record.py @@ -401,7 +401,7 @@ class Record(SignalEvent): for field_name, field in self.group.fields.iteritems(): if fields is not None and field_name not in fields: continue - if field.get_state_attrs(self).get('readonly', False): + if field.attrs.get('readonly'): continue if field_name == self.group.exclude_field: continue