urls.py 437 Bytes
Newer Older
luxcem's avatar
luxcem committed
1
from rest_framework import routers
2
from .views import ArticleViewSet, ArticleSearch, ArticleTag, ArticleStatus
3 4


luxcem's avatar
luxcem committed
5 6 7
router = routers.DefaultRouter()

router.register(r"articles", ArticleViewSet)
8
router.register(r"articles-by-status/(?P<filter_status>.+)", ArticleStatus)
9
router.register(r"articles-by-tag/(?P<filter_tag>.+)", ArticleTag)
10
router.register(r"articles-search/(?P<search_keywords>.+)", ArticleSearch)
11

cynddl's avatar
cynddl committed
12
urlpatterns = router.urls