diff --git a/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoiceModel.swift b/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoiceModel.swift index 6258e6fe2..8410ae943 100644 --- a/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoiceModel.swift +++ b/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoiceModel.swift @@ -1,7 +1,6 @@ import UIKit public struct UpsaleVisibilityChoiceModel: Hashable { -// let category: UpsaleVisibilityResponse.Category? let title: String let description: String? let specificationUrn: String? @@ -17,14 +16,4 @@ public struct UpsaleVisibilityChoiceModel: Hashable { self.specificationUrn = specificationUrn self.icon = icon } - -// init() { -// self.init( -// category: response.category, -// title: response.heading, -// price: response.price?.actual, -// description: response.description, -// specificationUrn: response.specificationUrn -// ) -// } } diff --git a/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoicesView.swift b/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoicesView.swift index a0d02dd57..b0a1bc5c6 100644 --- a/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoicesView.swift +++ b/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityChoicesView.swift @@ -70,7 +70,6 @@ struct ExtraVisibilityProductView: View { title: "adIn.userAdManagement.upsale.extra.title", buttonTitle: "adIn.userAdManagement.upsale.extra.button.title", productModels: [UpsaleVisibilityChoiceModel( -// category: .bump, title: "Anbefalte annonser", price: "119 kr", description: "Økt synlighet blant lignende annonser - 7 dager", diff --git a/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityModel.swift b/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityModel.swift index 8b155de9d..5c87b553f 100644 --- a/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityModel.swift +++ b/FinniversKit/Sources/SwiftUI Components/UpsaleVisibility/UpsaleVisibilityModel.swift @@ -5,15 +5,6 @@ public struct SelectedProductsModel: Hashable { let innerProducts: [UpsaleVisibilityModel]? let product: UpsaleVisibilityModel? -// init(response: UpsaleVisibilityResponse.SelectedProduct) { -// if let selectedProducts = response.selectedProducts { -// self.name = response.name -// self.innerProducts = selectedProducts.map { UpsaleVisibilityModel(response: $0) } -// } else { -// self.product = UpsaleVisibilityModel(response: response) -// } -// } - public init(name: String?, innerProducts: [UpsaleVisibilityModel]?, product: UpsaleVisibilityModel?) { self.name = name self.product = product @@ -24,25 +15,12 @@ public struct SelectedProductsModel: Hashable { public struct UpsaleVisibilityModel: Hashable { let title: String let description: String? -// var category: UpsaleVisibilityResponse.Category? let durationRemaining: CGFloat? let icon: UIImage? -// init() { -// self.title = response.name -// // Backend srvice(s) require time to update these fields. -// // To mitigate this we try to present any of the received fields with `salesFrontDescription` having the highest priority. -// self.description = response.salesFrontDescription ?? -// response.formattedDurationRemaining ?? -// response.formattedStart -// self.category = response.category -// self.durationRemaining = CGFloat((response.percentageDurationRemaining ?? 100) / 100) -// } - public init(title: String, description: String?, durationRemaining: CGFloat?, icon: UIImage?) { self.title = title self.description = description -// self.category = category self.durationRemaining = durationRemaining self.icon = icon }