Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion product/pay/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ dependencies {
// implementation("com.github.reown-com:yttrium-wcpay:unspecified")

//jitpack
implementation("com.github.reown-com.yttrium:yttrium-wcpay:0.10.34") {
implementation("com.github.reown-com.yttrium:yttrium-wcpay:0.10.41") {
exclude(group = "net.java.dev.jna", module = "jna")
}
implementation("net.java.dev.jna:jna:5.17.0@aar")
Expand Down
3 changes: 2 additions & 1 deletion product/pay/src/main/java/com/walletconnect/pay/Mappers.kt
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ internal object Mappers {
id = option.id,
amount = mapAmount(option.amount),
estimatedTxs = option.etaS.coerceAtMost(Int.MAX_VALUE.toULong().toLong()).toInt(),
account = option.account
account = option.account,
collectData = option.collectData?.let { mapCollectDataAction(it) }
)
}

Expand Down
3 changes: 2 additions & 1 deletion product/pay/src/main/java/com/walletconnect/pay/Pay.kt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ object Pay {
val id: String,
val amount: Amount,
val account: String,
val estimatedTxs: Int?
val estimatedTxs: Int?,
val collectData: CollectDataAction? = null
)

data class MerchantInfo(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ internal fun Pay.PaymentOption.toWallet(): Wallet.Model.PaymentOption =
id = id,
amount = amount.toWallet(),
account = account,
estimatedTxs = estimatedTxs
estimatedTxs = estimatedTxs,
collectData = collectData?.toWallet()
)

@JvmSynthetic
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,8 @@ object Wallet {
val id: String,
val amount: PaymentAmount,
val account: String,
val estimatedTxs: Int?
val estimatedTxs: Int?,
val collectData: CollectDataAction? = null
) : Model()

enum class CollectDataFieldType {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,9 @@ class WalletKitActivity : AppCompatActivity() {
.onEach { paymentLink ->
navigateWhenReady {
val encodedLink = URLEncoder.encode(paymentLink, "UTF-8")
navController.navigate("${Route.Payment.path}/$encodedLink")
navController.navigate("${Route.Payment.path}/$encodedLink") {
launchSingleTop = true
}
}
}
.launchIn(lifecycleScope)
Expand All @@ -209,7 +211,9 @@ class WalletKitActivity : AppCompatActivity() {
lifecycleScope.launch {
navigateWhenReady {
val encodedLink = URLEncoder.encode(dataString, "UTF-8")
navController.navigate("${Route.Payment.path}/$encodedLink")
navController.navigate("${Route.Payment.path}/$encodedLink") {
launchSingleTop = true
}
}
}
return
Expand Down
Loading
Loading