Showing
11 changed files
with
222 additions
and
58 deletions
No preview for this file type
... | @@ -695,10 +695,11 @@ var timer2: DispatchSourceTimer? | ... | @@ -695,10 +695,11 @@ var timer2: DispatchSourceTimer? |
695 | } else if (eventArray[1] == "loyaltyWallet") { | 695 | } else if (eventArray[1] == "loyaltyWallet") { |
696 | // event:loyaltyWallet | 696 | // event:loyaltyWallet |
697 | SwiftEventBus.post("refresh_vouchers") | 697 | SwiftEventBus.post("refresh_vouchers") |
698 | + SwiftEventBus.post("open_my_rewards") | ||
698 | 699 | ||
699 | - let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self)) | 700 | + // let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self)) |
700 | - let vc = storyboard.instantiateViewController(withIdentifier: "WalletViewController") as! SwiftWarplyFramework.WalletViewController | 701 | + // let vc = storyboard.instantiateViewController(withIdentifier: "WalletViewController") as! SwiftWarplyFramework.WalletViewController |
701 | - self.navigationController?.pushViewController(vc, animated: true) | 702 | + // self.navigationController?.pushViewController(vc, animated: true) |
702 | 703 | ||
703 | } else if (eventArray[1] == "cancel_unified_success") { | 704 | } else if (eventArray[1] == "cancel_unified_success") { |
704 | // event:cancel_unified_success | 705 | // event:cancel_unified_success | ... | ... |
... | @@ -26,7 +26,8 @@ import SwiftEventBus | ... | @@ -26,7 +26,8 @@ import SwiftEventBus |
26 | getCouponsRequest() | 26 | getCouponsRequest() |
27 | 27 | ||
28 | setBackButton() | 28 | setBackButton() |
29 | - setNavigationTitle("GIFTS FOR YOU") | 29 | +// setNavigationTitle("GIFTS FOR YOU") |
30 | + setNavigationTitle("FREE COUPONS") | ||
30 | 31 | ||
31 | // backgroundImage.image = UIImage(named: "coupons_scrollview_dark", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | 32 | // backgroundImage.image = UIImage(named: "coupons_scrollview_dark", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) |
32 | 33 | ... | ... |
... | @@ -74,7 +74,8 @@ import SwiftEventBus | ... | @@ -74,7 +74,8 @@ import SwiftEventBus |
74 | } | 74 | } |
75 | } | 75 | } |
76 | 76 | ||
77 | - setBackButton() | 77 | +// setBackButton() |
78 | + setBackButton("ic_close_3") | ||
78 | setNavigationTitle("Ιστορικό") | 79 | setNavigationTitle("Ιστορικό") |
79 | 80 | ||
80 | // === images === // | 81 | // === images === // |
... | @@ -95,7 +96,7 @@ import SwiftEventBus | ... | @@ -95,7 +96,7 @@ import SwiftEventBus |
95 | historySectionView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 96 | historySectionView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
96 | historySectionView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 97 | historySectionView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
97 | historySectionView.layer.shadowOpacity = 1.0 | 98 | historySectionView.layer.shadowOpacity = 1.0 |
98 | - historySectionView.layer.shadowRadius = 1.0 | 99 | + historySectionView.layer.shadowRadius = 2.0 |
99 | 100 | ||
100 | } | 101 | } |
101 | 102 | ||
... | @@ -205,7 +206,8 @@ import SwiftEventBus | ... | @@ -205,7 +206,8 @@ import SwiftEventBus |
205 | 206 | ||
206 | dfyBannerParentView.backgroundColor = .clear | 207 | dfyBannerParentView.backgroundColor = .clear |
207 | dfyBannerInnerParentView.backgroundColor = .white | 208 | dfyBannerInnerParentView.backgroundColor = .white |
208 | - dfyBannerInnerView.backgroundColor = UIColor(red: 0.46, green: 0.75, blue: 0.45, alpha: 0.05) | 209 | +// dfyBannerInnerView.backgroundColor = UIColor(red: 0.46, green: 0.75, blue: 0.45, alpha: 0.05) |
210 | + dfyBannerInnerView.backgroundColor = .white | ||
209 | dfyBannerInnerParentView.layer.cornerRadius = 16.0 | 211 | dfyBannerInnerParentView.layer.cornerRadius = 16.0 |
210 | dfyBannerInnerView.layer.cornerRadius = 16.0 | 212 | dfyBannerInnerView.layer.cornerRadius = 16.0 |
211 | // dfyBannerInnerView.layer.borderWidth = 1 | 213 | // dfyBannerInnerView.layer.borderWidth = 1 |
... | @@ -214,7 +216,7 @@ import SwiftEventBus | ... | @@ -214,7 +216,7 @@ import SwiftEventBus |
214 | dfyBannerParentView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 216 | dfyBannerParentView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
215 | dfyBannerParentView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 217 | dfyBannerParentView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
216 | dfyBannerParentView.layer.shadowOpacity = 1.0 | 218 | dfyBannerParentView.layer.shadowOpacity = 1.0 |
217 | - dfyBannerParentView.layer.shadowRadius = 1.0 | 219 | + dfyBannerParentView.layer.shadowRadius = 2.0 |
218 | 220 | ||
219 | let totalCouponValueFixed = Float(round(100 * totalCouponValue) / 100) | 221 | let totalCouponValueFixed = Float(round(100 * totalCouponValue) / 100) |
220 | var totalCouponValueString = "0" | 222 | var totalCouponValueString = "0" |
... | @@ -236,7 +238,8 @@ import SwiftEventBus | ... | @@ -236,7 +238,8 @@ import SwiftEventBus |
236 | // === MARKET banner === // | 238 | // === MARKET banner === // |
237 | 239 | ||
238 | marketBannerParentView.backgroundColor = .clear | 240 | marketBannerParentView.backgroundColor = .clear |
239 | - marketBannerInnerView.backgroundColor = UIColor(red: 1.00, green: 0.99, blue: 0.97, alpha: 1.00) | 241 | +// marketBannerInnerView.backgroundColor = UIColor(red: 1.00, green: 0.99, blue: 0.97, alpha: 1.00) |
242 | + marketBannerInnerView.backgroundColor = .white | ||
240 | marketBannerInnerView.layer.cornerRadius = 16.0 | 243 | marketBannerInnerView.layer.cornerRadius = 16.0 |
241 | // marketBannerInnerView.layer.borderWidth = 1 | 244 | // marketBannerInnerView.layer.borderWidth = 1 |
242 | // marketBannerInnerView.layer.borderColor = UIColor(red: 0.90, green: 0.90, blue: 0.90, alpha: 1.00).cgColor | 245 | // marketBannerInnerView.layer.borderColor = UIColor(red: 0.90, green: 0.90, blue: 0.90, alpha: 1.00).cgColor |
... | @@ -244,7 +247,7 @@ import SwiftEventBus | ... | @@ -244,7 +247,7 @@ import SwiftEventBus |
244 | marketBannerParentView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 247 | marketBannerParentView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
245 | marketBannerParentView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 248 | marketBannerParentView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
246 | marketBannerParentView.layer.shadowOpacity = 1.0 | 249 | marketBannerParentView.layer.shadowOpacity = 1.0 |
247 | - marketBannerParentView.layer.shadowRadius = 1.0 | 250 | + marketBannerParentView.layer.shadowRadius = 2.0 |
248 | 251 | ||
249 | let marketDiscount = Float(round(100 * unifiedCouponsDiscount) / 100) | 252 | let marketDiscount = Float(round(100 * unifiedCouponsDiscount) / 100) |
250 | var marketDiscountString = "0" | 253 | var marketDiscountString = "0" |
... | @@ -267,7 +270,8 @@ import SwiftEventBus | ... | @@ -267,7 +270,8 @@ import SwiftEventBus |
267 | // === GFY banner === // | 270 | // === GFY banner === // |
268 | 271 | ||
269 | gfyBannerParentView.backgroundColor = .clear | 272 | gfyBannerParentView.backgroundColor = .clear |
270 | - gfyBannerInnerView.backgroundColor = UIColor(red: 0.96, green: 0.97, blue: 0.98, alpha: 1.00) | 273 | +// gfyBannerInnerView.backgroundColor = UIColor(red: 0.96, green: 0.97, blue: 0.98, alpha: 1.00) |
274 | + gfyBannerInnerView.backgroundColor = .white | ||
271 | gfyBannerInnerView.layer.cornerRadius = 16.0 | 275 | gfyBannerInnerView.layer.cornerRadius = 16.0 |
272 | // gfyBannerInnerView.layer.borderWidth = 1 | 276 | // gfyBannerInnerView.layer.borderWidth = 1 |
273 | // gfyBannerInnerView.layer.borderColor = UIColor(red: 0.90, green: 0.90, blue: 0.90, alpha: 1.00).cgColor | 277 | // gfyBannerInnerView.layer.borderColor = UIColor(red: 0.90, green: 0.90, blue: 0.90, alpha: 1.00).cgColor |
... | @@ -275,7 +279,7 @@ import SwiftEventBus | ... | @@ -275,7 +279,7 @@ import SwiftEventBus |
275 | gfyBannerParentView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 279 | gfyBannerParentView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
276 | gfyBannerParentView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 280 | gfyBannerParentView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
277 | gfyBannerParentView.layer.shadowOpacity = 1.0 | 281 | gfyBannerParentView.layer.shadowOpacity = 1.0 |
278 | - gfyBannerParentView.layer.shadowRadius = 1.0 | 282 | + gfyBannerParentView.layer.shadowRadius = 2.0 |
279 | 283 | ||
280 | var totalCouponDiscountString = "0" | 284 | var totalCouponDiscountString = "0" |
281 | totalCouponDiscountString = String(format: "%.2f", totalCouponDiscount).replacingOccurrences(of: ".", with: ",", options: .literal, range: nil) | 285 | totalCouponDiscountString = String(format: "%.2f", totalCouponDiscount).replacingOccurrences(of: ".", with: ",", options: .literal, range: nil) |
... | @@ -283,7 +287,8 @@ import SwiftEventBus | ... | @@ -283,7 +287,8 @@ import SwiftEventBus |
283 | 287 | ||
284 | let gfyNormalText1 = "Μέχρι τώρα έχεις όφελος " | 288 | let gfyNormalText1 = "Μέχρι τώρα έχεις όφελος " |
285 | let gfyBoldText = totalCouponDiscountString + "€" | 289 | let gfyBoldText = totalCouponDiscountString + "€" |
286 | - let gfyNormalText2 = " από τα GIFTS FOR YOU" | 290 | + let gfyNormalText2 = " από τα FREE COUPONS" |
291 | +// let gfyNormalText2 = " από τα GIFTS FOR YOU" | ||
287 | 292 | ||
288 | let gfyAttributedString = NSMutableAttributedString(string:gfyNormalText1, attributes:attrRegular) | 293 | let gfyAttributedString = NSMutableAttributedString(string:gfyNormalText1, attributes:attrRegular) |
289 | let gfyBoldString = NSMutableAttributedString(string: gfyBoldText, attributes:attrBold) | 294 | let gfyBoldString = NSMutableAttributedString(string: gfyBoldText, attributes:attrBold) | ... | ... |
This diff could not be displayed because it is too large.
... | @@ -33,14 +33,16 @@ import UIKit | ... | @@ -33,14 +33,16 @@ import UIKit |
33 | // Initialization code | 33 | // Initialization code |
34 | 34 | ||
35 | // DFY Banner | 35 | // DFY Banner |
36 | - dfyViewParent.backgroundColor = UIColor(red: 0.95, green: 0.95, blue: 0.95, alpha: 1.00) | 36 | +// dfyViewParent.backgroundColor = UIColor(red: 0.95, green: 0.95, blue: 0.95, alpha: 1.00) |
37 | + dfyViewParent.backgroundColor = .white | ||
37 | dfyViewParent.layer.cornerRadius = 16.0 | 38 | dfyViewParent.layer.cornerRadius = 16.0 |
38 | dfyViewParent.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 39 | dfyViewParent.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
39 | dfyViewParent.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 40 | dfyViewParent.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
40 | dfyViewParent.layer.shadowOpacity = 1.0 | 41 | dfyViewParent.layer.shadowOpacity = 1.0 |
41 | - dfyViewParent.layer.shadowRadius = 1.0 | 42 | + dfyViewParent.layer.shadowRadius = 2.0 |
42 | 43 | ||
43 | - dfyView.backgroundColor = UIColor(red: 0.46, green: 0.75, blue: 0.45, alpha: 0.05) | 44 | +// dfyView.backgroundColor = UIColor(red: 0.46, green: 0.75, blue: 0.45, alpha: 0.05) |
45 | + dfyView.backgroundColor = .white | ||
44 | dfyView.layer.cornerRadius = 16.0 | 46 | dfyView.layer.cornerRadius = 16.0 |
45 | 47 | ||
46 | dfyImage.image = UIImage(named: "wallet_banner_dfy", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | 48 | dfyImage.image = UIImage(named: "wallet_banner_dfy", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) |
... | @@ -51,12 +53,13 @@ import UIKit | ... | @@ -51,12 +53,13 @@ import UIKit |
51 | dfyCountView.backgroundColor = UIColor(red: 0.92, green: 0.75, blue: 0.41, alpha: 1.00) | 53 | dfyCountView.backgroundColor = UIColor(red: 0.92, green: 0.75, blue: 0.41, alpha: 1.00) |
52 | 54 | ||
53 | // SM Banner | 55 | // SM Banner |
54 | - smView.backgroundColor = UIColor(red: 1.00, green: 0.99, blue: 0.97, alpha: 1.00) | 56 | +// smView.backgroundColor = UIColor(red: 1.00, green: 0.99, blue: 0.97, alpha: 1.00) |
57 | + smView.backgroundColor = .white | ||
55 | smView.layer.cornerRadius = 16.0 | 58 | smView.layer.cornerRadius = 16.0 |
56 | smView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 59 | smView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
57 | smView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 60 | smView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
58 | smView.layer.shadowOpacity = 1.0 | 61 | smView.layer.shadowOpacity = 1.0 |
59 | - smView.layer.shadowRadius = 1.0 | 62 | + smView.layer.shadowRadius = 2.0 |
60 | 63 | ||
61 | smImage.image = UIImage(named: "wallet_banner_sm", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | 64 | smImage.image = UIImage(named: "wallet_banner_sm", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) |
62 | 65 | ||
... | @@ -66,16 +69,19 @@ import UIKit | ... | @@ -66,16 +69,19 @@ import UIKit |
66 | smCountView.backgroundColor = UIColor(red: 0.92, green: 0.75, blue: 0.41, alpha: 1.00) | 69 | smCountView.backgroundColor = UIColor(red: 0.92, green: 0.75, blue: 0.41, alpha: 1.00) |
67 | 70 | ||
68 | // GFY Banner | 71 | // GFY Banner |
69 | - gfyView.backgroundColor = UIColor(red: 0.96, green: 0.97, blue: 0.98, alpha: 1.00) | 72 | +// gfyView.backgroundColor = UIColor(red: 0.96, green: 0.97, blue: 0.98, alpha: 1.00) |
73 | + gfyView.backgroundColor = .white | ||
70 | gfyView.layer.cornerRadius = 16.0 | 74 | gfyView.layer.cornerRadius = 16.0 |
71 | gfyView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | 75 | gfyView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor |
72 | gfyView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | 76 | gfyView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) |
73 | gfyView.layer.shadowOpacity = 1.0 | 77 | gfyView.layer.shadowOpacity = 1.0 |
74 | - gfyView.layer.shadowRadius = 1.0 | 78 | + gfyView.layer.shadowRadius = 2.0 |
75 | 79 | ||
76 | gfyImage.image = UIImage(named: "wallet_banner_gfy", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | 80 | gfyImage.image = UIImage(named: "wallet_banner_gfy", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) |
77 | 81 | ||
78 | - gfyLabel.text = "GIFTS FOR YOU" | 82 | +// gfyLabel.text = "GIFTS FOR YOU" |
83 | +// gfyLabel.text = "Free coupons" | ||
84 | + gfyLabel.text = "FREE COUPONS" | ||
79 | 85 | ||
80 | gfyCountView.layer.cornerRadius = 4.0 | 86 | gfyCountView.layer.cornerRadius = 4.0 |
81 | gfyCountView.backgroundColor = UIColor(red: 0.92, green: 0.75, blue: 0.41, alpha: 1.00) | 87 | gfyCountView.backgroundColor = UIColor(red: 0.92, green: 0.75, blue: 0.41, alpha: 1.00) | ... | ... |
... | @@ -8,10 +8,17 @@ | ... | @@ -8,10 +8,17 @@ |
8 | import UIKit | 8 | import UIKit |
9 | 9 | ||
10 | @objc public class WalletEmptyViewTableViewCell: UITableViewCell { | 10 | @objc public class WalletEmptyViewTableViewCell: UITableViewCell { |
11 | - | 11 | + @IBOutlet weak var emptyImage: UIImageView! |
12 | + @IBOutlet weak var emptyLabel: UILabel! | ||
13 | + | ||
12 | public override func awakeFromNib() { | 14 | public override func awakeFromNib() { |
13 | super.awakeFromNib() | 15 | super.awakeFromNib() |
14 | // Initialization code | 16 | // Initialization code |
17 | + | ||
18 | + emptyImage.image = UIImage(named: "ic_empty_wallet_3", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | ||
19 | +// emptyLabel.text = "Δεν έχεις κάποιον ενεργό κωδικό ή κουπόνι! Μπες τώρα στην ενότητα COSMOTE For You και βρες αποκλειστικές προσφορές!" | ||
20 | + emptyLabel.text = "Δεν έχεις ενεργό κωδικό ή κουπόνι!\nΜπες τώρα στην ενότητα COSMOTE For You και βρες αποκλειστικές προσφορές" | ||
21 | + | ||
15 | } | 22 | } |
16 | 23 | ||
17 | public override func setSelected(_ selected: Bool, animated: Bool) { | 24 | public override func setSelected(_ selected: Bool, animated: Bool) { | ... | ... |
... | @@ -8,10 +8,31 @@ | ... | @@ -8,10 +8,31 @@ |
8 | import UIKit | 8 | import UIKit |
9 | 9 | ||
10 | @objc public class WalletHistoryBannerTableViewCell: UITableViewCell { | 10 | @objc public class WalletHistoryBannerTableViewCell: UITableViewCell { |
11 | - | 11 | + @IBOutlet weak var bannerView: UIView! |
12 | + @IBOutlet weak var bannerIconImage: UIImageView! | ||
13 | + @IBOutlet weak var bannerLabel: UILabel! | ||
14 | + @IBOutlet weak var bannerArrowImage: UIImageView! | ||
15 | + | ||
16 | + let language = swiftApi().getLanguage() | ||
17 | + | ||
12 | public override func awakeFromNib() { | 18 | public override func awakeFromNib() { |
13 | super.awakeFromNib() | 19 | super.awakeFromNib() |
14 | // Initialization code | 20 | // Initialization code |
21 | + | ||
22 | + bannerView.layer.cornerRadius = 16.0 | ||
23 | + bannerView.layer.borderWidth = 1 | ||
24 | + bannerView.layer.borderColor = UIColor(red: 0.90, green: 0.90, blue: 0.90, alpha: 1.00).cgColor | ||
25 | + | ||
26 | + // Add shadow | ||
27 | + bannerView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | ||
28 | + bannerView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | ||
29 | + bannerView.layer.shadowOpacity = 1.0 | ||
30 | + bannerView.layer.shadowRadius = 1.0 | ||
31 | + | ||
32 | + bannerIconImage.image = UIImage(named: "wallet_history_blue", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | ||
33 | + bannerArrowImage.image = UIImage(named: "arrow_right_black", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | ||
34 | + | ||
35 | + bannerLabel.text = "Δες το ιστορικό σου" | ||
15 | } | 36 | } |
16 | 37 | ||
17 | public override func setSelected(_ selected: Bool, animated: Bool) { | 38 | public override func setSelected(_ selected: Bool, animated: Bool) { |
... | @@ -19,5 +40,5 @@ import UIKit | ... | @@ -19,5 +40,5 @@ import UIKit |
19 | 40 | ||
20 | // Configure the view for the selected state | 41 | // Configure the view for the selected state |
21 | } | 42 | } |
22 | - | 43 | + |
23 | } | 44 | } | ... | ... |
... | @@ -8,10 +8,29 @@ | ... | @@ -8,10 +8,29 @@ |
8 | import UIKit | 8 | import UIKit |
9 | 9 | ||
10 | @objc public class WalletQuestionnaireBannerTableViewCell: UITableViewCell { | 10 | @objc public class WalletQuestionnaireBannerTableViewCell: UITableViewCell { |
11 | - | 11 | + @IBOutlet weak var bannerView: UIView! |
12 | + @IBOutlet weak var bannerIconImage: UIImageView! | ||
13 | + @IBOutlet weak var bannerIconImageWidth: NSLayoutConstraint! | ||
14 | + @IBOutlet weak var bannerLabel: UILabel! | ||
15 | + @IBOutlet weak var bannerLabelLeftSpace: NSLayoutConstraint! | ||
16 | + @IBOutlet weak var bannerArrowImage: UIImageView! | ||
17 | + | ||
12 | public override func awakeFromNib() { | 18 | public override func awakeFromNib() { |
13 | super.awakeFromNib() | 19 | super.awakeFromNib() |
14 | // Initialization code | 20 | // Initialization code |
21 | + | ||
22 | + bannerView.layer.cornerRadius = 16.0 | ||
23 | + bannerView.layer.borderWidth = 1 | ||
24 | + bannerView.layer.borderColor = UIColor(red: 0.90, green: 0.90, blue: 0.90, alpha: 1.00).cgColor | ||
25 | + | ||
26 | + // Add shadow | ||
27 | + bannerView.layer.shadowColor = UIColor(red: 0.00, green: 0.00, blue: 0.00, alpha: 0.2).cgColor | ||
28 | + bannerView.layer.shadowOffset = CGSize(width: 0.0, height: 1.0) | ||
29 | + bannerView.layer.shadowOpacity = 1.0 | ||
30 | + bannerView.layer.shadowRadius = 1.0 | ||
31 | + | ||
32 | + bannerIconImage.image = UIImage(named: "wallet_plus_blue", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | ||
33 | + bannerArrowImage.image = UIImage(named: "arrow_right_black", in: MyEmptyClass.resourceBundle(), compatibleWith: nil) | ||
15 | } | 34 | } |
16 | 35 | ||
17 | public override func setSelected(_ selected: Bool, animated: Bool) { | 36 | public override func setSelected(_ selected: Bool, animated: Bool) { |
... | @@ -19,5 +38,24 @@ import UIKit | ... | @@ -19,5 +38,24 @@ import UIKit |
19 | 38 | ||
20 | // Configure the view for the selected state | 39 | // Configure the view for the selected state |
21 | } | 40 | } |
22 | - | 41 | + |
42 | + func configureCell() { | ||
43 | + let userTag = swiftApi().getUserTag() | ||
44 | +// print("User tag: " + userTag) | ||
45 | + if (userTag != "" && userTag != "undefined") { | ||
46 | + bannerLabel.text = userTag | ||
47 | + bannerLabel.frame.size.width = bannerLabel.intrinsicContentSize.width | ||
48 | + bannerIconImage.isHidden = true | ||
49 | + bannerIconImageWidth.constant = CGFloat(0.0) | ||
50 | + bannerLabelLeftSpace.constant = CGFloat(0.0) | ||
51 | + | ||
52 | + } else { | ||
53 | + bannerLabel.text = "Πρόσθεσε τις προτιμήσεις σου" | ||
54 | + bannerLabel.frame.size.width = bannerLabel.intrinsicContentSize.width | ||
55 | + bannerIconImage.isHidden = false | ||
56 | + bannerIconImageWidth.constant = CGFloat(22.0) | ||
57 | + bannerLabelLeftSpace.constant = CGFloat(10.0) | ||
58 | + } | ||
59 | + } | ||
60 | + | ||
23 | } | 61 | } | ... | ... |
... | @@ -14,7 +14,8 @@ import UIKit | ... | @@ -14,7 +14,8 @@ import UIKit |
14 | super.awakeFromNib() | 14 | super.awakeFromNib() |
15 | // Initialization code | 15 | // Initialization code |
16 | 16 | ||
17 | - spinner.color = UIColor(red: 0.05, green: 0.65, blue: 0.00, alpha: 1.00) | 17 | +// spinner.color = UIColor(red: 0.05, green: 0.65, blue: 0.00, alpha: 1.00) |
18 | + spinner.color = UIColor(red: 0.00, green: 0.65, blue: 0.89, alpha: 1.00) | ||
18 | 19 | ||
19 | spinner.translatesAutoresizingMaskIntoConstraints = false | 20 | spinner.translatesAutoresizingMaskIntoConstraints = false |
20 | spinner.startAnimating() | 21 | spinner.startAnimating() | ... | ... |
... | @@ -80,6 +80,7 @@ import SwiftEventBus | ... | @@ -80,6 +80,7 @@ import SwiftEventBus |
80 | var forYouExpanded: Bool = false; | 80 | var forYouExpanded: Bool = false; |
81 | var showSpinner: Bool = false; | 81 | var showSpinner: Bool = false; |
82 | var showActiveCouponsBanners: Bool = false; | 82 | var showActiveCouponsBanners: Bool = false; |
83 | + var showEmptyView: Bool = false; | ||
83 | 84 | ||
84 | 85 | ||
85 | public override func viewDidLoad() { | 86 | public override func viewDidLoad() { |
... | @@ -105,8 +106,8 @@ import SwiftEventBus | ... | @@ -105,8 +106,8 @@ import SwiftEventBus |
105 | self.unifiedCoupons = swiftApi().getUnifiedCouponList() | 106 | self.unifiedCoupons = swiftApi().getUnifiedCouponList() |
106 | // TODO: Maybe add this | 107 | // TODO: Maybe add this |
107 | // TODO: Uncomment if discounts are shown again in wallet | 108 | // TODO: Uncomment if discounts are shown again in wallet |
108 | -// self.matchOldSMCoupons() | 109 | + self.matchOldSMCoupons() |
109 | -// self.updateMarketBadge() | 110 | + self.updateMarketBadge() |
110 | self.handleSpinnerAndEmptyView() | 111 | self.handleSpinnerAndEmptyView() |
111 | self.tableView.reloadData() | 112 | self.tableView.reloadData() |
112 | } | 113 | } |
... | @@ -161,8 +162,8 @@ import SwiftEventBus | ... | @@ -161,8 +162,8 @@ import SwiftEventBus |
161 | // TODO: Uncomment when UnifiedCoupons will be shown again | 162 | // TODO: Uncomment when UnifiedCoupons will be shown again |
162 | // getCouponsSetsDealsRequest() | 163 | // getCouponsSetsDealsRequest() |
163 | 164 | ||
164 | - setBackButton("ic_close_3") | 165 | +// setBackButton("ic_close_3") |
165 | - setNavigationTitle("My Rewards") | 166 | +// setNavigationTitle("My Rewards") |
166 | 167 | ||
167 | tableView.delegate = self | 168 | tableView.delegate = self |
168 | tableView.dataSource = self | 169 | tableView.dataSource = self |
... | @@ -494,8 +495,8 @@ import SwiftEventBus | ... | @@ -494,8 +495,8 @@ import SwiftEventBus |
494 | emptyLabel.text = "Δεν έχεις κάποιον ενεργό κωδικό ή κουπόνι! Μπες τώρα στην ενότητα COSMOTE For You και βρες αποκλειστικές προσφορές!" | 495 | emptyLabel.text = "Δεν έχεις κάποιον ενεργό κωδικό ή κουπόνι! Μπες τώρα στην ενότητα COSMOTE For You και βρες αποκλειστικές προσφορές!" |
495 | 496 | ||
496 | // TODO: Uncomment if discounts are shown again in wallet | 497 | // TODO: Uncomment if discounts are shown again in wallet |
497 | -// matchOldSMCoupons() | 498 | + matchOldSMCoupons() |
498 | -// updateMarketBadge() | 499 | + updateMarketBadge() |
499 | 500 | ||
500 | // TODO: DELETE if emptyView is needed again | 501 | // TODO: DELETE if emptyView is needed again |
501 | // emptyView.isHidden = true | 502 | // emptyView.isHidden = true |
... | @@ -558,10 +559,10 @@ import SwiftEventBus | ... | @@ -558,10 +559,10 @@ import SwiftEventBus |
558 | // TODO: Uncomment when UnifiedCoupons will be shown again | 559 | // TODO: Uncomment when UnifiedCoupons will be shown again |
559 | self.unifiedCoupons = swiftApi().getUnifiedCouponList() | 560 | self.unifiedCoupons = swiftApi().getUnifiedCouponList() |
560 | // TODO: Maybe add this | 561 | // TODO: Maybe add this |
561 | - // self.matchOldSMCoupons() | 562 | + self.matchOldSMCoupons() |
562 | // <=== | 563 | // <=== |
563 | // TODO: Uncomment if discounts are shown again in wallet | 564 | // TODO: Uncomment if discounts are shown again in wallet |
564 | -// self.updateMarketBadge() | 565 | + self.updateMarketBadge() |
565 | self.handleSpinnerAndEmptyView() | 566 | self.handleSpinnerAndEmptyView() |
566 | self.tableView.reloadData() | 567 | self.tableView.reloadData() |
567 | 568 | ||
... | @@ -582,19 +583,25 @@ import SwiftEventBus | ... | @@ -582,19 +583,25 @@ import SwiftEventBus |
582 | 583 | ||
583 | public override func viewDidLayoutSubviews() { | 584 | public override func viewDidLayoutSubviews() { |
584 | super.viewDidLayoutSubviews() | 585 | super.viewDidLayoutSubviews() |
585 | - | 586 | + |
586 | - if let headerView = tableView.tableHeaderView { | 587 | + // TODO: Uncomment if header is needed again |
587 | - | 588 | +// if let headerView = tableView.tableHeaderView { |
588 | - let height = headerView.systemLayoutSizeFitting(UIView.layoutFittingCompressedSize).height | 589 | +// |
589 | - var headerFrame = headerView.frame | 590 | +// let height = headerView.systemLayoutSizeFitting(UIView.layoutFittingCompressedSize).height |
590 | - | 591 | +// var headerFrame = headerView.frame |
591 | - //Comparison necessary to avoid infinite loop | 592 | +//// let height = 0.0 |
592 | - if height != headerFrame.size.height { | 593 | +//// var headerFrame = CGRect(x: 0,y: 0,width: 0,height: 0) |
593 | - headerFrame.size.height = height | 594 | +// |
594 | - headerView.frame = headerFrame | 595 | +// //Comparison necessary to avoid infinite loop |
595 | - tableView.tableHeaderView = headerView | 596 | +// if height != headerFrame.size.height { |
596 | - } | 597 | +// headerFrame.size.height = height |
597 | - } | 598 | +// headerView.frame = headerFrame |
599 | +// tableView.tableHeaderView = headerView | ||
600 | +// } | ||
601 | +// } | ||
602 | + | ||
603 | + // TODO: DELETE if header is needed again | ||
604 | + self.tableView.tableHeaderView = UIView(frame: CGRect(x: 0.0, y: 0.0, width: self.tableView.bounds.size.width, height: 0.01)) | ||
598 | } | 605 | } |
599 | 606 | ||
600 | // MARK: - Functions | 607 | // MARK: - Functions |
... | @@ -739,6 +746,7 @@ import SwiftEventBus | ... | @@ -739,6 +746,7 @@ import SwiftEventBus |
739 | if (swiftApi().getShowVouchersBanner() == "") { | 746 | if (swiftApi().getShowVouchersBanner() == "") { |
740 | self.emptyView.isHidden = true | 747 | self.emptyView.isHidden = true |
741 | self.emptyViewHeight.constant = 0 | 748 | self.emptyViewHeight.constant = 0 |
749 | + self.showEmptyView = false | ||
742 | 750 | ||
743 | self.showSpinner = true | 751 | self.showSpinner = true |
744 | 752 | ||
... | @@ -756,17 +764,21 @@ import SwiftEventBus | ... | @@ -756,17 +764,21 @@ import SwiftEventBus |
756 | self.showActiveCouponsBanners = false | 764 | self.showActiveCouponsBanners = false |
757 | 765 | ||
758 | if (swiftApi().getShowVouchersBanner() == "null") { | 766 | if (swiftApi().getShowVouchersBanner() == "null") { |
759 | - self.emptyView.isHidden = false | 767 | + // TODO: UNCOMMENT if emptyView is needed again |
760 | - self.emptyViewHeight.constant = self.emptyView.intrinsicContentSize.height | 768 | +// self.emptyView.isHidden = false |
769 | +// self.emptyViewHeight.constant = self.emptyView.intrinsicContentSize.height | ||
770 | + self.showEmptyView = true | ||
761 | 771 | ||
762 | } else { | 772 | } else { |
763 | self.emptyView.isHidden = true | 773 | self.emptyView.isHidden = true |
764 | self.emptyViewHeight.constant = 0 | 774 | self.emptyViewHeight.constant = 0 |
775 | + self.showEmptyView = false | ||
765 | } | 776 | } |
766 | 777 | ||
767 | } else { | 778 | } else { |
768 | self.emptyView.isHidden = true | 779 | self.emptyView.isHidden = true |
769 | self.emptyViewHeight.constant = 0 | 780 | self.emptyViewHeight.constant = 0 |
781 | + self.showEmptyView = false | ||
770 | 782 | ||
771 | self.showActiveCouponsBanners = true | 783 | self.showActiveCouponsBanners = true |
772 | } | 784 | } |
... | @@ -1028,7 +1040,7 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1028,7 +1040,7 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1028 | 1040 | ||
1029 | public func numberOfSections(in tableView: UITableView) -> Int { | 1041 | public func numberOfSections(in tableView: UITableView) -> Int { |
1030 | // return 4 | 1042 | // return 4 |
1031 | - return 3 | 1043 | + return 6 |
1032 | } | 1044 | } |
1033 | 1045 | ||
1034 | public func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { | 1046 | public func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { |
... | @@ -1060,12 +1072,27 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1060,12 +1072,27 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1060 | return 0 | 1072 | return 0 |
1061 | } | 1073 | } |
1062 | } else if (section == 1) { | 1074 | } else if (section == 1) { |
1075 | + return 1 | ||
1076 | + } else if (section == 2) { | ||
1077 | + let sumRedeemed = totalCouponValue + totalCouponDiscount + unifiedCouponsDiscount | ||
1078 | + if (sumRedeemed > 0.0) { | ||
1079 | + return 1 | ||
1080 | + } else { | ||
1081 | + return 0 | ||
1082 | + } | ||
1083 | + } else if (section == 3) { | ||
1063 | if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { | 1084 | if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { |
1064 | return 1 | 1085 | return 1 |
1065 | } else { | 1086 | } else { |
1066 | return 0 | 1087 | return 0 |
1067 | } | 1088 | } |
1068 | - } else if (section == 2) { | 1089 | + } else if (section == 4) { |
1090 | + if (self.showEmptyView == true) { | ||
1091 | + return 1 | ||
1092 | + } else { | ||
1093 | + return 0 | ||
1094 | + } | ||
1095 | + } else if (section == 5) { | ||
1069 | if (self.showSpinner == true) { | 1096 | if (self.showSpinner == true) { |
1070 | return 1 | 1097 | return 1 |
1071 | } else { | 1098 | } else { |
... | @@ -1114,12 +1141,27 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1114,12 +1141,27 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1114 | return 0.0 | 1141 | return 0.0 |
1115 | } | 1142 | } |
1116 | } else if (indexPath.section == 1) { | 1143 | } else if (indexPath.section == 1) { |
1144 | + return UITableView.automaticDimension | ||
1145 | + } else if (indexPath.section == 2) { | ||
1146 | + let sumRedeemed = totalCouponValue + totalCouponDiscount + unifiedCouponsDiscount | ||
1147 | + if (sumRedeemed > 0.0) { | ||
1148 | + return UITableView.automaticDimension | ||
1149 | + } else { | ||
1150 | + return 0.0 | ||
1151 | + } | ||
1152 | + } else if (indexPath.section == 3) { | ||
1117 | if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { | 1153 | if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { |
1118 | return UITableView.automaticDimension | 1154 | return UITableView.automaticDimension |
1119 | } else { | 1155 | } else { |
1120 | return 0.0 | 1156 | return 0.0 |
1121 | } | 1157 | } |
1122 | - } else if (indexPath.section == 2) { | 1158 | + } else if (indexPath.section == 4) { |
1159 | + if (self.showEmptyView == true) { | ||
1160 | + return UITableView.automaticDimension | ||
1161 | + } else { | ||
1162 | + return 0.0 | ||
1163 | + } | ||
1164 | + } else if (indexPath.section == 5) { | ||
1123 | if (self.showSpinner == true) { | 1165 | if (self.showSpinner == true) { |
1124 | return UITableView.automaticDimension | 1166 | return UITableView.automaticDimension |
1125 | } else { | 1167 | } else { |
... | @@ -1200,9 +1242,10 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1200,9 +1242,10 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1200 | view.backgroundColor = .clear | 1242 | view.backgroundColor = .clear |
1201 | 1243 | ||
1202 | let titleLabel = UILabel(frame: CGRect(x: 20, y: 20, width: view.frame.width - 40, height: 25)) | 1244 | let titleLabel = UILabel(frame: CGRect(x: 20, y: 20, width: view.frame.width - 40, height: 25)) |
1203 | - titleLabel.font = UIFont(name: "PeridotPE-SBold", size: 21) | 1245 | +// titleLabel.font = UIFont(name: "PeridotPE-SBold", size: 21) |
1246 | + titleLabel.font = UIFont(name: "BTCosmo-Bold", size: 19) | ||
1204 | titleLabel.textColor = UIColor(red: 0.13, green: 0.13, blue: 0.13, alpha: 1.00) | 1247 | titleLabel.textColor = UIColor(red: 0.13, green: 0.13, blue: 0.13, alpha: 1.00) |
1205 | - titleLabel.text = "Ενεργά κουπόνια" | 1248 | + titleLabel.text = "Κουπόνια" |
1206 | 1249 | ||
1207 | view.addSubview(titleLabel) | 1250 | view.addSubview(titleLabel) |
1208 | return view | 1251 | return view |
... | @@ -1210,6 +1253,10 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1210,6 +1253,10 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1210 | return nil | 1253 | return nil |
1211 | } | 1254 | } |
1212 | } else if (section == 1) { | 1255 | } else if (section == 1) { |
1256 | + return nil | ||
1257 | + } else if (section == 2) { | ||
1258 | + return nil | ||
1259 | + } else if (section == 3) { | ||
1213 | // if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { | 1260 | // if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { |
1214 | // let view = UIView(frame: CGRect(x: 0, y: 0, width: tableView.frame.width, height: 70)) | 1261 | // let view = UIView(frame: CGRect(x: 0, y: 0, width: tableView.frame.width, height: 70)) |
1215 | // view.backgroundColor = .clear | 1262 | // view.backgroundColor = .clear |
... | @@ -1227,7 +1274,9 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1227,7 +1274,9 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1227 | // } else { | 1274 | // } else { |
1228 | return nil | 1275 | return nil |
1229 | // } | 1276 | // } |
1230 | - } else if (section == 2) { | 1277 | + } else if (section == 4) { |
1278 | + return nil | ||
1279 | + } else if (section == 5) { | ||
1231 | return nil | 1280 | return nil |
1232 | } else { | 1281 | } else { |
1233 | return nil | 1282 | return nil |
... | @@ -1270,12 +1319,18 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1270,12 +1319,18 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1270 | return 0.0 | 1319 | return 0.0 |
1271 | } | 1320 | } |
1272 | } else if (section == 1) { | 1321 | } else if (section == 1) { |
1322 | + return 0.0 | ||
1323 | + } else if (section == 2) { | ||
1324 | + return 0.0 | ||
1325 | + } else if (section == 3) { | ||
1273 | // if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { | 1326 | // if (swiftApi().getShowVouchersBanner() == "true" || swiftApi().getShowVouchersBanner() == "false") { |
1274 | // return 70.0 | 1327 | // return 70.0 |
1275 | // } else { | 1328 | // } else { |
1276 | return 0.0 | 1329 | return 0.0 |
1277 | // } | 1330 | // } |
1278 | - } else if (section == 2) { | 1331 | + } else if (section == 4) { |
1332 | + return 0.0 | ||
1333 | + } else if (section == 5) { | ||
1279 | return 0.0 | 1334 | return 0.0 |
1280 | } else { | 1335 | } else { |
1281 | return 0.0 | 1336 | return 0.0 |
... | @@ -1323,9 +1378,19 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1323,9 +1378,19 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1323 | return cell | 1378 | return cell |
1324 | 1379 | ||
1325 | } else if (indexPath.section == 1) { | 1380 | } else if (indexPath.section == 1) { |
1381 | + let cell = tableView.dequeueReusableCell(withIdentifier: "WalletQuestionnaireBannerTableViewCellId", for: indexPath) as! WalletQuestionnaireBannerTableViewCell | ||
1382 | + cell.configureCell() | ||
1383 | + return cell | ||
1384 | + } else if (indexPath.section == 2) { | ||
1385 | + let cell = tableView.dequeueReusableCell(withIdentifier: "WalletHistoryBannerTableViewCellId", for: indexPath) as! WalletHistoryBannerTableViewCell | ||
1386 | + return cell | ||
1387 | + } else if (indexPath.section == 3) { | ||
1326 | let cell = tableView.dequeueReusableCell(withIdentifier: "WalletVouchersBannerTableViewCellId", for: indexPath) as! WalletVouchersBannerTableViewCell | 1388 | let cell = tableView.dequeueReusableCell(withIdentifier: "WalletVouchersBannerTableViewCellId", for: indexPath) as! WalletVouchersBannerTableViewCell |
1327 | cell.configureCell(showSeparator: self.showActiveCouponsBanners, active: swiftApi().getShowVouchersBanner() == "true") | 1389 | cell.configureCell(showSeparator: self.showActiveCouponsBanners, active: swiftApi().getShowVouchersBanner() == "true") |
1328 | return cell | 1390 | return cell |
1391 | + } else if (indexPath.section == 4) { | ||
1392 | + let cell = tableView.dequeueReusableCell(withIdentifier: "WalletEmptyViewTableViewCellId", for: indexPath) as! WalletEmptyViewTableViewCell | ||
1393 | + return cell | ||
1329 | } else { | 1394 | } else { |
1330 | let cell = tableView.dequeueReusableCell(withIdentifier: "WalletSpinnerTableViewCellId", for: indexPath) as! WalletSpinnerTableViewCell | 1395 | let cell = tableView.dequeueReusableCell(withIdentifier: "WalletSpinnerTableViewCellId", for: indexPath) as! WalletSpinnerTableViewCell |
1331 | return cell | 1396 | return cell |
... | @@ -1376,6 +1441,23 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1376,6 +1441,23 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1376 | // Do nothing - Each button is handled differently | 1441 | // Do nothing - Each button is handled differently |
1377 | 1442 | ||
1378 | } else if (indexPath.section == 1) { | 1443 | } else if (indexPath.section == 1) { |
1444 | + swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "Questionnaire")) | ||
1445 | + | ||
1446 | + swiftApi().openQuestionnaire(self); | ||
1447 | + | ||
1448 | + } else if (indexPath.section == 2) { | ||
1449 | + let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel() | ||
1450 | + firebaseEvent._eventName = "did_tap_history_badge" | ||
1451 | + firebaseEvent.setParameter = ("screen", "Loyalty Wallet") | ||
1452 | + SwiftEventBus.post("firebase", sender: firebaseEvent) | ||
1453 | + | ||
1454 | + swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "LoyaltyHistoryBadge")) | ||
1455 | + | ||
1456 | + let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self)) | ||
1457 | + let vc = storyboard.instantiateViewController(withIdentifier: "LoyaltyHistoryViewController") as! SwiftWarplyFramework.LoyaltyHistoryViewController | ||
1458 | + self.navigationController?.pushViewController(vc, animated: true) | ||
1459 | + | ||
1460 | + } else if (indexPath.section == 3) { | ||
1379 | let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel() | 1461 | let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel() |
1380 | firebaseEvent._eventName = "did_tap_vouchers_badge" | 1462 | firebaseEvent._eventName = "did_tap_vouchers_badge" |
1381 | firebaseEvent.setParameter = ("screen", "Loyalty Wallet") | 1463 | firebaseEvent.setParameter = ("screen", "Loyalty Wallet") |
... | @@ -1385,7 +1467,9 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ | ... | @@ -1385,7 +1467,9 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{ |
1385 | 1467 | ||
1386 | SwiftEventBus.post("vouchers_banner_pressed") | 1468 | SwiftEventBus.post("vouchers_banner_pressed") |
1387 | 1469 | ||
1388 | - } else if (indexPath.section == 2) { | 1470 | + } else if (indexPath.section == 4) { |
1471 | + // Do nothing | ||
1472 | + } else if (indexPath.section == 5) { | ||
1389 | // Do nothing | 1473 | // Do nothing |
1390 | } else { | 1474 | } else { |
1391 | // Do nothing | 1475 | // Do nothing | ... | ... |
-
Please register or login to post a comment