Manos Chorianopoulos

added ActiveBoxCouponModel and support functions

......@@ -14,6 +14,7 @@ public struct GlobalVariables {
static var customerState: swiftApi.CustomerStateModel?
static var userTag: String = ""
static var dfyCoupons: Array<swiftApi.ActiveDFYCouponModel> = []
static var boxCoupons: Array<swiftApi.ActiveBoxCouponModel> = []
static var couponList: Array<swiftApi.CouponItemModel> = []
static var oldCouponList: Array<swiftApi.CouponItemModel> = []
static var smOldCouponList: Array<swiftApi.CouponItemModel> = []
......@@ -28,6 +29,7 @@ public struct GlobalVariables {
static var consumerInternal: swiftApi.ProfileModel?
static var ccmsCampaigns: Array<swiftApi.LoyaltyContextualOfferModel> = []
static var dealsSum: Float = 0.0
static var boxSum: Float = 0.0
static var seasonalList: Array<swiftApi.LoyaltyGiftsForYouPackage> = []
static var savedSteps: Int = 0
static var stepsWebview: Int = 0
......@@ -8628,4 +8630,49 @@ public class swiftApi {
}
public class ActiveBoxCouponModel {
private var value: String
private var code: String
public init() {
self.value = ""
self.code = ""
}
public var _value: String {
get { // getter
return self.value
}
set(newValue) { //setter
self.value = newValue
}
}
public var _code: String {
get { // getter
return self.code
}
set(newValue) { //setter
self.code = newValue
}
}
}
public func setActiveBoxCoupons(boxCoupons: Array<ActiveBoxCouponModel>) {
GlobalVariables.boxCoupons = boxCoupons
}
public func getActiveBoxCoupons() -> Array<ActiveBoxCouponModel> {
return GlobalVariables.boxCoupons
}
public func setBoxCouponsSum(_ sum: Float) {
GlobalVariables.boxSum = sum
}
public func getBoxCouponsSum() -> Float {
return GlobalVariables.boxSum
}
}
......