Skip to content

Commit

Permalink
调整路由跳转
Browse files Browse the repository at this point in the history
  • Loading branch information
wuyue92tree committed Jul 1, 2018
1 parent 624e7bc commit fbe413d
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,8 @@ python manage.py runserver

## 启动

浏览器访问: http://127.0.0.1:8000/api-docs/
浏览器访问: http://127.0.0.1:8000/api/docs/

## FAQ

[说明文档](http://wuyue92tree.antio.top/opensource/rest-backend.html#FAQ)
4 changes: 3 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@ django-debug-toolbar==1.9.1
django-rest-swagger==2.1.2
djangorestframework==3.8.2
djangorestframework-jwt==1.11.0
Pillow==5.1.0
django-filter==1.1.0
Pillow==5.1.0
git+https://github.com/darklow/django-suit/tarball/v2.git
7 changes: 5 additions & 2 deletions rest_backend/libs/backend/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,12 @@

router = routers.DefaultRouter()

app_name = 'backend'

urlpatterns = [
path('api-auth/', include('rest_framework.urls', namespace='rest_framework')),
path('auth/login/', obtain_jwt_token, name='token-login'),
path('api-docs/', schema_view),
path('docs/', schema_view),

# add api here

]

0 comments on commit fbe413d

Please sign in to comment.