mirror of
https://github.com/haveno-dex/haveno.git
synced 2024-12-22 03:29:28 +00:00
show locked symbol for private offers in trade history
This commit is contained in:
parent
c75e3aa455
commit
544d69827a
3 changed files with 2 additions and 6 deletions
|
@ -105,7 +105,7 @@ public class ClosedTradesListItem implements FilterableListItem {
|
|||
? offer.getDirection()
|
||||
: offer.getMirroredDirection();
|
||||
String currencyCode = tradable.getOffer().getCurrencyCode();
|
||||
return DisplayUtils.getDirectionWithCode(direction, currencyCode);
|
||||
return DisplayUtils.getDirectionWithCode(direction, currencyCode, offer.isPrivateOffer());
|
||||
}
|
||||
|
||||
public Date getDate() {
|
||||
|
|
|
@ -68,7 +68,7 @@ class FailedTradesViewModel extends ActivatableWithDataModel<FailedTradesDataMod
|
|||
}
|
||||
|
||||
String getDirectionLabel(FailedTradesListItem item) {
|
||||
return (item != null) ? DisplayUtils.getDirectionWithCode(dataModel.getDirection(item.getTrade().getOffer()), item.getTrade().getOffer().getCurrencyCode()) : "";
|
||||
return (item != null) ? DisplayUtils.getDirectionWithCode(dataModel.getDirection(item.getTrade().getOffer()), item.getTrade().getOffer().getCurrencyCode(), item.getTrade().getOffer().isPrivateOffer()) : "";
|
||||
}
|
||||
|
||||
String getMarketLabel(FailedTradesListItem item) {
|
||||
|
|
|
@ -116,10 +116,6 @@ public class DisplayUtils {
|
|||
// Offer direction
|
||||
///////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
public static String getDirectionWithCode(OfferDirection direction, String currencyCode) {
|
||||
return getDirectionWithCode(direction, currencyCode, false);
|
||||
}
|
||||
|
||||
public static String getDirectionWithCode(OfferDirection direction, String currencyCode, boolean isPrivate) {
|
||||
if (CurrencyUtil.isTraditionalCurrency(currencyCode))
|
||||
return (direction == OfferDirection.BUY) ? Res.get(isPrivate ? "shared.buyCurrencyLocked" : "shared.buyCurrency", Res.getBaseCurrencyCode()) : Res.get(isPrivate ? "shared.sellCurrencyLocked" : "shared.sellCurrency", Res.getBaseCurrencyCode());
|
||||
|
|
Loading…
Reference in a new issue