add fix for Creating sequence on fiscalyear: ValueError: Double underscores not allowed

This commit is contained in:
?ngel ?lvarez 2014-10-06 14:58:58 +02:00
parent 12fd6fa4c5
commit 91e9d63f6c
2 changed files with 18 additions and 0 deletions

17
issue5681002_1_10001.diff Normal file
View file

@ -0,0 +1,17 @@
Index: trytond/model/modelview.py
===================================================================
--- a/trytond/trytond/model/modelview.py
+++ b/trytond/trytond/model/modelview.py
@@ -426,7 +426,9 @@
# convert attributes into pyson
encoder = PYSONEncoder()
for attr in ('states', 'domain', 'spell', 'colors'):
- if element.get(attr):
+ if (element.get(attr)
+ # Avoid double evaluation from inherit with different model
+ and '__' not in element.get(attr)):
element.set(attr, encoder.encode(safe_eval(element.get(attr),
CONTEXT)))

1
series
View file

@ -34,3 +34,4 @@ issue8381002_20002.diff
issue3991003_40001.diff
issue4011003_200001.diff
nan_tic_sao.diff
issue5681002_1_10001.diff