taler-ios

iOS apps for GNU Taler (wallet)
Log | Files | Refs | README | LICENSE

commit 5ed30b8bc5ce953b891769c17be36496766d7fad
parent bab4ef3ca5d526e9b0b30250a0a984adc1e1191f
Author: Marc Stibane <marc@taler.net>
Date:   Sun,  7 Jan 2024 15:06:06 +0100

AccountRestriction

Diffstat:
MTalerWallet1/Model/Model+Withdraw.swift | 13++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/TalerWallet1/Model/Model+Withdraw.swift b/TalerWallet1/Model/Model+Withdraw.swift @@ -7,16 +7,23 @@ import taler_swift import SymLog fileprivate let ASYNCDELAY: UInt = 0 //set e.g to 6 or 9 seconds for debugging -enum AccountRestrictionType: String, Decodable { +enum AccountRestrictionType: String, Codable { case deny case regex } -struct AccountRestriction: Decodable { + +typealias HintDict = [String:String] + +struct AccountRestriction: Codable, Hashable { var type: AccountRestrictionType var payto_regex: String? var human_hint: String? - var human_hint_i18n: [String:String]? + var human_hint_i18n: HintDict? } +extension AccountRestriction: Identifiable { + var id: AccountRestriction {self} +} + struct WithdrawalExchangeAccountDetails: Decodable { var status: String var bankName: String?