[bisq-network/bisq] Add SWIFT payment method (#5672)

Christoph Atteneder notifications at github.com
Thu Sep 9 10:35:05 CEST 2021


@ripcurlx requested changes on this pull request.

NACK - Please see my comments. As I have the changes locally already I'll push them to the branch as soon as I'm done with the Regtest test run. So please wait for doing the changes on your own.

> +import static bisq.core.payment.payload.SwiftAccountPayload.*;
+
+public class SwiftForm extends PaymentMethodForm {
+    private final SwiftAccountPayload formData;
+    private CheckBox useIntermediaryCheck;
+    private LengthValidator defaultValidator = new LengthValidator(2, 34);
+    private LengthValidator swiftValidator = new LengthValidator(11, 11);
+    private LengthValidator accountNrValidator = new LengthValidator(2, 40);
+    private LengthValidator addressValidator = new LengthValidator(1, 100);
+
+    public SwiftForm(PaymentAccount paymentAccount,
+                     AccountAgeWitnessService accountAgeWitnessService,
+                     InputValidator defaultValidator, GridPane gridPane, int gridRow, CoinFormatter formatter) {
+        super(paymentAccount, accountAgeWitnessService, defaultValidator, gridPane, gridRow, formatter);
+        this.formData = ((SwiftAccount) paymentAccount).getPayload();
+        this.useIntermediaryCheck = new CheckBox(Res.get("payment.swift.use.intermediary"));

```suggestion
        this.useIntermediaryCheck = new AutoTooltipCheckBox(Res.get("payment.swift.use.intermediary"));
```
Should be 
![Bildschirmfoto 2021-09-09 um 10 21 18](https://user-images.githubusercontent.com/170962/132650764-d21100a0-57cf-46a9-8410-5f404dfea48c.png)
Instead of 
![Bildschirmfoto 2021-09-09 um 10 19 33](https://user-images.githubusercontent.com/170962/132650795-5855bd73-ea2a-4e76-85c2-9358e0e123bb.png)


> +        beneficiaryCityField.setValidator(defaultValidator);
+        beneficiaryCityField.textProperty().addListener((ov, oldValue, newValue) -> {
+            formData.setBeneficiaryCity(newValue.trim());
+            updateFromInputs();
+        });
+
+        label = Res.get(Res.get(PHONE + BENEFICIARYPOSTFIX));
+        InputTextField beneficiaryPhoneField = addInputTextField(gridPane, ++gridRow, label);
+        beneficiaryPhoneField.setPromptText(label);
+        beneficiaryPhoneField.setValidator(defaultValidator);
+        beneficiaryPhoneField.textProperty().addListener((ov, oldValue, newValue) -> {
+            formData.setBeneficiaryPhone(newValue.trim());
+            updateFromInputs();
+        });
+
+        label = Res.get("payment.shared.optionalExtraInfo");

```suggestion
        label = Res.get("payment.shared.optionalExtra");
```
Wrong key
![Bildschirmfoto 2021-09-09 um 10 27 58](https://user-images.githubusercontent.com/170962/132651138-6b90dcde-42dd-4483-ab0c-0617c8c76f1a.png)


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/5672#pullrequestreview-750035700
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20210909/07656ab9/attachment.htm>


More information about the bisq-github mailing list