Fix value of Reference fields when id is -1
issue3375 review1089002 (transplanted from d24d3b856c487b9904fa60923708faa751a0d6ed)
This commit is contained in:
1 parent
f62ace468a
commit
2a4cdfe43b
1 file changed
+1
-1
@@ -818,7 +818,7 @@ class ReferenceField(CharField):
|
||||
def get(self, record, check_load=True, readonly=True, modified=False):
|
||||
if (record.value.get(self.name)
|
||||
and record.value[self.name][0]
|
||||
and record.value[self.name][1] >= 0):
|
||||
and record.value[self.name][1] >= -1):
|
||||
return ','.join(map(str, record.value[self.name]))
|
||||
return None
|
||||
|
||||
|
||||
Reference in new issue
Block a user