diff options
author | MS <ms@taler.net> | 2020-10-01 15:38:17 +0200 |
---|---|---|
committer | MS <ms@taler.net> | 2020-10-01 15:38:17 +0200 |
commit | 7352d8815916e4da2ee283b9e968b8ff233dc1fd (patch) | |
tree | 089a012ef94044467a9fd801a641d16c07b24116 /talerbank | |
parent | ec3982590a32478b0915e83576355cf78ea5ad8f (diff) | |
download | bank-7352d8815916e4da2ee283b9e968b8ff233dc1fd.tar.gz bank-7352d8815916e4da2ee283b9e968b8ff233dc1fd.tar.bz2 bank-7352d8815916e4da2ee283b9e968b8ff233dc1fd.zip |
withdrawal abort button
Diffstat (limited to 'talerbank')
-rw-r--r-- | talerbank/app/templates/withdraw_confirm.html | 5 | ||||
-rw-r--r-- | talerbank/app/views.py | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/talerbank/app/templates/withdraw_confirm.html b/talerbank/app/templates/withdraw_confirm.html index d9f57de..27be9f1 100644 --- a/talerbank/app/templates/withdraw_confirm.html +++ b/talerbank/app/templates/withdraw_confirm.html @@ -38,6 +38,11 @@ <p> What is {{ question }} ? </p> + <form method="post" action="{{ url('withdraw-confirm', user_id, withdraw_id) }}" class="pure-form"> + <input type="hidden" name="csrfmiddlewaretoken" value="{{ csrf_token }}" /> + <input type="submit" value="Abort" class="pure-button pure-button-primary" /> + </form> + <form method="post" action="{{ url('withdraw-confirm', withdraw_id) }}" class="pure-form"> <input type="hidden" name="csrfmiddlewaretoken" value="{{ csrf_token }}" /> <input type="text" name="pin_0" value="" autocomplete="off" autofocus /> diff --git a/talerbank/app/views.py b/talerbank/app/views.py index 8e8d9a9..c909d59 100644 --- a/talerbank/app/views.py +++ b/talerbank/app/views.py @@ -1226,7 +1226,6 @@ def confirm_withdrawal(request, withdraw_id): set_profile_hint( request, success=True, failure=False, hint="Withdrawal successful!" ) - request.session["just_withdrawn"] = True return redirect("profile") @@ -1236,6 +1235,7 @@ def confirm_withdrawal(request, withdraw_id): question=question, hashed_answer=hashed_answer, withdraw_id=withdraw_id, + account_id=request.user.username, amount=op.amount.stringify(settings.TALER_DIGITS), exchange=op.selected_exchange_account.user, ) |