Ticket #10918: to_field-10918.git.diff

File to_field-10918.git.diff, 1023 bytes (added by Collin Anderson, 15 years ago)

Git formated patch that fixes the problem.

  • django/contrib/admin/views/main.py

    diff --git a/django/contrib/admin/views/main.py b/django/contrib/admin/views/main.py
    index df0fd9f..6c2c3b7 100644
    a b class ChangeList(object):  
    5858        self.params = dict(request.GET.items())
    5959        if PAGE_VAR in self.params:
    6060            del self.params[PAGE_VAR]
    61         if TO_FIELD_VAR in self.params:
    62             del self.params[TO_FIELD_VAR]
    6361        if ERROR_FLAG in self.params:
    6462            del self.params[ERROR_FLAG]
    6563
    class ChangeList(object):  
    171169    def get_query_set(self):
    172170        qs = self.root_query_set
    173171        lookup_params = self.params.copy() # a dictionary of the query string
    174         for i in (ALL_VAR, ORDER_VAR, ORDER_TYPE_VAR, SEARCH_VAR, IS_POPUP_VAR):
     172        for i in (ALL_VAR, ORDER_VAR, ORDER_TYPE_VAR, SEARCH_VAR, IS_POPUP_VAR, TO_FIELD_VAR):
    175173            if i in lookup_params:
    176174                del lookup_params[i]
    177175        for key, value in lookup_params.items():
Back to Top