Ticket #10150: model_to_sorted_dict.diff
File model_to_sorted_dict.diff, 500 bytes (added by , 16 years ago) |
---|
-
django/forms/models.py
diff --git a/django/forms/models.py b/django/forms/models.py index 01bd912..f187183 100644
a b def model_to_dict(instance, fields=None, exclude=None): 117 117 # avoid a circular import 118 118 from django.db.models.fields.related import ManyToManyField, OneToOneField 119 119 opts = instance._meta 120 data = {}120 data = SortedDict() 121 121 for f in opts.fields + opts.many_to_many: 122 122 if not f.editable: 123 123 continue