urls.py 657 B

123456789101112131415161718
  1. from django.urls import path
  2. from .views.userexportview import UserExportView
  3. from .views.userjoinview import UserJoinView
  4. from .views.userlistview import UserListView, UserListLogin
  5. from .views.userquitview import UserQuitView
  6. from .views.userview import UserView, UserEdit
  7. urlpatterns = [
  8. # 注册登录代码
  9. path('', UserListView.as_view()),
  10. path('login', UserListLogin.as_view()),
  11. path('export', UserExportView.as_view()),
  12. path('<str:user_id>', UserView.as_view()),
  13. path('<str:user_id>/edit', UserEdit.as_view()),
  14. path('<str:user_id>/join', UserJoinView.as_view()),
  15. path('<str:user_id>/quit', UserQuitView.as_view())
  16. ]