Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

OneToOne filtering should only apply in a popup selection from the re…

…lated model.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@9507 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 3ba235a348dd00f10cdc85652fb841bc15caca35 1 parent e5437af
@ubernostrum ubernostrum authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  django/contrib/admin/views/main.py
View
2  django/contrib/admin/views/main.py
@@ -237,7 +237,7 @@ def construct_search(field_name):
qs = qs.distinct()
break
- if self.opts.one_to_one_field:
+ if self.is_popup and self.opts.one_to_one_field:
qs = qs.complex_filter(self.opts.one_to_one_field.rel.limit_choices_to)
return qs
Please sign in to comment.
Something went wrong with that request. Please try again.