|
|
|
@ -119,7 +119,13 @@ def register(request):
|
|
|
|
|
return redirect("index")
|
|
|
|
|
|
|
|
|
|
context = {}
|
|
|
|
|
if request.method == "POST":
|
|
|
|
|
if not global_preferences["helper__enable_registration"]:
|
|
|
|
|
messages.add_message(
|
|
|
|
|
request,
|
|
|
|
|
messages.WARNING if request.method == "POST" else messages.INFO,
|
|
|
|
|
"Aktuell ist es leider nicht möglich, sich für die Helfer*innen zu registrieren. Bitte komm später wieder.",
|
|
|
|
|
)
|
|
|
|
|
elif request.method == "POST":
|
|
|
|
|
form = RegisterForm(request.POST)
|
|
|
|
|
if not form.is_valid():
|
|
|
|
|
context["form"] = form
|
|
|
|
|