django-oidc-provider/openid_provider/views/clients.py
2015-01-12 19:13:48 -03:00

14 lines
No EOL
459 B
Python

from django.utils.decorators import method_decorator
from django.views.generic.list import ListView
from openid_provider.lib.utils.decorators import staff_required
from openid_provider.models import Client
class ClientListView(ListView):
model = Client
template_name = "openid_provider/clients.html"
@method_decorator(staff_required)
def dispatch(self, *args, **kwargs):
return super(ClientListView, self).dispatch(*args, **kwargs)