Ejemplo n.º 1
0
    hogehoge - the explanation of the data.


Copyright:
    Copyright 2011 Alisue allright reserved.

License:
    Licensed under the Apache License, Version 2.0 (the "License"); 
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

        http://www.apache.org/licenses/LICENSE-2.0

    Unliss required by applicable law or agreed to in writing, software
    distributed under the License is distrubuted on an "AS IS" BASICS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
"""
__author__  = 'Alisue <*****@*****.**>'
__version__ = '1.0.0'
__date__    = '2011/06/09'
from django.conf.urls.defaults import patterns, url

from views import EntryDetailView
from views import EntryListView

urlpatterns = patterns('',
    url('^(?P<pk>\d+)/$',           EntryDetailView.as_view(),  name="blogs-entry-detail"),  
    url('^$',                       EntryListView.as_view(),    name="blogs-entry-list"),  
)
Ejemplo n.º 2
0
    # Changelog entry management
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/'
              'pending-entry/list/$',
        view=PendingEntryListView.as_view(),
        name='pending-entry-list'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/entry/'
              '(?P<slug>[\w-]+)/approve/$',
        view=ApproveEntryView.as_view(),
        name='entry-approve'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w'
              '.-]+)/entry/list/$',
        view=EntryListView.as_view(),
        name='entry-list'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/entry'
              '/(?P<slug>[\w-]+)/$',
        view=EntryDetailView.as_view(),
        name='entry-detail'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/entry/'
              '(?P<slug>[\w-]+)/delete/$',
        view=EntryDeleteView.as_view(),
        name='entry-delete'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/'
              'create-entry/$',
        view=EntryCreateView.as_view(),
        name='entry-create'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/entry/'
              '(?P<slug>[\w-]+)/update/$',
        view=EntryUpdateView.as_view(),
        name='entry-update'),

    # Feeds
Ejemplo n.º 3
0
from django.conf.urls import patterns, include, url
from views import EntryListView, EntryDetailView, register, user_login, user_logout, add_comment


urlpatterns = patterns('',
    url(r'^register$', register, name='register'),
    url(r'^login$', user_login, name='login'),
    url(r'^logout$', user_logout, name='logout'),
    url(r'^add-comment$', add_comment, name='add-comment'),
    url(r'^(?P<slug>[-_\w]+)$', EntryDetailView.as_view(), name='entry-detail'),
    url(r'^$', EntryListView.as_view(), name='entry-list'),    
)
Ejemplo n.º 4
0
        name='version-download-gnu'),

    # Changelog entry management
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/'
              'pending-entry/list/$',
        view=PendingEntryListView.as_view(),
        name='pending-entry-list'),
    url(regex='^entry/approve/(?P<pk>\d+)$',
        view=ApproveEntryView.as_view(),
        name='entry-approve'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w'
              '.-]+)/entry/list/$',
        view=EntryListView.as_view(),
        name='entry-list'),
    url(regex='^entry/(?P<pk>\d+)$',
        view=EntryDetailView.as_view(),
        name='entry-detail'),
    url(regex='^entry/delete/(?P<pk>\d+)$',
        view=EntryDeleteView.as_view(),
        name='entry-delete'),
    url(regex='^(?P<project_slug>[\w-]+)/(?P<version_slug>[\w.-]+)/'
              'create-entry/$',
        view=EntryCreateView.as_view(),
        name='entry-create'),
    url(regex='^entry/update/(?P<pk>\d+)$',
        view=EntryUpdateView.as_view(),
        name='entry-update'),

    # Feeds
    url(regex='^(?P<project_slug>[\w-]+)/rss/latest-version/$',
        view=RssVersionFeed(),
Ejemplo n.º 5
0
from django.conf.urls import url
from django.contrib.auth.decorators import login_required

from views import (EntryCreate, EntryDetailView, FeedListView,
                   EntryListView, add_feed, delete_feed, add_to_read)


urlpatterns = [
    url(r'^add/$', login_required(EntryCreate.as_view()), name='entry_add'),
    url(r'entry/(?P<pk>[0-9]+)/$', EntryDetailView.as_view(), name='entry'),
    url(r'user/(?P<pk>[0-9]+)/$', EntryListView.as_view(), name='user'),
    url(r'add_feed/(?P<user_id>[0-9]+)/$', add_feed, name='add_feed'),
    url(r'delete_feed/(?P<user_id>[0-9]+)/$', delete_feed, name='delete_feed'),
    url(r'^feed/$', login_required(FeedListView.as_view()), name='user_feed'),
    url(r'^add_to_read/(?P<entry_id>[0-9]+)/$', add_to_read, name='add_to_read'),
]
Ejemplo n.º 6
0
from django.conf.urls import patterns, url

from views import EntryListView, EntryDetailView, TagView

urlpatterns = patterns(
    '',
    url(r'^$', EntryListView.as_view(), name='blog.entries'),
    url(r'^tags/(?P<tag>.+)/$', TagView.as_view(), name='blog.tags'),
    url(r'^(?P<pk>\d+)/$', EntryDetailView.as_view(), name='blog.detail')
)
Ejemplo n.º 7
0
from django.conf.urls import patterns, include, url
from django.contrib.auth.decorators import permission_required
from views import EntryVisibleListView, EntryDetailView, LatestEntriesFeed, EntryCreate, EntryUpdate

urlpatterns = patterns('blogalog.views', 
    url(r'^$', EntryVisibleListView.as_view(
            context_object_name='latest_blog_entries',
        ), 
        name='entry-list'
    ),
    url(r'^feed/?$', LatestEntriesFeed()),
    url(r'^entry/(?P<pk>\d+)/?$', EntryDetailView.as_view(
            context_object_name='entry',
        ), 
        name='entry-detail',
    ),
    url(r'^entry/add/?$', permission_required('blogalog.add_entry')(EntryCreate.as_view()), name='entry-add'),
    url(r'^entry/update/(?P<pk>\d+)/?$', permission_required('blogalog.change_entry')(EntryUpdate.as_view()), name='entry-update'),
)