taler-ios

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

commit d872f3418bd93bd09669ebe7cefdc33dfcb1a7e1
parent a5ea18d209b38afc3e2d035bb1d3d62b3617ed3e
Author: Marc Stibane <marc@taler.net>
Date:   Mon,  5 Oct 2026 09:33:28 +0200

cleanup

Diffstat:
MTalerCommon/ViewModifier/View+dismissTop.swift | 3+++
MTalerWallet1/Controllers/TalerWallet1App.swift | 17+----------------
MTalerWallet1/Model/Model+Payment.swift | 10+++++-----
3 files changed, 9 insertions(+), 21 deletions(-)

diff --git a/TalerCommon/ViewModifier/View+dismissTop.swift b/TalerCommon/ViewModifier/View+dismissTop.swift @@ -16,6 +16,9 @@ // DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // +/** + * @author Marc Stibane + */ import SwiftUI /// This is just a workaround for a SwiftUI bug diff --git a/TalerWallet1/Controllers/TalerWallet1App.swift b/TalerWallet1/Controllers/TalerWallet1App.swift @@ -150,22 +150,7 @@ struct TalerWallet1App: App { } #if TALER_NIGHTLY .backgroundTask(.appRefresh("net.taler.refresh")) { -// symLog.log("backgroundTask running") -//#if 0 -// let request = URLRequest(url: URL(string: "your_backend")!) -// guard let data = try? await URLSession.shared.data(for: request).0 else { -// return -// } -// -// let decoder = JSONDecoder() -// guard let products = try? decoder.decode([Product].self, from: data) else { -// return -// } -// -// if !products.isEmpty && !Task.isCancelled { -// await notifyUser(for: products) -// } -//#endif + symLog.log("backgroundTask running") } #endif } else { diff --git a/TalerWallet1/Model/Model+Payment.swift b/TalerWallet1/Model/Model+Payment.swift @@ -517,14 +517,14 @@ enum TemplateType: String, Codable { struct TemplateContractDetails: Codable { let summary: String? // Human-readable short summary of the contract. Editable if nil let currency: String? // specify currency when amount is nil - unspecified if nil - let amount: Amount? // Total amount payable. Fixed if this field exists, editable if nil - let scopeInfo: ScopeInfo? - let minimumAge: Int? let payDuration: Duration? let maxPickupDuration: Duration? + let minimumAge: Int? let requestTip: Bool? let templateType: TemplateType? + let amount: Amount? // Total amount payable. Fixed if this field exists, editable if nil + let scopeInfo: ScopeInfo? // unfortunately this DOESN'T exist - but it should let websiteRegex: String? let choices: [OrderChoice]? @@ -613,11 +613,11 @@ struct TemplateContractDetailsDefaults: Codable { struct TalerMerchantTemplateDetails: Codable { let templateContract: TemplateContractDetails let editableDefaults: TemplateContractDetailsDefaults? -// let requiredCurrency: String? + let requiredCurrency: String? enum CodingKeys: String, CodingKey { case templateContract = "template_contract" case editableDefaults = "editable_defaults" -// case requiredCurrency = "required_currency" + case requiredCurrency = "required_currency" } }