Ticket #8101: bool.diff
File bool.diff, 865 bytes (added by , 16 years ago) |
---|
-
django/db/models/fields/__init__.py
505 505 def get_db_prep_value(self, value): 506 506 if value is None: 507 507 return None 508 return bool(value)508 return to_python(value) 509 509 510 510 def get_manipulator_field_objs(self): 511 511 return [oldforms.CheckboxField] … … 1013 1013 raise validators.ValidationError, _("This value must be either None, True or False.") 1014 1014 1015 1015 def get_db_prep_value(self, value): 1016 if value is None: 1017 return None 1018 return bool(value) 1016 return to_python(value) 1019 1017 1020 1018 def get_manipulator_field_objs(self): 1021 1019 return [oldforms.NullBooleanField]