Change display of balance post card transaction
This commit is contained in:
parent
f53835a80a
commit
9a64ba1237
|
@ -129,6 +129,7 @@ void loop() {
|
|||
lastStatusText = cardTransaction(wifi, http, apiUrl, scannedCardId, "1.50");
|
||||
if (lastStatusText.startsWith("S:")) {
|
||||
tone(BUZZER_PIN, NOTE_C7, 650);
|
||||
lastStatusText += "€";
|
||||
state = STATE_RESULT_SUCCESS;
|
||||
} else {
|
||||
tone(BUZZER_PIN, NOTE_CS5, 100);
|
||||
|
|
|
@ -19,7 +19,7 @@ public class CardTransaction : Controller {
|
|||
|
||||
user.Balance -= amount;
|
||||
db.Update(user);
|
||||
return $"S:{user.Nickname} - {user.Balance:N2}";
|
||||
return $"S:{user.Nickname}: {user.Balance:N2}";
|
||||
}
|
||||
|
||||
return "E:Unknown card.";
|
||||
|
|
Loading…
Reference in a new issue