From 4fca767bf97f86ed58af1f5bb8e42241f2ab3ae9 Mon Sep 17 00:00:00 2001 From: Patrick Mayr Date: Fri, 27 May 2022 14:18:31 +0000 Subject: [PATCH 1/2] display edit button when the text is shown --- fet2020/templates/members/index.html | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/fet2020/templates/members/index.html b/fet2020/templates/members/index.html index 89241023..869a9b6d 100644 --- a/fet2020/templates/members/index.html +++ b/fet2020/templates/members/index.html @@ -72,13 +72,15 @@ {% endif %} - {% get_flatpages '/fachschaft/' as pages %} - {% if pages %} -
  • - - Fachschaft-Text bearbeiten - -
  • + {% if members %} + {% get_flatpages '/fachschaft/' as pages %} + {% if pages %} +
  • + + Fachschaft-Text bearbeiten + +
  • + {% endif %} {% endif %} {% if member %} From cf3e3d6fbcdcbf501b57df2f574f88d5dd3f59bc Mon Sep 17 00:00:00 2001 From: Patrick Mayr Date: Sat, 28 May 2022 23:11:00 +0000 Subject: [PATCH 2/2] fix redirect --- fet2020/authentications/decorators.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fet2020/authentications/decorators.py b/fet2020/authentications/decorators.py index 670430aa..f5fbeabe 100644 --- a/fet2020/authentications/decorators.py +++ b/fet2020/authentications/decorators.py @@ -16,7 +16,7 @@ def authenticated_user(view_func): if request.user.is_authenticated: return view_func(request, *args, **kwargs) else: - return redirect("login") + return redirect("authentications:login") return wrapper_func