mirror of
https://github.com/django/django.git
synced 2025-10-05 00:00:37 +00:00
Fixed #15103 - SuspiciousOperation with limit_choices_to and raw_id_fields
Thanks to natrius for the report. This patch also fixes some unicode bugs in affected code. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15347 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
22eaf77f9d
commit
c24bdf044b
7 changed files with 77 additions and 21 deletions
|
@ -55,6 +55,10 @@ class Options(object):
|
|||
self.abstract_managers = []
|
||||
self.concrete_managers = []
|
||||
|
||||
# List of all lookups defined in ForeignKey 'limit_choices_to' options
|
||||
# from *other* models. Needed for some admin checks. Internal use only.
|
||||
self.related_fkey_lookups = []
|
||||
|
||||
def contribute_to_class(self, cls, name):
|
||||
from django.db import connection
|
||||
from django.db.backends.util import truncate_name
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue