Browse Source

postkey/admin.py: fix compatibility with django 1.8

pull/1/head
Hidden Z 9 years ago
parent
commit
e6c89f6c6c
  1. 8
      pyi2phosts/postkey/admin.py

8
pyi2phosts/postkey/admin.py

@ -39,12 +39,12 @@ class i2phostAdmin(admin.ModelAdmin):
class PendingAdmin(i2phostAdmin): class PendingAdmin(i2phostAdmin):
def queryset(self, request): def get_queryset(self, request):
qs = super(PendingAdmin, self).queryset(request) qs = super(PendingAdmin, self).get_queryset(request)
return qs.filter(approved=False) return qs.filter(approved=False)
def approve_selected(modeladmin, request, queryset): def approve_selected(modeladmin, request, get_queryset):
queryset.update(approved=True) get_queryset.update(approved=True)
list_filter = [] list_filter = []
list_display = ('url', 'name', 'description', 'date_added', 'last_seen', 'expires', 'approved') list_display = ('url', 'name', 'description', 'date_added', 'last_seen', 'expires', 'approved')

Loading…
Cancel
Save