HiPhone_BE/user/urls.py

16 lines
270 B
Python

from django.conf import settings
from rest_framework import routers
from .viewsets import UserViewset
if settings.DEBUG:
router = routers.DefaultRouter()
else:
router = routers.SimpleRouter()
router.register("users", UserViewset)
urlpatterns = router.urls