Skip to content

Commit

Permalink
Merge pull request #844 from xzzy/master
Browse files Browse the repository at this point in the history
Currency Formatting
  • Loading branch information
xzzy committed Mar 5, 2021
2 parents e6e6a18 + 8a5f9e9 commit 91f8282
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Expand Up @@ -40,7 +40,8 @@ def handle(self, *args, **options):
else:
pass
if c.bank_response_code == '00':
rows.append({'txn_number': c.txn_number,'crn1': c.crn1,'processed_date_time': c.processed_date_time, 'settlement_date': c.settlement_date, 'action': c.action, 'amount': c.amount})
amount = str(c.amount)[:-2]+'.'+str(c.amount)[-2:]
rows.append({'txn_number': c.txn_number,'crn1': c.crn1,'processed_date_time': c.processed_date_time, 'settlement_date': c.settlement_date, 'action': c.action, 'amount': amount})
#rows.append({'txn_number': c.txn_number,'crn1': c.crn1,'processed_date_time': c.processed_date_time, 'settlement_date': c.settlement_date })

#print ("Error: Sending Email Notification: "+settings.NOTIFICATION_EMAIL)
Expand Down
4 changes: 2 additions & 2 deletions ledger/templates/email/missing_payments.html
Expand Up @@ -7,9 +7,9 @@
<b>Report Date: {{ settlement_date }}
<br>
<table>
<tr><th>Txn Number</th><th>Invoice No</th><th>Settlement Date</th><th>Processed Date Time</th><th>Action</th><td>Amount</td></tr>
<tr><th>Txn Number</th><th>Invoice No</th><th>Settlement Date</th><th>Processed Date Time</th><th>Action</th><th>Amount</th></tr>
{% for r in rows %}
<tr><td>{{ r.txn_number }}</td><td>{{ r.crn1 }}</td><td>{{ r.settlement_date }}</td><td>{{ r.processed_date_time }}</td><td>{{ r.action }}</td><td>{{ r.amount }}</td></tr>
<tr><td>{{ r.txn_number }}</td><td>{{ r.crn1 }}</td><td>{{ r.settlement_date }}</td><td>{{ r.processed_date_time }}</td><td>{{ r.action }}</td><td>${{ r.amount }}</td></tr>
{% endfor %}
</table>
<br><br>
Expand Down

0 comments on commit 91f8282

Please sign in to comment.