2013-09-25 10:01:01 +02:00
|
|
|
from django.conf.urls import include, patterns, url
|
2013-11-29 16:47:31 +01:00
|
|
|
|
2015-01-30 11:58:36 +01:00
|
|
|
from openslides.core.views import IndexView, ErrorView
|
2014-10-11 14:15:42 +02:00
|
|
|
from openslides.utils.rest_api import router
|
2015-02-06 23:57:52 +01:00
|
|
|
from openslides.users.views import UserSettingsView, UserPasswordSettingsView
|
2012-04-15 11:24:40 +02:00
|
|
|
|
2013-12-09 23:56:01 +01:00
|
|
|
handler403 = ErrorView.as_view(status_code=403)
|
|
|
|
handler404 = ErrorView.as_view(status_code=404)
|
|
|
|
handler500 = ErrorView.as_view(status_code=500)
|
2011-07-31 10:46:29 +02:00
|
|
|
|
2015-01-30 11:58:36 +01:00
|
|
|
urlpatterns = patterns(
|
|
|
|
'',
|
|
|
|
url(r'^rest/', include(router.urls)),
|
|
|
|
# TODO: add "special" urls, for example pdf views etc.
|
|
|
|
|
|
|
|
url(r'^user.*', IndexView.as_view()),
|
|
|
|
)
|
|
|
|
|
2013-11-29 16:47:31 +01:00
|
|
|
|
2015-01-30 11:58:36 +01:00
|
|
|
# Deprecated.
|
2013-11-29 16:47:31 +01:00
|
|
|
js_info_dict = {'packages': []}
|
|
|
|
|
|
|
|
|
|
|
|
urlpatterns += patterns(
|
2013-09-25 10:01:01 +02:00
|
|
|
'',
|
2012-07-10 14:00:51 +02:00
|
|
|
(r'^agenda/', include('openslides.agenda.urls')),
|
2012-10-24 11:04:23 +02:00
|
|
|
(r'^motion/', include('openslides.motion.urls')),
|
2012-07-10 14:00:51 +02:00
|
|
|
(r'^assignment/', include('openslides.assignment.urls')),
|
2014-10-11 14:34:49 +02:00
|
|
|
(r'^user/', include('openslides.users.urls')),
|
2013-02-16 16:19:20 +01:00
|
|
|
(r'^mediafile/', include('openslides.mediafile.urls')),
|
2012-07-10 14:00:51 +02:00
|
|
|
(r'^config/', include('openslides.config.urls')),
|
|
|
|
(r'^projector/', include('openslides.projector.urls')),
|
2011-07-31 10:46:29 +02:00
|
|
|
(r'^i18n/', include('django.conf.urls.i18n')),
|
2014-05-11 19:10:08 +02:00
|
|
|
(r'^ckeditor/', include('ckeditor.urls')),
|
2011-07-31 10:46:29 +02:00
|
|
|
)
|
2011-09-03 19:16:43 +02:00
|
|
|
|
2013-09-25 10:01:01 +02:00
|
|
|
# TODO: move this patterns into core or the participant app
|
|
|
|
urlpatterns += patterns(
|
|
|
|
'',
|
2012-04-16 11:12:21 +02:00
|
|
|
(r'^jsi18n/$', 'django.views.i18n.javascript_catalog', js_info_dict),
|
2012-04-14 09:42:30 +02:00
|
|
|
|
|
|
|
url(r'^login/$',
|
2014-10-11 14:34:49 +02:00
|
|
|
'openslides.users.views.login',
|
2013-09-25 10:01:01 +02:00
|
|
|
name='user_login'),
|
2012-04-14 09:42:30 +02:00
|
|
|
|
|
|
|
url(r'^logout/$',
|
|
|
|
'django.contrib.auth.views.logout_then_login',
|
2013-09-25 10:01:01 +02:00
|
|
|
name='user_logout'),
|
2012-05-20 22:34:41 +02:00
|
|
|
|
2015-01-30 11:58:36 +01:00
|
|
|
url(r'^myusersettings/$',
|
2014-10-11 14:34:49 +02:00
|
|
|
UserSettingsView.as_view(),
|
2013-09-25 10:01:01 +02:00
|
|
|
name='user_settings'),
|
2012-05-20 22:34:41 +02:00
|
|
|
|
2015-01-30 11:58:36 +01:00
|
|
|
url(r'^myusersettings/changepassword/$',
|
2014-10-11 14:34:49 +02:00
|
|
|
UserPasswordSettingsView.as_view(),
|
2013-09-25 10:01:01 +02:00
|
|
|
name='password_change'),
|
2011-09-03 19:16:43 +02:00
|
|
|
)
|
2013-03-01 17:13:12 +01:00
|
|
|
|
2013-09-25 10:01:01 +02:00
|
|
|
urlpatterns += patterns(
|
|
|
|
'',
|
2013-03-01 17:13:12 +01:00
|
|
|
(r'^', include('openslides.core.urls')),
|
|
|
|
)
|