1
0
mirror of https://github.com/django/django.git synced 2025-10-30 17:16:10 +00:00

magic-removal: Implemented hook for custom managers

git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@1647 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty
2005-12-14 18:49:48 +00:00
parent af96c19be2
commit e18d87f84e
3 changed files with 45 additions and 20 deletions

View File

@@ -313,7 +313,7 @@ class Field(object):
return first_choice + list(self.choices)
rel_model = self.rel.to
return first_choice + [(getattr(x, rel_model._meta.pk.attname), str(x))
for x in rel_model.objects.get_list(**self.rel._meta.limit_choices_to)]
for x in rel_model._default_manager.get_list(**self.rel._meta.limit_choices_to)]
def get_choices_default(self):
if(self.radio_admin):