# HG changeset patch # User Brian Neal # Date 1387918775 21600 # Node ID 6c7dd8bda8905c2aa023e5936ca494afec6e9a6c # Parent 1fd79e3b47e2dc580f9f17f8f5e16c01f8397385 For Django 1.6: ModelAdmin.queryset renamed to get_queryset. diff -r 1fd79e3b47e2 -r 6c7dd8bda890 gigs/admin.py --- a/gigs/admin.py Tue Dec 24 14:48:36 2013 -0600 +++ b/gigs/admin.py Tue Dec 24 14:59:35 2013 -0600 @@ -16,8 +16,8 @@ list_filter = ['state'] search_fields = ['name'] - def queryset(self, request): - qs = super(CityAdmin, self).queryset(request) + def get_queryset(self, request): + qs = super(CityAdmin, self).get_queryset(request) return qs.select_related('state', 'country') @@ -30,8 +30,8 @@ list_display = ['name', 'city'] search_fields = ['name'] - def queryset(self, request): - qs = super(VenueAdmin, self).queryset(request) + def get_queryset(self, request): + qs = super(VenueAdmin, self).get_queryset(request) return qs.select_related('city', 'city__state', 'city__country') @@ -44,8 +44,8 @@ save_on_top = True filter_horizontal = ['bands'] - def queryset(self, request): - qs = super(GigAdmin, self).queryset(request) + def get_queryset(self, request): + qs = super(GigAdmin, self).get_queryset(request) return qs.select_related('venue')