Commit 33ef00890d86875fbf833a36a2003963d195ff40
1 parent
65e23e6b
Exists in
master
and in
2 other branches
Removed contrast view, now works with JavaScript
Showing
1 changed file
with
1 additions
and
14 deletions
Show diff stats
themes/views.py
... | ... | @@ -3,7 +3,7 @@ from django.shortcuts import render |
3 | 3 | from django.contrib import messages |
4 | 4 | from django.core.urlresolvers import reverse, reverse_lazy |
5 | 5 | from django.utils.translation import ugettext_lazy as _ |
6 | -from django.http import HttpResponse, JsonResponse, HttpResponseRedirect | |
6 | +from django.http import HttpResponse, JsonResponse, HttpResponseRedirect,HttpRequest | |
7 | 7 | from django.shortcuts import redirect |
8 | 8 | |
9 | 9 | from braces import views as braces_mixins |
... | ... | @@ -79,16 +79,3 @@ class CSSStyleSettings(braces_mixins.LoginRequiredMixin, braces_mixins.Staffuser |
79 | 79 | context['settings_menu_active'] = "settings_menu_active" |
80 | 80 | |
81 | 81 | return context |
82 | - | |
83 | -def Contrast(request): | |
84 | - theme = Themes.objects.get(id = 1) | |
85 | - | |
86 | - if theme.css_style == 'contrast': | |
87 | - theme.css_style = 'green' | |
88 | - else: | |
89 | - theme.css_style = 'contrast' | |
90 | - theme.save() | |
91 | - | |
92 | - caminho = request.META.get('HTTP_REFERER') | |
93 | - | |
94 | - return HttpResponseRedirect(caminho) | ... | ... |