Skip to content

Commit 54e80c1

Browse files
committed
Switch to currency symbol
1 parent b7a59f4 commit 54e80c1

File tree

5 files changed

+13
-16
lines changed

5 files changed

+13
-16
lines changed

templates/webserver/website/.env

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@ APP_ENV=dev
22
DATABASE_URL="sqlite:///%kernel.project_dir%/var/app.db"
33
KOFI_NAME=filipmania
44
KOFI_TARGET=12.49
5-
KOFI_CURRENCY=EUR
5+
KOFI_CURRENCY=
66
KOFI_STARTDATE="2023-10-22 15:35:11"

templates/webserver/website/public/css/index.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ iframe {
99
background:#f9f9f9;
1010
}
1111

12-
img {
12+
img, iframe {
1313
display: block;
1414
margin: auto;
1515
}

templates/webserver/website/templates/index.html.twig

+3-3
Original file line numberDiff line numberDiff line change
@@ -51,17 +51,17 @@
5151
</div>
5252

5353
<div class="c">
54-
Balance for {{ 'now' | date('F Y') }}: {{ balance }} / {{ kofi_target }} {{ kofi_currency }}
54+
Balance for {{ 'now' | date('F Y') }}: {{ kofi_currency }}{{ balance }} of {{ kofi_currency }}{{ kofi_target }}
5555
<script src="{{ asset('js/css_random.js') }}"></script>
5656
<ul>
5757
{% for donation in donations %}
5858
<li>
5959
{{ '%02d/%02d/%d %s' | format(donation.day, donation.month, donation.year, donation.time) }}<br>
60-
{{ donation.name }} donated {{ donation.amount_sent }} {{ kofi_currency }}{% if donation.message %}: {{ donation.message }}{% endif %}
60+
{{ donation.name }} donated {{ kofi_currency }}{{ donation.amount_sent }}{% if donation.message %}: {{ donation.message }}{% endif %}
6161
</li>
6262
{% endfor %}
6363
</ul>
64-
The amount(s) above include the transfer fee which is around 3% + 0.3 {{ kofi_currency }}<br>
64+
The amounts above include the transfer fee which is about 3% + {{ kofi_currency }}0.3<br>
6565
<br>
6666
This server has been up since {{ kofi_startdate | date('d/m/Y H:i:s') }} {{ 'now' | date('T') }}
6767
</div>

templates/webserver/website/templates/stats.html.twig

+6-5
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,21 @@
33
{% block title %}MF statistics{% endblock %}
44

55
{% block body %}
6-
A total of {{ sum }} {{ kofi_currency }} in donations was received for MF<br>
7-
Approximate net balance: {{ balance }} {{ kofi_currency }}<br>
8-
<br>
6+
A total of {{ kofi_currency }}{{ sum }} in donations was received for MF<br>
7+
Approximate net balance:
8+
{{ balance > 0 ? kofi_currency ~ balance : '-' ~ kofi_currency ~ (-balance) }}
9+
<br><br>
910

1011
Top 10 donators:
1112
<script src="{{ asset('js/css_random.js') }}"></script>
1213
<ul>
1314
{% for donator in donators %}
1415
<li>
15-
{{ donator.name }} donated {{ donator.amount }} {{ kofi_currency }} over {{ donator.times }} donation(s)
16+
{{ donator.name }} donated {{ kofi_currency }}{{ donator.amount }} over {{ donator.times }} donation(s)
1617
</li>
1718
{% endfor %}
1819
</ul>
19-
The amount(s) above include the transfer fee which is around 3% + 0.3 {{ kofi_currency }}<br>
20+
The amounts above include the transfer fee which is about 3% + {{ kofi_currency }}0.3<br>
2021
<br>
2122

2223
Donation activity:

vars.yml

+2-6
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,7 @@ install_path: "/opt/{{ server_user }}"
66
ServerName: example.com
77
ServerAdmin: [email protected]
88
AdminPassword: P@ssword123!
9-
kofi_name: filipmania
109
kofi_token: 904939d1-5699-4da2-86c4-6caf067854f0
11-
kofi_target: 12.49
12-
kofi_currency: EUR
13-
kofi_startdate: 2023-10-22 15:35:11
14-
kofi_paypal_clientid: ASMC28YsAMD5X9jEM0HUUowekCM9YIhgEu1fziuY8XL-7FCMCFx5o1srmKkdV_DVy1dUS4kpAt0knCxK
15-
kofi_paypal_secretkey: EP7lIjI_h__Gu-7IPaf95hT4P7zLzm2PuVkvfHm7MBBvOGqV3K1FmRZ0v6XUMmoTQqOlG7dY4X5waSUL
10+
paypal_clientid: ASMC28YsAMD5X9jEM0HUUowekCM9YIhgEu1fziuY8XL-7FCMCFx5o1srmKkdV_DVy1dUS4kpAt0knCxK
11+
paypal_secretkey: EP7lIjI_h__Gu-7IPaf95hT4P7zLzm2PuVkvfHm7MBBvOGqV3K1FmRZ0v6XUMmoTQqOlG7dY4X5waSUL
1612
app_secret: 35c4226386b747b023c298aecfd67ec73b7cf60e7e0e3b63d5ae0a72df78a144

0 commit comments

Comments
 (0)