1 # -*- coding: utf-8 -*-
2 from django.conf.urls import patterns, include, url
3 from django.conf import settings
4 from .views import HomeView, AvatarlessProfileEditView
7 urlpatterns = patterns(
9 url(r'^$', HomeView.as_view(), name="home"),
10 url(r'^lekcje/', include('catalogue.urls')),
11 url(r'^info/(?P<url>.*)$', 'django.contrib.flatpages.views.flatpage',
13 url(r'^szukaj/', include('haystack.urls')),
14 url(r'^zglos/', include('contact.urls')),
15 url(r'^forum/profile/edit/$', AvatarlessProfileEditView.as_view(), name='edit_profile'),
16 url(r'^forum/', include('forum.urls')),
17 url(r'^forum/', include('pybb.urls', namespace='pybb')),
18 url(r'^kompetencje/', include('curriculum.urls')),
19 url(r'^wtem/', include('wtem.urls')),
23 # Admin stuff, if necessary.
24 if 'django.contrib.admin' in settings.INSTALLED_APPS:
25 from django.contrib import admin
28 if 'django_cas' in settings.INSTALLED_APPS:
29 urlpatterns += patterns(
31 (r'^admin/logout/$', 'django_cas.views.logout'),
33 urlpatterns += patterns(
35 url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
36 url(r'^admin/', include(admin.site.urls)),
39 # Auth stuff, if necessary
40 if 'django_cas' in settings.INSTALLED_APPS:
41 urlpatterns += patterns(
43 url(r'^accounts/login/$', 'django_cas.views.login', name='login'),
44 url(r'^accounts/logout/$', 'django_cas.views.logout', name='logout'),
49 from fnpdjango.utils.urls import i18n_patterns
50 from .views import mil_home_view, mil_contact_view, mil_knowledge_base_view
51 urlpatterns += i18n_patterns(
53 url(r'^katalog/$', mil_home_view, name="mil_home"),
54 url(r'^wez-udzial/', include('comment.urls')),
55 url(r'^kontakt/$', mil_contact_view, name='mil_contact'),
56 url(r'^bazawiedzy/(?P<url>.*)$', mil_knowledge_base_view, name="knowledge_base"),
61 urlpatterns += patterns(
63 url(r'^media/(?P<path>.*)$', 'django.views.static.serve', {
64 'document_root': settings.MEDIA_ROOT,