From cd0df727ccba9d9626ba9e1fb01ca981da600fdd Mon Sep 17 00:00:00 2001 From: Commander1024 Date: Sat, 1 Aug 2020 19:21:59 +0200 Subject: [PATCH] Finally got an input form. :-) --- lostplaces/lostplaces_app/templates/voucher-verify.html | 4 ++-- lostplaces/lostplaces_app/views.py | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/lostplaces/lostplaces_app/templates/voucher-verify.html b/lostplaces/lostplaces_app/templates/voucher-verify.html index b316ff3..899066a 100644 --- a/lostplaces/lostplaces_app/templates/voucher-verify.html +++ b/lostplaces/lostplaces_app/templates/voucher-verify.html @@ -8,8 +8,8 @@

Voucher-Überprüfung

{% csrf_token %} - {{ form.as_p }} - + {{ voucher_form.as_p }} +
{% endblock maincontent %} \ No newline at end of file diff --git a/lostplaces/lostplaces_app/views.py b/lostplaces/lostplaces_app/views.py index 53c9239..e5a9da3 100644 --- a/lostplaces/lostplaces_app/views.py +++ b/lostplaces/lostplaces_app/views.py @@ -21,7 +21,8 @@ class VoucherVerify(View): fields = ['code'] def get(self, request, *args, **kwargs): - return render(request, 'voucher-verify.html') + voucher_form = VoucherVerifyForm() + return render(request, 'voucher-verify.html', {'voucher_form': voucher_form}) class SignUpView(CreateView): form_class = ExplorerCreationForm