Skip to content

Commit 6446b42

Browse files
authored
🐛 Fix: Set a maximum credits to buy (ITISFoundation#5545)
1 parent 95bf48b commit 6446b42

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

services/static-webserver/client/source/class/osparc/desktop/credits/BuyCreditsInput.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,9 @@ qx.Class.define("osparc.desktop.credits.BuyCreditsInput", {
6767
osparc.store.Store.getInstance().getMinimumAmount()
6868
.then(minimum => {
6969
amountInput.set({
70-
value: Math.ceil(minimum/this.__pricePerCredit),
71-
minimum: Math.ceil(minimum/this.__pricePerCredit)
70+
maximum: 10000,
71+
minimum: Math.ceil(minimum/this.__pricePerCredit),
72+
value: Math.ceil(minimum/this.__pricePerCredit)
7273
});
7374
});
7475
},
@@ -80,7 +81,7 @@ qx.Class.define("osparc.desktop.credits.BuyCreditsInput", {
8081
const input = new qx.ui.form.TextField().set({
8182
appearance: "appmotion-buy-credits-input",
8283
textAlign: "center",
83-
width: 80,
84+
width: 90,
8485
...inputProps
8586
});
8687
const label = new qx.ui.basic.Label(labelText);
@@ -95,7 +96,7 @@ qx.Class.define("osparc.desktop.credits.BuyCreditsInput", {
9596
}));
9697
const input = new qx.ui.form.Spinner().set({
9798
appearance: "appmotion-buy-credits-spinner",
98-
width: 80,
99+
width: 100,
99100
...inputProps
100101
});
101102
input.getChildControl("textfield").set({

0 commit comments

Comments
 (0)