From 04f46449ebd9176a5d6c390befb11599fa032f5f Mon Sep 17 00:00:00 2001 From: Damyan Ivanov Date: Wed, 23 Dec 2020 20:53:01 +0000 Subject: [PATCH] hew transaction entry: honour default currency setting --- .../mobileledger/ui/activity/NewTransactionItemHolder.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/src/main/java/net/ktnx/mobileledger/ui/activity/NewTransactionItemHolder.java b/app/src/main/java/net/ktnx/mobileledger/ui/activity/NewTransactionItemHolder.java index 62f0de49..5596d574 100644 --- a/app/src/main/java/net/ktnx/mobileledger/ui/activity/NewTransactionItemHolder.java +++ b/app/src/main/java/net/ktnx/mobileledger/ui/activity/NewTransactionItemHolder.java @@ -378,6 +378,9 @@ class NewTransactionItemHolder extends RecyclerView.ViewHolder showCurrencyObserver = showCurrency -> { if (showCurrency) { tvCurrency.setVisibility(View.VISIBLE); + String defaultCommodity = mProfile.getDefaultCommodity(); + item.setCurrency( + (defaultCommodity == null) ? null : Currency.loadByName(defaultCommodity)); } else { tvCurrency.setVisibility(View.GONE); -- 2.39.5