Cleaning de code inutile
[auf_rh_dae.git] / project / urls.py
CommitLineData
5e23d90d
OL
1# -*- encoding: utf-8 -*
2from django.conf.urls.defaults import patterns, include, handler500, url
3from django.conf import settings
4from django.contrib import admin
8e0d552d 5from auf.django.emploi import settings as sett
5e23d90d
OL
6
7admin.autodiscover()
8
9handler500 # Pyflakes
10
11urlpatterns = patterns(
12 '',
fd5f1d55 13 (r'^$', 'project.views.index'),
86caaf03 14 url(r'^captcha/', include('captcha.urls')),
5e23d90d
OL
15 url(r'^admin_tools/', include('admin_tools.urls')),
16 (r'^admin/', include(admin.site.urls)),
43198a9f
NBV
17 url(r'^api/(?P<method>[a-z_-]+)/(?P<offre_id>\d+)$', 'recrutement.api.api',
18 name='recrutement_api'),
8e0f904f
NBV
19 url(r'^api/(?P<method>[a-z_-]+)/$', 'recrutement.api.api',
20 name='recrutement_api'),
5e23d90d
OL
21 (r'^connexion/$', 'django.contrib.auth.views.login'),
22 (r'^deconnexion/$', 'django.contrib.auth.views.logout'),
498881f4 23 (r'^dae/', include('project.dae.urls')),
b8778e64 24 (r'^recrutement/', include('recrutement.urls')),
ec517164 25 (r'^tinymce/', include('tinymce.urls')),
ae936f8d 26 (r'^', include('project.rh.urls')),
2b3edf33 27 (r'^prive/(?P<path>.*)$', 'django.views.static.serve',
8e0d552d 28 {'document_root': sett.PRIVE_MEDIA_ROOT}),
5e23d90d
OL
29)
30
31if settings.DEBUG:
32 urlpatterns += patterns('',
33 (r'^media/(?P<path>.*)$', 'django.views.static.serve',
34 {'document_root': settings.MEDIA_ROOT}),
35 )