From 0f7d0e349c2c3dd707102e24a8fb64992d0d3e0b Mon Sep 17 00:00:00 2001 From: Oskar Hahn Date: Sat, 2 Feb 2013 00:26:08 +0100 Subject: [PATCH] Fixed URLs in projector views --- openslides/projector/views.py | 16 ++++++---------- openslides/urls.py | 2 +- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/openslides/projector/views.py b/openslides/projector/views.py index 997e89cf2..2ebb67569 100644 --- a/openslides/projector/views.py +++ b/openslides/projector/views.py @@ -151,7 +151,7 @@ class ActivateView(RedirectView): Activate a Slide. """ permission_required = 'projector.can_manage_projector' - url = 'dashboard' + url_name = 'dashboard' allow_ajax = True def pre_redirect(self, request, *args, **kwargs): @@ -209,7 +209,7 @@ class ProjectorEdit(RedirectView): Scale or scroll the projector. """ permission_required = 'projector.can_manage_projector' - url = 'dashboard' + url_name = 'dashboard' allow_ajax = True def pre_redirect(self, request, *args, **kwargs): @@ -233,7 +233,7 @@ class CountdownEdit(RedirectView): Start, stop or reset the countdown. """ permission_required = 'projector.can_manage_projector' - url = 'dashboard' + url_name = 'dashboard' allow_ajax = True def pre_redirect(self, request, *args, **kwargs): @@ -284,7 +284,7 @@ class OverlayMessageView(RedirectView): """ Sets or clears the overlay message """ - url = 'dashboard' + url_name = 'dashboard' allow_ajax = True permission_required = 'projector.can_manage_projector' @@ -305,7 +305,7 @@ class ActivateOverlay(RedirectView): """ Activate or deactivate an overlay. """ - url = 'dashboard' + url_name = 'dashboard' allow_ajax = True permission_required = 'projector.can_manage_projector' @@ -341,8 +341,6 @@ class CustomSlideCreateView(CreateView): template_name = 'projector/new.html' model = ProjectorSlide context_object_name = 'customslide' - success_url = 'dashboard' - apply_url = 'customslide_edit' class CustomSlideUpdateView(UpdateView): @@ -353,8 +351,6 @@ class CustomSlideUpdateView(UpdateView): template_name = 'projector/new.html' model = ProjectorSlide context_object_name = 'customslide' - success_url = 'dashboard' - apply_url = 'customslide_edit' class CustomSlideDeleteView(DeleteView): @@ -363,7 +359,7 @@ class CustomSlideDeleteView(DeleteView): """ permission_required = 'projector.can_manage_projector' model = ProjectorSlide - url = 'dashboard' + url_name = 'dashboard' def register_tab(request): diff --git a/openslides/urls.py b/openslides/urls.py index 800ef85e6..5689e475a 100644 --- a/openslides/urls.py +++ b/openslides/urls.py @@ -20,7 +20,7 @@ handler500 = 'openslides.utils.views.server_error' urlpatterns = patterns('', # Redirect to dashboard URL - url(r'^$', RedirectView.as_view(url='dashboard'), name='home',), + url(r'^$', RedirectView.as_view(url='projector/dashboard'), name='home',), (r'^agenda/', include('openslides.agenda.urls')), (r'^motion/', include('openslides.motion.urls')),