[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-bank] branch master updated: striking cancelled wire
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-bank] branch master updated: striking cancelled wire transfers' subject lines through. |
Date: |
Wed, 13 Dec 2017 16:53:17 +0100 |
This is an automated email from the git hooks/post-receive script.
marcello pushed a commit to branch master
in repository bank.
The following commit(s) were added to refs/heads/master by this push:
new 8e1bd9c striking cancelled wire transfers' subject lines through.
8e1bd9c is described below
commit 8e1bd9c5ed5cb329b957021f36ab2086f2208d5a
Author: Marcello Stanisci <address@hidden>
AuthorDate: Wed Dec 13 16:52:07 2017 +0100
striking cancelled wire transfers' subject lines through.
---
talerbank/app/static/bank.css | 4 ++++
talerbank/app/templates/profile_page.html | 15 +++++++++++++--
talerbank/app/urls.py | 1 +
talerbank/app/views.py | 10 ++++++++++
4 files changed, 28 insertions(+), 2 deletions(-)
diff --git a/talerbank/app/static/bank.css b/talerbank/app/static/bank.css
index c01fc13..0f38f11 100644
--- a/talerbank/app/static/bank.css
+++ b/talerbank/app/static/bank.css
@@ -8,3 +8,7 @@ a.pure-button {
right: 20px;
top: 23px;
}
+
+.cancelled {
+ text-decoration: line-through;
+}
diff --git a/talerbank/app/templates/profile_page.html
b/talerbank/app/templates/profile_page.html
index ef53437..608dc82 100644
--- a/talerbank/app/templates/profile_page.html
+++ b/talerbank/app/templates/profile_page.html
@@ -154,8 +154,19 @@
<td style="text-align:right">
{{ item.sign }} {{ item.amount }}
</td>
- <td class="text-align:left">{% if item.counterpart_username %} {{
item.counterpart_username }} {% endif %} (account #{{ item.counterpart }})</td>
- <td class="text-align:left">{{ item.subject }}</td>
+ <td class="text-align:left">
+ {% if item.counterpart_username %}
+ {{ item.counterpart_username }}
+ {% endif %} (account #{{ item.counterpart }})
+ </td>
+ <td class="text-align:left
+ {% if item.cancelled %}
+ cancelled
+ {% endif %}">{{ item.subject }}
+ </td>
+ <td>
+ <a href="/strike?row_id={{ item.row_id }}">strike this line</a>
+ </td>
</tr>
{% endfor %}
</tbody>
diff --git a/talerbank/app/urls.py b/talerbank/app/urls.py
index c44c7c3..6e97b89 100644
--- a/talerbank/app/urls.py
+++ b/talerbank/app/urls.py
@@ -29,6 +29,7 @@ urlpatterns = [
url(r'^profile$', views.profile_page, name="profile"),
url(r'^history$', views.serve_history, name="history"),
url(r'^reject$', views.reject, name="reject"),
+ url(r'^strike$', views.strike, name="strike"),
url(r'^withdraw$', views.withdraw_nojs, name="withdraw-nojs"),
url(r'^public-accounts$', views.serve_public_accounts,
name="public-accounts"),
url(r'^public-accounts/(?P<name>[a-zA-Z0-9 ]+)$',
diff --git a/talerbank/app/views.py b/talerbank/app/views.py
index ed89f6d..49890cb 100644
--- a/talerbank/app/views.py
+++ b/talerbank/app/views.py
@@ -330,6 +330,9 @@ def extract_history(account):
counterpart = item.credit_account
sign = "-"
entry = dict(
+ row_id=item.id,
+ cancelled=item.cancelled,
+ reimburses=item.reimburses,
sign=sign,
amount=item.amount.stringify(settings.TALER_DIGITS),
counterpart=counterpart.account_no,
@@ -459,6 +462,13 @@ def auth_and_login(request):
return django.contrib.auth.authenticate(username=username,
password=password)
address@hidden
+def strike(request):
+ trans = BankTransaction.objects.get(id=request.GET["row_id"])
+ trans.cancelled = True
+ trans.save()
+ return redirect("profile")
+
@transaction.atomic
@csrf_exempt
@require_http_methods(["PUT", "POST"])
--
To stop receiving notification emails like this one, please contact
address@hidden
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] [taler-bank] branch master updated: striking cancelled wire transfers' subject lines through.,
gnunet <=