Ticket #629: fix_patch.txt

File fix_patch.txt, 702 bytes (added by wgunadi@…, 19 years ago)

Suggested fix

Line 
1Index: django/core/formfields.py
2===================================================================
3--- django/core/formfields.py (revision 880)
4+++ django/core/formfields.py (working copy)
5@@ -120,7 +120,10 @@
6 else:
7 data = self.data.get(field.field_name, None)
8 if data is None:
9- data = ''
10+ "See if the data is an id of another object"
11+ data = self.data.get(field.field_name + "_id", None)
12+ if data is None:
13+ data = ''
14 return FormFieldWrapper(field, data, self.error_dict.get(field.field_name, []))
15 raise KeyError
16
Back to Top