gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-taler-android] branch master updated (d6c5237 -> ad029fc)


From: gnunet
Subject: [taler-taler-android] branch master updated (d6c5237 -> ad029fc)
Date: Tue, 20 Feb 2024 18:08:59 +0100

This is an automated email from the git hooks/post-receive script.

torsten-grote pushed a change to branch master
in repository taler-android.

    from d6c5237  [cashier] Upgrade to newer bank APIs and better response 
handling
     new a2feeb8  [wallet] withdrawal: don't let users select an exchange if 
there's only one
     new 33b7449  [wallet] Fix failing test
     new ad029fc  [cashier] release v0.3

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 cashier/build.gradle                                        |  4 ++--
 .../net/taler/wallet/withdraw/PromptWithdrawFragment.kt     | 13 +++++++++++--
 .../java/net/taler/wallet/backend/WalletResponseTest.kt     |  5 +++++
 3 files changed, 18 insertions(+), 4 deletions(-)

diff --git a/cashier/build.gradle b/cashier/build.gradle
index 2e5db5f..074124f 100644
--- a/cashier/build.gradle
+++ b/cashier/build.gradle
@@ -29,8 +29,8 @@ android {
         applicationId "net.taler.cashier"
         minSdkVersion 23
         targetSdkVersion 33
-        versionCode 2
-        versionName "0.2"
+        versionCode 3
+        versionName "0.3"
         testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
 
         buildConfigField("String", "BACKEND_API_VERSION", "\"4:0:0\"")
diff --git 
a/wallet/src/main/java/net/taler/wallet/withdraw/PromptWithdrawFragment.kt 
b/wallet/src/main/java/net/taler/wallet/withdraw/PromptWithdrawFragment.kt
index 16b956b..56f56f7 100644
--- a/wallet/src/main/java/net/taler/wallet/withdraw/PromptWithdrawFragment.kt
+++ b/wallet/src/main/java/net/taler/wallet/withdraw/PromptWithdrawFragment.kt
@@ -115,7 +115,13 @@ class PromptWithdrawFragment : Fragment() {
         if (s.showImmediately.getIfNotConsumed() == true) {
             
findNavController().navigate(R.id.action_promptWithdraw_to_reviewExchangeTOS)
         } else {
-            showContent(s.amountRaw, s.amountEffective, s.exchangeBaseUrl, 
s.talerWithdrawUri)
+            showContent(
+                amountRaw = s.amountRaw,
+                amountEffective = s.amountEffective,
+                exchange = s.exchangeBaseUrl,
+                uri = s.talerWithdrawUri,
+                exchanges = s.possibleExchanges,
+            )
             ui.confirmWithdrawButton.apply {
                 text = getString(R.string.withdraw_button_tos)
                 setOnClickListener {
@@ -133,6 +139,7 @@ class PromptWithdrawFragment : Fragment() {
             exchange = s.exchangeBaseUrl,
             uri = s.talerWithdrawUri,
             ageRestrictionOptions = s.ageRestrictionOptions,
+            exchanges = s.possibleExchanges,
         )
         ui.confirmWithdrawButton.apply {
             text = getString(R.string.withdraw_button_confirm)
@@ -154,6 +161,7 @@ class PromptWithdrawFragment : Fragment() {
         amountEffective: Amount,
         exchange: String,
         uri: String?,
+        exchanges: List<ExchangeItem> = emptyList(),
         ageRestrictionOptions: List<Int>? = null,
     ) {
         model.showProgressBar.value = false
@@ -178,7 +186,8 @@ class PromptWithdrawFragment : Fragment() {
         ui.withdrawExchangeUrl.text = cleanExchange(exchange)
         ui.withdrawExchangeUrl.fadeIn()
 
-        if (uri != null) {  // no Uri for manual withdrawals
+        // no Uri for manual withdrawals, no selection for single exchange
+        if (uri != null && exchanges.size > 1) {
             ui.selectExchangeButton.fadeIn()
             ui.selectExchangeButton.setOnClickListener {
                 selectExchange()
diff --git 
a/wallet/src/test/java/net/taler/wallet/backend/WalletResponseTest.kt 
b/wallet/src/test/java/net/taler/wallet/backend/WalletResponseTest.kt
index e2389d8..5d3a80b 100644
--- a/wallet/src/test/java/net/taler/wallet/backend/WalletResponseTest.kt
+++ b/wallet/src/test/java/net/taler/wallet/backend/WalletResponseTest.kt
@@ -39,6 +39,11 @@ class WalletResponseTest {
               "result": {
                 "balances": [
                   {
+                    "scopeInfo": {
+                      "currency": "TESTKUDOS",
+                      "type": "exchange",
+                      "url": "https://exchange.test.taler.net/";
+                    },
                     "available": "TESTKUDOS:15.8",
                     "pendingIncoming": "TESTKUDOS:0",
                     "pendingOutgoing": "TESTKUDOS:0",

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]