mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
22 lines
389 B
Python
22 lines
389 B
Python
from rest_framework import routers
|
|
|
|
from . import views
|
|
|
|
|
|
class UsersRootView(routers.APIRootView):
|
|
"""
|
|
Users API root view
|
|
"""
|
|
def get_view_name(self):
|
|
return 'Users'
|
|
|
|
|
|
router = routers.DefaultRouter()
|
|
router.APIRootView = UsersRootView
|
|
|
|
# Permissions
|
|
router.register('permissions', views.ObjectPermissionViewSet)
|
|
|
|
app_name = 'users-api'
|
|
urlpatterns = router.urls
|