您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

123456789101112131415
  1. import rest_framework_jwt.views
  2. from django.conf.urls import url, include
  3. from rest_framework.routers import DefaultRouter
  4. from api import views
  5. router = DefaultRouter()
  6. router.register(r'passwords', views.PasswordViewSet, base_name='passwords')
  7. urlpatterns = [
  8. url(r'^', include(router.urls)),
  9. url(r'^tokens/auth/', rest_framework_jwt.views.obtain_jwt_token),
  10. url(r'^tokens/refresh/', rest_framework_jwt.views.refresh_jwt_token),
  11. url(r'^auth/', include('djoser.urls')),
  12. ]