Fix bug css
[ifgu.git] / project / urls.py
1 # -*- encoding: utf-8 -*
2 from django.conf.urls.defaults import *
3 from django.conf import settings
4 from django.contrib import admin
5 from django.contrib.staticfiles.urls import staticfiles_urlpatterns
6 from django.contrib.syndication.views import Feed
7 from feeds import *
8 from cms.sitemaps import CMSSitemap
9
10 admin.autodiscover()
11
12 handler404
13 handler500 # Pyflakes
14
15 urlpatterns = patterns(
16 '',
17 # admin
18 url(r'^admin_tools/', include('admin_tools.urls')),
19 (r'^admin/', include(admin.site.urls)),
20 )
21
22 #rss Marc
23
24 flux = {
25 'actualite': DerniereActualites,
26 }
27
28 urlpatterns += patterns('',
29 (r'^flux/(?P<url>.*)/$', 'django.contrib.syndication.views.feed',
30 {'feed_dict': flux}),)
31
32 #article
33 urlpatterns += patterns('article.views',
34 (r'^actualites/$', 'actualite'),
35 (r'^actualites/(?P<slug>[-\w]+)/$', 'actualite_detail'),
36 (r'^plan-du-site/$', 'plan_du_site'),
37 )
38
39 if settings.DEBUG:
40 urlpatterns += staticfiles_urlpatterns()
41 urlpatterns += patterns('',
42 url(r'^media/(?P<path>.*)$',
43 'django.views.static.serve', {
44 'document_root': settings.MEDIA_ROOT, }),
45 )
46
47 # django-cms
48 urlpatterns += patterns('',
49 url(r'^', include('cms.urls')),
50 url(r'^sitemap.xml$', 'django.contrib.sitemaps.views.sitemap', {'sitemaps': {'cmspages': CMSSitemap}}),
51 )