Release 8 (devel -> main) #30
12 changed files with 81 additions and 79 deletions
|
@ -51,7 +51,7 @@ class Drink(models.Model):
|
|||
self.deleted = True
|
||||
super().save()
|
||||
|
||||
def __str__(self): return f"{self.product_name} ({str(self.content_litres).rstrip('0')}l) - {self.price}{settings.CURRENCY_SUFFIX}"
|
||||
def __str__(self): return f"{self.product_name} ({float(self.content_litres):.2f}l) - {self.price}{settings.CURRENCY_SUFFIX}"
|
||||
|
||||
|
||||
class RegisterTransaction(models.Model):
|
||||
|
@ -145,7 +145,7 @@ class Order(models.Model):
|
|||
drink.save()
|
||||
super().delete(*args, **kwargs)
|
||||
|
||||
def __str__(self): return f"{self.drink.product_name} ({str(self.drink.content_litres).rstrip('0')}l) x {self.amount} - {self.price_sum}{settings.CURRENCY_SUFFIX}"
|
||||
def __str__(self): return f"{self.drink.product_name} ({float(self.drink.content_litres):.2f}l) x {self.amount} - {self.price_sum}{settings.CURRENCY_SUFFIX}"
|
||||
|
||||
|
||||
class Global(models.Model):
|
||||
|
|
|
@ -2,5 +2,5 @@
|
|||
|
||||
<div class="footer">
|
||||
<div>Version {{ app_version }}</div>
|
||||
<div>Copyright (C) 2021, <a href="https://gitlab.com/W13R">Julian Müller (W13R)</a></div>
|
||||
<div>Copyright (C) 2021, Julian Müller (W13R)</div>
|
||||
</div>
|
||||
|
|
|
@ -82,7 +82,7 @@
|
|||
{% else %}
|
||||
|
||||
<div class="centeringFlex">
|
||||
<p>{% translate "You can't order this, because you have a negative balance." %}</p>
|
||||
<p>{% translate "Your balance is too low to order a drink." %}</p>
|
||||
<a href="/">{% translate "back" %}</a>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
<div class="horizontalButtonList">
|
||||
<a class="button" id="navBarBtnHome" href="/">Home</a>
|
||||
<a class="button" id="navBarBtnDeposit" href="/deposit">{% translate "Deposit" %}</a>
|
||||
<a class="button" href="/accounts/logout">{% translate "Logout" %}</a>
|
||||
<div class="dropDownMenu" id="dropDownMenu">
|
||||
<button class="dropDownButton" id="dropDownMenuButton">
|
||||
<div>{% translate "Account" %}</div>
|
||||
|
@ -28,7 +29,6 @@
|
|||
<a class="button dropDownChoice" href="/admin/">Admin Panel</a>
|
||||
{% endif %}
|
||||
<a class="button dropDownChoice" href="/accounts/password_change/">{% translate "Change Password" %}</a>
|
||||
<a class="button dropDownChoice" href="/accounts/logout">{% translate "Logout" %}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Binary file not shown.
|
@ -8,11 +8,10 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2021-12-22 11:07+0100\n"
|
||||
"POT-Creation-Date: 2022-06-13 19:01+0200\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"Language: \n"
|
||||
"Last-Translator: Julian Müller (W13R)\n"
|
||||
"Language: DE\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
@ -26,7 +25,7 @@ msgstr "Django Administrator"
|
|||
msgid "Django administration"
|
||||
msgstr "Django Administration"
|
||||
|
||||
#: app/templates/baseLayout.html:43
|
||||
#: app/templates/baseLayout.html:41
|
||||
msgid "An error occured. Please log out and log in again."
|
||||
msgstr "Ein Fehler ist aufgetreten. Bitte ab- und wieder anmelden."
|
||||
|
||||
|
@ -34,7 +33,7 @@ msgstr "Ein Fehler ist aufgetreten. Bitte ab- und wieder anmelden."
|
|||
msgid "Drinks - Deposit"
|
||||
msgstr "Getränke - Einzahlen"
|
||||
|
||||
#: app/templates/deposit.html:14 app/templates/userPanel.html:23
|
||||
#: app/templates/deposit.html:14 app/templates/userPanel.html:19
|
||||
msgid "Deposit"
|
||||
msgstr "Einzahlen"
|
||||
|
||||
|
@ -42,7 +41,7 @@ msgstr "Einzahlen"
|
|||
msgid "Amount"
|
||||
msgstr "Summe"
|
||||
|
||||
#: app/templates/deposit.html:31 app/templates/order.html:71
|
||||
#: app/templates/deposit.html:31 app/templates/order.html:72
|
||||
#: app/templates/registration/login.html:56
|
||||
msgid "cancel"
|
||||
msgstr "Abbrechen"
|
||||
|
@ -55,7 +54,7 @@ msgstr "Bestätigen"
|
|||
msgid "Drinks - History"
|
||||
msgstr "Getränke - Verlauf"
|
||||
|
||||
#: app/templates/history.html:14 app/templates/userPanel.html:21
|
||||
#: app/templates/history.html:14 app/templates/userPanel.html:25
|
||||
msgid "History"
|
||||
msgstr "Verlauf"
|
||||
|
||||
|
@ -63,10 +62,10 @@ msgstr "Verlauf"
|
|||
msgid "last 30 actions"
|
||||
msgstr "letzte 30 Vorgänge"
|
||||
|
||||
#: app/templates/history.html:33 app/templates/statistics.html:69
|
||||
#: app/templates/statistics.html:89 app/templates/statistics.html:109
|
||||
#: app/templates/statistics.html:129 app/templates/statistics.html:149
|
||||
#: app/templates/statistics.html:169
|
||||
#: app/templates/history.html:33 app/templates/statistics.html:41
|
||||
#: app/templates/statistics.html:61 app/templates/statistics.html:81
|
||||
#: app/templates/statistics.html:101 app/templates/statistics.html:121
|
||||
#: app/templates/statistics.html:141
|
||||
msgid "No history."
|
||||
msgstr "Kein Verlauf verfügbar."
|
||||
|
||||
|
@ -86,49 +85,47 @@ msgstr "verfügbar"
|
|||
msgid "No drinks available."
|
||||
msgstr "Es sind gerade keine Getränke verfügbar."
|
||||
|
||||
#: app/templates/order.html:6
|
||||
#: app/templates/order.html:7
|
||||
msgid "Drinks - Order"
|
||||
msgstr "Getränke - Bestellen"
|
||||
|
||||
#: app/templates/order.html:15
|
||||
#: app/templates/order.html:16
|
||||
msgid "Order"
|
||||
msgstr "Bestellung"
|
||||
|
||||
#: app/templates/order.html:28
|
||||
#: app/templates/order.html:29
|
||||
msgid "Drink"
|
||||
msgstr "Getränk"
|
||||
|
||||
#: app/templates/order.html:33
|
||||
#: app/templates/order.html:34
|
||||
msgid "Price per Item"
|
||||
msgstr "Preis pro Getränk"
|
||||
|
||||
#: app/templates/order.html:39
|
||||
#: app/templates/order.html:40
|
||||
msgid "Available"
|
||||
msgstr "Verfügbar"
|
||||
|
||||
#: app/templates/order.html:45
|
||||
#: app/templates/order.html:46
|
||||
msgid "Count"
|
||||
msgstr "Anzahl"
|
||||
|
||||
#: app/templates/order.html:62
|
||||
#: app/templates/order.html:63
|
||||
msgid "Sum"
|
||||
msgstr "Summe"
|
||||
|
||||
#: app/templates/order.html:72
|
||||
#: app/templates/order.html:73
|
||||
msgid "order"
|
||||
msgstr "Bestellen"
|
||||
|
||||
#: app/templates/order.html:84
|
||||
msgid "You can't order this, because you have a negative balance."
|
||||
msgstr ""
|
||||
"Sie können momentan keine Bestellungen aufgeben, da Sie einen negativen "
|
||||
"Saldo haben."
|
||||
#: app/templates/order.html:85
|
||||
msgid "Your balance is too low to order a drink."
|
||||
msgstr "Dein Saldo ist zu niedrig um Getränke zu bestellen."
|
||||
|
||||
#: app/templates/order.html:85 app/templates/order.html:94
|
||||
#: app/templates/order.html:86 app/templates/order.html:95
|
||||
msgid "back"
|
||||
msgstr "zurück"
|
||||
|
||||
#: app/templates/order.html:93
|
||||
#: app/templates/order.html:94
|
||||
msgid "This drink is not available."
|
||||
msgstr "Dieses Getränk ist gerade nicht verfügbar."
|
||||
|
||||
|
@ -138,13 +135,12 @@ msgstr "Getränke - Abgemeldet"
|
|||
|
||||
#: app/templates/registration/logged_out.html:17
|
||||
msgid "Logged out! You will be redirected shortly."
|
||||
msgstr "Sie wurden abgemeldet und werden in Kürze weitergeleitet."
|
||||
msgstr "Du wurdest abgemeldet und wirst in Kürze weitergeleitet."
|
||||
|
||||
#: app/templates/registration/logged_out.html:19
|
||||
msgid "Click here if automatic redirection does not work."
|
||||
msgstr ""
|
||||
"Bitte klicken Sie hier, wenn die automatische Weiterleitung nicht "
|
||||
"funktionieren sollte."
|
||||
"Bitte klicke hier, wenn die automatische Weiterleitung nicht funktioniert."
|
||||
|
||||
#: app/templates/registration/login.html:7
|
||||
msgid "Drinks - Login"
|
||||
|
@ -164,75 +160,75 @@ msgstr "Anmelden"
|
|||
|
||||
#: app/templates/registration/login.html:65
|
||||
msgid "Choose your account"
|
||||
msgstr "Bitte wählen Sie Ihren Account"
|
||||
msgstr "Wähle deinen Account"
|
||||
|
||||
#: app/templates/statistics.html:6
|
||||
msgid "Drinks - Statistics"
|
||||
msgstr "Getränke - Statistiken"
|
||||
|
||||
#: app/templates/statistics.html:15 app/templates/userPanel.html:22
|
||||
#: app/templates/statistics.html:15 app/templates/userPanel.html:26
|
||||
msgid "Statistics"
|
||||
msgstr "Statistiken"
|
||||
|
||||
#: app/templates/statistics.html:26
|
||||
msgid "Choose"
|
||||
msgstr "Auswählen"
|
||||
|
||||
#: app/templates/statistics.html:31 app/templates/statistics.html:54
|
||||
msgid "Your orders per drink"
|
||||
msgstr "Deine Bestellungen pro Getränk"
|
||||
|
||||
#: app/templates/statistics.html:34 app/templates/statistics.html:134
|
||||
msgid "Your orders per weekday"
|
||||
msgstr "Deine Bestellungen pro Wochentag"
|
||||
|
||||
#: app/templates/statistics.html:37 app/templates/statistics.html:94
|
||||
msgid "Your orders per month (last 12 months)"
|
||||
msgstr "Deine Bestellungen pro Monat (letzte 12 Monate)"
|
||||
|
||||
#: app/templates/statistics.html:40 app/templates/statistics.html:74
|
||||
msgid "All orders per drink"
|
||||
msgstr "Alle Bestellungen pro Getränk"
|
||||
|
||||
#: app/templates/statistics.html:43 app/templates/statistics.html:154
|
||||
msgid "All orders per weekday"
|
||||
msgstr "Alle Bestellungen pro Wochentag"
|
||||
|
||||
#: app/templates/statistics.html:46 app/templates/statistics.html:114
|
||||
msgid "All orders per month (last 12 months)"
|
||||
msgstr "Alle Bestellungen pro Monat (letzte 12 Monate)"
|
||||
|
||||
#: app/templates/statistics.html:58 app/templates/statistics.html:78
|
||||
#: app/templates/statistics.html:30 app/templates/statistics.html:50
|
||||
msgid "drink"
|
||||
msgstr "Getränk"
|
||||
|
||||
#: app/templates/statistics.html:59 app/templates/statistics.html:79
|
||||
#: app/templates/statistics.html:99 app/templates/statistics.html:119
|
||||
#: app/templates/statistics.html:139 app/templates/statistics.html:159
|
||||
#: app/templates/statistics.html:31 app/templates/statistics.html:51
|
||||
#: app/templates/statistics.html:71 app/templates/statistics.html:91
|
||||
#: app/templates/statistics.html:111 app/templates/statistics.html:131
|
||||
msgid "count"
|
||||
msgstr "Anzahl"
|
||||
|
||||
#: app/templates/statistics.html:98 app/templates/statistics.html:118
|
||||
#: app/templates/statistics.html:46
|
||||
msgid "All orders per drink"
|
||||
msgstr "Alle Bestellungen pro Getränk"
|
||||
|
||||
#: app/templates/statistics.html:66
|
||||
msgid "Your orders per month (last 12 months)"
|
||||
msgstr "Deine Bestellungen pro Monat (letzte 12 Monate)"
|
||||
|
||||
#: app/templates/statistics.html:70 app/templates/statistics.html:90
|
||||
msgid "month"
|
||||
msgstr "Monat"
|
||||
|
||||
#: app/templates/statistics.html:138 app/templates/statistics.html:158
|
||||
#: app/templates/statistics.html:86
|
||||
msgid "All orders per month (last 12 months)"
|
||||
msgstr "Alle Bestellungen pro Monat (letzte 12 Monate)"
|
||||
|
||||
#: app/templates/statistics.html:106
|
||||
msgid "Your orders per weekday"
|
||||
msgstr "Deine Bestellungen pro Wochentag"
|
||||
|
||||
#: app/templates/statistics.html:110 app/templates/statistics.html:130
|
||||
msgid "day"
|
||||
msgstr "Tag"
|
||||
|
||||
#: app/templates/userPanel.html:7 app/templates/userPanel.html:9
|
||||
#: app/templates/statistics.html:126
|
||||
msgid "All orders per weekday"
|
||||
msgstr "Alle Bestellungen pro Wochentag"
|
||||
|
||||
#: app/templates/userPanel.html:6 app/templates/userPanel.html:8
|
||||
msgid "User"
|
||||
msgstr "Benutzer"
|
||||
|
||||
#: app/templates/userPanel.html:13 app/templates/userPanel.html:15
|
||||
#: app/templates/userPanel.html:12 app/templates/userPanel.html:14
|
||||
msgid "Balance"
|
||||
msgstr "Saldo"
|
||||
|
||||
#: app/templates/userPanel.html:27
|
||||
#: app/templates/userPanel.html:22
|
||||
msgid "Account"
|
||||
msgstr "Account"
|
||||
|
||||
#: app/templates/userPanel.html:30
|
||||
msgid "Change Password"
|
||||
msgstr "Passwort ändern"
|
||||
|
||||
#: app/templates/userPanel.html:29
|
||||
#: app/templates/userPanel.html:31
|
||||
msgid "Logout"
|
||||
msgstr "Abmelden"
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ Before the actual setup, you have to satisfy the following dependencies:
|
|||
|
||||
### Python Packages (pip)
|
||||
|
||||
All required python packages are listed in [pip-dependencies.txt](/pip-dependencies.txt)
|
||||
All required python packages are listed in [requirements.txt](/requirements.txt)
|
||||
|
||||
You can install the required python packages with
|
||||
```bash
|
||||
|
|
|
@ -4,4 +4,4 @@
|
|||
|
||||
wd=$(dirname $0)
|
||||
|
||||
pip3 install -r "$wd/pip-dependencies.txt" -t "$wd/packages"
|
||||
pip3 install -r "$wd/requirements.txt" -t "$wd/packages"
|
||||
|
|
|
@ -2,5 +2,5 @@
|
|||
|
||||
export DJANGO_SK_ABS_FP="$(pwd)/config/secret_key.txt"
|
||||
export STATIC_FILES="$(pwd)/static/"
|
||||
export APP_VERSION="7"
|
||||
export APP_VERSION="8"
|
||||
export PYTHONPATH="$(pwd)/packages/"
|
||||
|
|
|
@ -60,8 +60,8 @@ main > h1 {
|
|||
width: fit-content;
|
||||
}
|
||||
.passwordOverlay > form > h1 {
|
||||
margin-top: 3rem;
|
||||
margin-bottom: 3rem;
|
||||
margin-top: 2rem;
|
||||
margin-bottom: 2rem;
|
||||
}
|
||||
form input[type="password"], form input[type="text"] {
|
||||
width: 94%;
|
||||
|
@ -110,7 +110,4 @@ form input[type="password"], form input[type="text"] {
|
|||
font-size: 1.16rem;
|
||||
margin: .2rem;
|
||||
}
|
||||
.passwordOverlay {
|
||||
margin-top: 2rem;
|
||||
}
|
||||
}
|
|
@ -349,6 +349,9 @@ h1 {
|
|||
}
|
||||
/* MOBILE OPTIMIZATIONS */
|
||||
@media only screen and (max-width: 700px) {
|
||||
main {
|
||||
margin-top: 1.5rem;
|
||||
}
|
||||
.globalMessage span {
|
||||
width: 90%;
|
||||
}
|
||||
|
@ -361,5 +364,11 @@ h1 {
|
|||
margin-right: 0;
|
||||
margin-left: 0;
|
||||
margin-top: .5rem;
|
||||
justify-content: center;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
.userPanel > .horizontalButtonList > .button,
|
||||
.userPanel > .horizontalButtonList > .dropDownMenu {
|
||||
margin: 0.25rem;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue