Fixed call to queryset object for Django >= 1.7
This commit is contained in:
@@ -44,7 +44,9 @@ class SortableAdminBase(object):
|
|||||||
object_tools block to take people to the view to change the sorting.
|
object_tools block to take people to the view to change the sorting.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
if get_is_sortable(self.queryset(request)):
|
qs_method = getattr(self, 'get_queryset', self.queryset)
|
||||||
|
|
||||||
|
if get_is_sortable(qs_method(request)):
|
||||||
self.change_list_template = \
|
self.change_list_template = \
|
||||||
self.sortable_change_list_with_sort_link_template
|
self.sortable_change_list_with_sort_link_template
|
||||||
self.is_sortable = True
|
self.is_sortable = True
|
||||||
|
|||||||
Reference in New Issue
Block a user