Skip to content

Commit

Permalink
Merge pull request #1713 from ManfredKarrer/F2F-contact-info
Browse files Browse the repository at this point in the history
Add contact info for seller in case of aa F2F trade
  • Loading branch information
ripcurlx authored Sep 24, 2018
2 parents c2df7ce + 38e910c commit a41c20c
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 5 deletions.
3 changes: 2 additions & 1 deletion core/src/main/resources/i18n/displayStrings.properties
Original file line number Diff line number Diff line change
Expand Up @@ -531,14 +531,15 @@ portfolio.pending.step2_buyer.halCashInfo.headline=Send HalCash code
portfolio.pending.step2_buyer.halCashInfo.msg=You need to send a text message with the HalCash code as well as the \
trade ID ({0}) to the BTC seller.\nThe seller''s mobile nr. is {1}.\n\n\
Did you send the code to the seller?
portfolio.pending.step2_buyer.fasterPaymentsHolderNameInfo=Some banks might require the receivers name. \
portfolio.pending.step2_buyer.fasterPaymentsHolderNameInfo=Some banks might require the receiver's name. \
The UK sort code and account number is sufficient for a Faster Payment transfer and the receivers name is not verified \
by any of the banks.
portfolio.pending.step2_buyer.confirmStart.headline=Confirm that you have started the payment
portfolio.pending.step2_buyer.confirmStart.msg=Did you initiate the {0} payment to your trading partner?
portfolio.pending.step2_buyer.confirmStart.yes=Yes, I have started the payment

portfolio.pending.step2_seller.waitPayment.headline=Wait for payment
portfolio.pending.step2_seller.f2fInfo.headline=Buyer's contact information
portfolio.pending.step2_seller.waitPayment.msg=The deposit transaction has at least one blockchain confirmation.\nYou need to wait until the BTC buyer starts the {0} payment.
portfolio.pending.step2_seller.warn=The BTC buyer still has not done the {0} payment.\nYou need to wait until he starts the payment.\nIf the trade has not been completed on {1} the arbitrator will investigate.
portfolio.pending.step2_seller.openForDispute=The BTC buyer has not started his payment!\nThe max. allowed period for the trade has elapsed.\nYou can wait longer and give the trading peer more time or contact the arbitrator for opening a dispute.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,10 @@ public class F2FForm extends PaymentMethodForm {
private Country selectedCountry;

public static int addFormForBuyer(GridPane gridPane, int gridRow,
PaymentAccountPayload paymentAccountPayload, Offer offer) {
PaymentAccountPayload paymentAccountPayload, Offer offer, double top) {
F2FAccountPayload f2fAccountPayload = (F2FAccountPayload) paymentAccountPayload;
addLabelTextFieldWithCopyIcon(gridPane, ++gridRow, Res.getWithCol("shared.country"),
CountryUtil.getNameAndCode(f2fAccountPayload.getCountryCode()));
CountryUtil.getNameAndCode(f2fAccountPayload.getCountryCode()), top);
addLabelTextFieldWithCopyIcon(gridPane, ++gridRow, Res.getWithCol("payment.f2f.contact"),
f2fAccountPayload.getContact());
addLabelTextFieldWithCopyIcon(gridPane, ++gridRow, Res.getWithCol("payment.f2f.city"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ protected void addContent() {
break;
case PaymentMethod.F2F_ID:
checkNotNull(model.dataModel.getTrade().getOffer(), "model.dataModel.getTrade().getOffer() must not be null");
gridRow = F2FForm.addFormForBuyer(gridPane, gridRow, paymentAccountPayload, model.dataModel.getTrade().getOffer());
gridRow = F2FForm.addFormForBuyer(gridPane, gridRow, paymentAccountPayload, model.dataModel.getTrade().getOffer(), 0);
break;
case PaymentMethod.BLOCK_CHAINS_ID:
String labelTitle = Res.get("portfolio.pending.step2_buyer.sellersAddress",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,14 @@

package bisq.desktop.main.portfolio.pendingtrades.steps.seller;

import bisq.desktop.components.paymentmethods.F2FForm;
import bisq.desktop.main.portfolio.pendingtrades.PendingTradesViewModel;
import bisq.desktop.main.portfolio.pendingtrades.steps.TradeStepView;
import bisq.desktop.util.FormBuilder;
import bisq.desktop.util.Layout;

import bisq.core.locale.Res;
import bisq.core.payment.payload.F2FAccountPayload;

public class SellerStep2View extends TradeStepView {

Expand All @@ -32,6 +36,19 @@ public SellerStep2View(PendingTradesViewModel model) {
super(model);
}

@Override
protected void addContent() {
addTradeInfoBlock();
addInfoBlock();
if (model.dataModel.getSellersPaymentAccountPayload() instanceof F2FAccountPayload) {
FormBuilder.addTitledGroupBg(gridPane, ++gridRow, 4,
Res.get("portfolio.pending.step2_seller.f2fInfo.headline"), Layout.GROUP_DISTANCE);
gridRow = F2FForm.addFormForBuyer(gridPane, --gridRow, model.dataModel.getSellersPaymentAccountPayload(),
model.dataModel.getTrade().getOffer(), Layout.FIRST_ROW_AND_GROUP_DISTANCE);
}
}


///////////////////////////////////////////////////////////////////////////////////////////
// Info
///////////////////////////////////////////////////////////////////////////////////////////
Expand All @@ -46,6 +63,7 @@ protected String getInfoText() {
return Res.get("portfolio.pending.step2_seller.waitPayment.msg", model.dataModel.getCurrencyCode());
}


///////////////////////////////////////////////////////////////////////////////////////////
// Warning
///////////////////////////////////////////////////////////////////////////////////////////
Expand All @@ -58,6 +76,7 @@ protected String getWarningText() {
model.getDateForOpenDispute());
}


///////////////////////////////////////////////////////////////////////////////////////////
// Dispute
///////////////////////////////////////////////////////////////////////////////////////////
Expand All @@ -70,7 +89,6 @@ protected String getOpenForDisputeText() {
@Override
protected void applyOnDisputeOpened() {
}

}


0 comments on commit a41c20c

Please sign in to comment.