Example #1
0
from django.conf.urls.defaults import *
from entry.views import EntryListView, EntryDetailView
from entry.views import CategoryListView, CategoryDetailView
from entry.views import EntryTagListView, EntryTagDetailView
from django.views.generic import TemplateView

urlpatterns = patterns('',
	url(r'tags/$', EntryTagListView.as_view(), name='entry_tag_list'),
	url(r'tags/(?P<pk>[-\d]+)/$', EntryTagDetailView.as_view(), name='entry_tag_detail'),
	url(r'category/$', CategoryListView.as_view(), name='entry_category_list'),
	url(r'category/(?P<slug>[-\w]+)/$', CategoryDetailView.as_view(), name='entry_category_detail'),
	url(r'(?P<slug>[-\w]+)/$', EntryDetailView.as_view(), name='entry_detail'),
	url(r'^$', EntryListView.as_view(), name='entry_list'),
)
Example #2
0
from django.urls import path

from entry.views import EntryListView, EntryCreateView, EntryUpdateView, EntryDeleteView


app_name = 'entry'


urlpatterns = [
    path('', EntryListView.as_view(), name='list'),
    path('create/', EntryCreateView.as_view(), name='create'),
    path('<int:id>/delete/', EntryDeleteView.as_view(), name='delete'),
    path('<int:id>/', EntryUpdateView.as_view(), name='update'),
]
Example #3
0
    template_name = "labs_home.html"


class BioView(TemplateView):
    template_name = "bio.html"

    def get_context_data(self, **kwargs):
        context = super(BioView, self).get_context_data(**kwargs)
        context["form"] = ContactForm()
        return context


urlpatterns = patterns(
    "",
    # Examples:
    # url(r'^$', 'rdw.views.home', name='home'),
    # url(r'^rdw/', include('rdw.foo.urls')),
    # Uncomment the admin/doc line below to enable admin documentation:
    # url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
    # from django.contrib.staticfiles.urls import staticfiles_urlpatternsUncomment the next line to enable the admin:
    url(r"^steven-ciraolo/$", BioView.as_view(), name="bio.html"),
    url(r"^comments/", include("django.contrib.comments.urls")),
    url(r"^contact/", include("ez_contact.urls")),
    url(r"^blog/", include("entry.urls")),
    url(r"^admin/", include(admin.site.urls)),
    url(r"^ropeadope/$", HomeView.as_view(), name="home"),
    url(r"^labs/$", LabsView.as_view(), name="labs"),
    url(r"^labs/where/$", WhereView.as_view(), name="where"),
    url(r"^$", EntryListView.as_view()),
)