urls.py 868 Bytes
Newer Older
1
from django.contrib.auth.decorators import login_required
luxcem's avatar
luxcem committed
2
from django.conf.urls import url
3

4
from rp.views.articles import ArticleListFlux, ArticleEdit, ArticleDetailView
luxcem's avatar
luxcem committed
5 6

urlpatterns = [
luxcem's avatar
luxcem committed
7
    url(
cynddl's avatar
cynddl committed
8
        r"^article/list/(?P<filter_view>\w+)",
9
        login_required(ArticleListFlux.as_view()),
luxcem's avatar
luxcem committed
10 11
        name="article-list"
    ),
12 13
    url(
        r"^article/list",
14
        login_required(ArticleListFlux.as_view()),
15 16
        name="article-list"
    ),
17 18
    url(
        r"^article/edit/(?P<pk>\d+)",
19
        login_required(ArticleEdit.as_view()),
20 21 22 23
        name="article-edit"
    ),
    url(
        r"^article/view/(?P<pk>\d+)",
24
        login_required(ArticleDetailView.as_view()),
25 26 27 28
        name="article-view"
    ),
    url(
        r"^article/preview/(?P<pk>\d+)",
29
        login_required(ArticleDetailView.as_view(preview=True)),
30 31
        name="article-preview"
    )
luxcem's avatar
luxcem committed
32
]