...
 
Commits (2)
from rest_framework import routers
from .views import ArticleViewSet, ArticleSearch, ArticleTag
router = routers.DefaultRouter()
router.register(r"articles", ArticleViewSet)
router.register(r"articles-by-tag/(?P<filter_tag>.+)", ArticleTag)
router.register(r"articles-search/(?P<search_keywords>.+)", ArticleSearch)
urlpatterns = router.urls
......@@ -11,6 +11,10 @@ from django.contrib import admin
from core.routers import DefaultRouter
from rp.api.urls import router as rp_router
# Django rest framework documentation
from rest_framework.documentation import include_docs_urls
router = DefaultRouter()
router.extend(rp_router)
......@@ -22,7 +26,8 @@ urlpatterns = [
url(r"^feeds/", include("rp.feeds.urls", namespace="feeds")),
url(r"^rp/", include("rp.urls", namespace="rp")),
url(r'^accounts/', include('allauth.urls')),
url(r"^users/", include('userprofile.urls', namespace="users"))
url(r"^users/", include('userprofile.urls', namespace="users")),
url(r"^docs/api/", include_docs_urls(title="API de la revue de presse")),
]
if settings.DEBUG:
......
......@@ -12,4 +12,7 @@ django-allauth
django-fsm
django-markdown2
url
coreapi
pygments
markdown
-e git+https://github.com/mariocesar/sorl-thumbnail.git#egg=sorl-thumbnail