mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-02-27 01:41:27 -05:00
do not require extra info in cardless cash form
This commit is contained in:
parent
1d4dbe7ce0
commit
97569bad37
@ -41,12 +41,12 @@ public class CashAtAtmForm extends PaymentMethodForm {
|
|||||||
|
|
||||||
public static int addFormForBuyer(GridPane gridPane, int gridRow,
|
public static int addFormForBuyer(GridPane gridPane, int gridRow,
|
||||||
PaymentAccountPayload paymentAccountPayload) {
|
PaymentAccountPayload paymentAccountPayload) {
|
||||||
CashAtAtmAccountPayload cbm = (CashAtAtmAccountPayload) paymentAccountPayload;
|
CashAtAtmAccountPayload cashAtAtmPayload = (CashAtAtmAccountPayload) paymentAccountPayload;
|
||||||
|
|
||||||
TextArea textExtraInfo = addCompactTopLabelTextArea(gridPane, ++gridRow, 0, Res.get("payment.shared.extraInfo"), "").second;
|
TextArea textExtraInfo = addCompactTopLabelTextArea(gridPane, ++gridRow, 0, Res.get("payment.shared.extraInfo"), "").second;
|
||||||
textExtraInfo.setMinHeight(70);
|
textExtraInfo.setMinHeight(70);
|
||||||
textExtraInfo.setEditable(false);
|
textExtraInfo.setEditable(false);
|
||||||
textExtraInfo.setText(cbm.getExtraInfo());
|
textExtraInfo.setText(cashAtAtmPayload.getExtraInfo());
|
||||||
return gridRow;
|
return gridRow;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -79,7 +79,11 @@ public class CashAtAtmForm extends PaymentMethodForm {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void autoFillNameTextField() {
|
protected void autoFillNameTextField() {
|
||||||
setAccountNameWithString(cashAtAtmAccount.getExtraInfo().substring(0, Math.min(50, cashAtAtmAccount.getExtraInfo().length())));
|
if (cashAtAtmAccount.getExtraInfo() != null && !cashAtAtmAccount.getExtraInfo().isEmpty()) {
|
||||||
|
setAccountNameWithString(cashAtAtmAccount.getExtraInfo().substring(0, Math.min(50, cashAtAtmAccount.getExtraInfo().length())));
|
||||||
|
} else {
|
||||||
|
setAccountNameWithString(cashAtAtmAccount.getSelectedTradeCurrency().getCode());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -104,7 +108,6 @@ public class CashAtAtmForm extends PaymentMethodForm {
|
|||||||
@Override
|
@Override
|
||||||
public void updateAllInputsValid() {
|
public void updateAllInputsValid() {
|
||||||
allInputsValid.set(isAccountNameValid()
|
allInputsValid.set(isAccountNameValid()
|
||||||
&& !cashAtAtmAccount.getExtraInfo().isEmpty()
|
|
||||||
&& paymentAccount.getSingleTradeCurrency() != null);
|
&& paymentAccount.getSingleTradeCurrency() != null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user