Manos Chorianopoulos

comment out SwiftEventBus

......@@ -27,7 +27,7 @@ Pod::Spec.new do |spec|
spec.exclude_files = "Classes/Exclude"
# spec.dependency 'RSBarcodes_Swift', '~> 5.1.1'
spec.dependency 'SwiftEventBus'
# spec.dependency 'SwiftEventBus'
# spec.resource_bundles = { 'ResourcesBundle' => ['SwiftWarplyFramework/**/*.{png,jpeg,jpg,storyboard,xib,xcassets,json,ttf,imageset,strings}'] }
spec.resource_bundles = { 'ResourcesBundle' => ['SwiftWarplyFramework/**/*.{storyboard,xib,otf,ttf,xcassets}'] }
......
......@@ -58,7 +58,6 @@
1EEA9FD02B7371670019C854 /* OffersTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1EEA9FCF2B7371670019C854 /* OffersTableViewCell.swift */; };
1EEA9FD22B737D900019C854 /* LoyaltyViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1EEA9FD12B737D900019C854 /* LoyaltyViewController.swift */; };
1EEA9FD42B7384260019C854 /* FiltersTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1EEA9FD32B7384260019C854 /* FiltersTableViewCell.swift */; };
1EEAA0152B73B0EA0019C854 /* SwiftEventBus in Frameworks */ = {isa = PBXBuildFile; productRef = 1EEAA0142B73B0EA0019C854 /* SwiftEventBus */; };
7630AD9A6242D60846D6750C /* Pods_SwiftWarplyFramework.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C0D5F56DD4E5371A50AD2D87 /* Pods_SwiftWarplyFramework.framework */; };
A02F34052882B6E60086465F /* TelcoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A02F34042882B6E60086465F /* TelcoViewController.swift */; };
A04D31DE288FF670000E43B5 /* HistoryViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = A04D31DD288FF670000E43B5 /* HistoryViewController.swift */; };
......@@ -396,7 +395,6 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
1EEAA0152B73B0EA0019C854 /* SwiftEventBus in Frameworks */,
7630AD9A6242D60846D6750C /* Pods_SwiftWarplyFramework.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
......@@ -884,7 +882,6 @@
);
name = SwiftWarplyFramework;
packageProductDependencies = (
1EEAA0142B73B0EA0019C854 /* SwiftEventBus */,
);
productName = SwiftWarplyFramework;
productReference = E6A7784E282933340045BBA8 /* SwiftWarplyFramework.framework */;
......@@ -915,7 +912,6 @@
);
mainGroup = E6A77844282933340045BBA8;
packageReferences = (
1EEAA0132B73B0EA0019C854 /* XCRemoteSwiftPackageReference "SwiftEventBus" */,
);
productRefGroup = E6A7784F282933340045BBA8 /* Products */;
projectDirPath = "";
......@@ -1321,25 +1317,6 @@
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
/* Begin XCRemoteSwiftPackageReference section */
1EEAA0132B73B0EA0019C854 /* XCRemoteSwiftPackageReference "SwiftEventBus" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/cesarferreira/SwiftEventBus";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 5.1.0;
};
};
/* End XCRemoteSwiftPackageReference section */
/* Begin XCSwiftPackageProductDependency section */
1EEAA0142B73B0EA0019C854 /* SwiftEventBus */ = {
isa = XCSwiftPackageProductDependency;
package = 1EEAA0132B73B0EA0019C854 /* XCRemoteSwiftPackageReference "SwiftEventBus" */;
productName = SwiftEventBus;
};
/* End XCSwiftPackageProductDependency section */
};
rootObject = E6A77845282933340045BBA8 /* Project object */;
}
......
{
"pins" : [
{
"identity" : "swifteventbus",
"kind" : "remoteSourceControl",
"location" : "https://github.com/cesarferreira/SwiftEventBus",
"state" : {
"revision" : "a30ff35e616f507d8a8d122dac32a2150371a87e",
"version" : "5.1.0"
}
}
],
"version" : 2
}
......@@ -8,7 +8,7 @@
import Foundation
import UIKit
import WebKit
import SwiftEventBus
// import SwiftEventBus
// Location Permissions
import CoreLocation
......@@ -441,8 +441,8 @@ var timer2: DispatchSourceTimer?
questionnaireEvent._parameter = ""
swiftApi().setUserTag("")
}
SwiftEventBus.post("questionnaire", sender: questionnaireEvent)
SwiftEventBus.post("campaigns_retrieved")
// SwiftEventBus.post("questionnaire", sender: questionnaireEvent)
// SwiftEventBus.post("campaigns_retrieved")
}
} else {
}
......@@ -456,7 +456,7 @@ var timer2: DispatchSourceTimer?
} else if (eventArray[1] == "couponRetrieved") {
let couponEvent = swiftApi.CouponEventModel()
SwiftEventBus.post("coupon_retrieved", sender: couponEvent)
// SwiftEventBus.post("coupon_retrieved", sender: couponEvent)
swiftApi().getCouponsAsync(getCouponsCallback, failureCallback: {errorCode in })
swiftApi().getCampaignsAsyncNew(language: "en", filters: [String : Any](), getCampaignsCallback, failureCallback: {errorCode in })
......@@ -465,7 +465,7 @@ var timer2: DispatchSourceTimer?
if (couponsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("coupons_fetched")
// SwiftEventBus.post("coupons_fetched")
}
} else {
}
......@@ -474,7 +474,7 @@ var timer2: DispatchSourceTimer?
func getCampaignsCallback (_ campaignsData: Array<swiftApi.CampaignItemModel>?) -> Void {
if (campaignsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("campaigns_retrieved")
// SwiftEventBus.post("campaigns_retrieved")
}
} else {
}
......@@ -483,7 +483,7 @@ var timer2: DispatchSourceTimer?
} else if (eventArray[1] == "ccmsRetrieved") {
let ccmsEnabled = swiftApi.WarplyCCMSEnabledModel()
ccmsEnabled._isActivated = true
SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
// SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
} else if (eventArray[1] == "couponShared") {
......@@ -491,24 +491,24 @@ var timer2: DispatchSourceTimer?
else if (eventArray[1] == "steps" && eventArray[2] == "widgetDisabled") {
let pacingWidget = swiftApi.WarplyPacingCardEventModel()
pacingWidget._isVisible = false
SwiftEventBus.post("pacing_widget", sender: pacingWidget)
// SwiftEventBus.post("pacing_widget", sender: pacingWidget)
} else if (eventArray[1] == "steps" && eventArray[2] == "widgetEnabled") {
let pacingWidget = swiftApi.WarplyPacingCardEventModel()
pacingWidget._isVisible = true
SwiftEventBus.post("pacing_widget", sender: pacingWidget)
// SwiftEventBus.post("pacing_widget", sender: pacingWidget)
}
else if (eventArray[1] == "steps" && eventArray[2] == "shortcutEnabled") {
let pacingEvent = swiftApi.WarplyPacingEventModel()
pacingEvent._isVisible = true
SwiftEventBus.post("pacing", sender: pacingEvent)
// SwiftEventBus.post("pacing", sender: pacingEvent)
if (swiftApi().getTrackingStepsEnabled() == false) {
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "loyalty_steps_activation"
firebaseEvent._parameters = nil
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.startTrackingSteps()
}
......@@ -516,7 +516,7 @@ var timer2: DispatchSourceTimer?
} else if (eventArray[1] == "steps" && eventArray[2] == "shortcutDisabled") {
let pacingEvent = swiftApi.WarplyPacingEventModel()
pacingEvent._isVisible = false
SwiftEventBus.post("pacing", sender: pacingEvent)
// SwiftEventBus.post("pacing", sender: pacingEvent)
swiftApi().stopTrackingSteps()
} else if (eventArray[1] == "request" || eventArray[1] == "response") {
......@@ -528,25 +528,25 @@ var timer2: DispatchSourceTimer?
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "loyalty_questionnaire_selected"
firebaseEvent.setParameter = ("completed", "true")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "loyalty_questionnaire_answer_again") {
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "loyalty_questionnaire_answer_again"
firebaseEvent._parameters = nil
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "loyalty_questionnaire_answers_deleted") {
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "loyalty_questionnaire_answers_deleted"
firebaseEvent._parameters = nil
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "loyalty_questionnaire_later") {
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "loyalty_questionnaire_later"
firebaseEvent.setParameter = ("completed", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "loyalty_sdk_offer_selected") {
var name: String = ""
......@@ -567,7 +567,7 @@ var timer2: DispatchSourceTimer?
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", name)
firebaseEvent.setParameter = ("type", type)
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "loyalty_offer_activated") {
var name: String = ""
......@@ -596,10 +596,10 @@ var timer2: DispatchSourceTimer?
firebaseEvent.setParameter = ("name", name)
firebaseEvent.setParameter = ("type", type)
firebaseEvent.setParameter = ("successful", successful)
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "unified_coupon_activated") {
SwiftEventBus.post("unified_coupon_activated")
// SwiftEventBus.post("unified_coupon_activated")
var name: String = ""
if (eventArray.count > 2) {
......@@ -627,7 +627,7 @@ var timer2: DispatchSourceTimer?
firebaseEvent.setParameter = ("name", name)
firebaseEvent.setParameter = ("type", type)
firebaseEvent.setParameter = ("successful", successful)
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "time_spent_on_loyalty_sdk") {
var name: String = ""
......@@ -648,7 +648,7 @@ var timer2: DispatchSourceTimer?
firebaseEvent._eventName = "time_spent_on_loyalty_sdk"
firebaseEvent.setParameter = ("name", name)
firebaseEvent.setParameter = ("seconds", seconds)
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
} else if (eventArray[1] == "refreshToken") {
var access_token: String = ""
......@@ -671,7 +671,7 @@ var timer2: DispatchSourceTimer?
} else if (eventArray[1] == "loyaltyWallet") {
// event:loyaltyWallet
SwiftEventBus.post("refresh_vouchers")
// SwiftEventBus.post("refresh_vouchers")
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "WalletViewController") as! SwiftWarplyFramework.WalletViewController
......@@ -682,46 +682,46 @@ var timer2: DispatchSourceTimer?
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
SwiftEventBus.post("refresh_unified_coupons")
// SwiftEventBus.post("refresh_unified_coupons")
} else if (eventArray[1] == "cancel_unified_failed") {
// event:cancel_unified_failed
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else if (eventArray[1] == "create_unified_success") {
// event:create_unified_success
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_create_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
SwiftEventBus.post("refresh_unified_coupons")
// SwiftEventBus.post("refresh_unified_coupons")
} else if (eventArray[1] == "create_unified_failed") {
// event:create_unified_failed
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_create_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else if (eventArray[1] == "get_unified_success") {
// event:get_unified_success
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_unified_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else if (eventArray[1] == "get_unified_failed") {
// event:get_unified_failed
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_unified_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
......
......@@ -6,7 +6,7 @@
//
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class ContextualViewController: UIViewController, UIPopoverControllerDelegate {
@IBOutlet weak var mainView: UIView!
......@@ -180,7 +180,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
})
......@@ -196,11 +196,11 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "true")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let ccmsEnabled = swiftApi.WarplyCCMSEnabledModel()
ccmsEnabled._isActivated = true
SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
// SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
self.showDialog("Το αίτημά σου ολοκληρώθηκε επιτυχώς!","Θα ενημερωθείς άμεσα για την ενεργοποίηση του πακέτου σου.")
// self.postEventRequest()
......@@ -211,7 +211,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
}
......@@ -222,7 +222,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
}
......
......@@ -6,7 +6,7 @@
//
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class CouponViewController: UIViewController, UITextViewDelegate {
@IBOutlet weak var mainView: UIView!
......@@ -221,7 +221,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
})
......@@ -235,7 +235,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
})
......@@ -253,12 +253,12 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "true")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
if (self.ccms != nil) {
let ccmsEnabled = swiftApi.WarplyCCMSEnabledModel()
ccmsEnabled._isActivated = true
SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
// SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
}
self.showSuccessDialog("Επιτυχής ενεργοποίηση","Το κουπόνι σου έχει ενεργοποιηθεί στην ενότητα My Rewards.")
......@@ -270,7 +270,7 @@ import SwiftEventBus
if (couponsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("coupons_fetched")
// SwiftEventBus.post("coupons_fetched")
}
} else {
}
......@@ -279,7 +279,7 @@ import SwiftEventBus
func getCampaignsCallback (_ campaignsData: Array<swiftApi.CampaignItemModel>?) -> Void {
if (campaignsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("campaigns_retrieved")
// SwiftEventBus.post("campaigns_retrieved")
}
} else {
}
......@@ -291,7 +291,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Το κουπόνι δεν είναι διαθέσιμο για αγορά")
......@@ -301,7 +301,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Δεν έχεις αρκετούς πόντους")
......@@ -311,7 +311,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Το κουπόνι εξαντλήθηκε","Μείνε συντονισμένος για νέες προσφορές και κουπόνια.")
......@@ -321,7 +321,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
}
......@@ -332,7 +332,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.couponset?.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
}
......@@ -379,7 +379,7 @@ import SwiftEventBus
// MARK: - Actions
@IBAction func redeemButtomAction(_ sender: Any) {
// SwiftEventBus.post("couponRedeem", sender: coupon)
// SwiftEventBus.post("couponRedeem", sender: coupon)
swiftApi().logTrackersEvent("click", ("RetrieveCoupon:" + (couponset?.uuid ?? "")))
......
......@@ -7,7 +7,7 @@
import Foundation
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class CouponsViewController: UIViewController {
@IBOutlet weak var backgroundImage: UIImageView!
......@@ -75,7 +75,7 @@ import SwiftEventBus
self.coupons = activeCouponData
DispatchQueue.main.async {
SwiftEventBus.post("coupons_fetched")
// SwiftEventBus.post("coupons_fetched")
self.tableView.reloadData()
if (self.coupons.count == 0) {
......
......@@ -7,7 +7,7 @@
import Foundation
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class GiftsViewController: UIViewController {
@IBOutlet weak var mainView: UIView!
......@@ -39,26 +39,26 @@ import SwiftEventBus
tableView.delegate = self
tableView.dataSource = self
SwiftEventBus.onMainThread(self, name: "ccms_retrieved") { result in
print("===== SwiftEventBus ccms_retrieved =====")
// SwiftEventBus.onMainThread(self, name: "ccms_retrieved") { result in
// print("===== SwiftEventBus ccms_retrieved =====")
self.refreshData()
// self.refreshData()
}
// }
SwiftEventBus.onMainThread(self, name: "campaigns_retrieved") { result in
print("===== SwiftEventBus campaigns_retrieved =====")
// SwiftEventBus.onMainThread(self, name: "campaigns_retrieved") { result in
// print("===== SwiftEventBus campaigns_retrieved =====")
self.refreshData()
// self.refreshData()
}
// }
SwiftEventBus.onMainThread(self, name: "seasonals_retrieved") { result in
print("===== SwiftEventBus seasonals_retrieved =====")
// SwiftEventBus.onMainThread(self, name: "seasonals_retrieved") { result in
// print("===== SwiftEventBus seasonals_retrieved =====")
self.refreshData()
// self.refreshData()
}
// }
// tableView.clipsToBounds = true
// tableView.layer.cornerRadius = 30
......@@ -174,7 +174,7 @@ import SwiftEventBus
firebaseEvent._eventName = "time_spent_on_loyalty_sdk"
firebaseEvent.setParameter = ("name", "GiftsForYou")
firebaseEvent.setParameter = ("seconds", String(seconds))
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
seconds = 0
}
......@@ -243,7 +243,7 @@ extension GiftsViewController: UITableViewDelegate, UITableViewDataSource{
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (campaigns[indexPath.row]._ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("Contextual:" + (campaigns[indexPath.row]._ccms?._sessionId ?? "")))
......@@ -270,7 +270,7 @@ extension GiftsViewController: UITableViewDelegate, UITableViewDataSource{
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (item._title))
firebaseEvent.setParameter = ("type", "gift")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "TelcoViewController") as! SwiftWarplyFramework.TelcoViewController
......@@ -301,7 +301,7 @@ extension GiftsViewController: UITableViewDelegate, UITableViewDataSource{
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (item.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "CouponViewController") as! SwiftWarplyFramework.CouponViewController
......@@ -401,13 +401,13 @@ extension GiftsViewController: UITableViewDelegate, UITableViewDataSource{
seasonalEvent._title = campaigns[indexPath.row]._title ?? ""
seasonalEvent._imageUrl = campaigns[indexPath.row]._logo_url ?? ""
seasonalEvent._loyaltyPackageId = campaigns[indexPath.row]._loyaltyPackageId ?? ""
SwiftEventBus.post("seasonal", sender: seasonalEvent)
// SwiftEventBus.post("seasonal", sender: seasonalEvent)
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (campaigns[indexPath.row]._title ?? ""))
firebaseEvent.setParameter = ("type", "seasonal")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
}
}
}
......
......@@ -6,7 +6,7 @@
//
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class LoyaltyAnalysisViewController: UIViewController {
......@@ -106,7 +106,7 @@ import SwiftEventBus
firebaseEvent._eventName = "time_spent_on_loyalty_sdk"
firebaseEvent.setParameter = ("name", "GiftsCalculator")
firebaseEvent.setParameter = ("seconds", String(seconds))
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
seconds = 0
}
......
......@@ -7,7 +7,7 @@
import Foundation
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class LoyaltyHistoryViewController: UIViewController {
@IBOutlet weak var sectionTitleLabel: UILabel!
......@@ -51,28 +51,28 @@ import SwiftEventBus
self.hidesBottomBarWhenPushed = true
SwiftEventBus.onBackgroundThread(self, name: "coupons_fetched") { result in
// SwiftEventBus.onBackgroundThread(self, name: "coupons_fetched") { result in
DispatchQueue.main.async {
self.coupons = swiftApi().getCouponList()
self.totalCouponDiscount = Float(round(100 * swiftApi().getLoyaltyBadge()._value) / 100)
self.loyaltyBadge = swiftApi().getLoyaltyBadge()
// self.tableView.reloadData()
self.updateUI()
}
}
SwiftEventBus.onBackgroundThread(self, name: "unified_coupons_fetched") { result in
// DispatchQueue.main.async {
// self.coupons = swiftApi().getCouponList()
// self.totalCouponDiscount = Float(round(100 * swiftApi().getLoyaltyBadge()._value) / 100)
// self.loyaltyBadge = swiftApi().getLoyaltyBadge()
// // self.tableView.reloadData()
// self.updateUI()
// }
// }
// SwiftEventBus.onBackgroundThread(self, name: "unified_coupons_fetched") { result in
DispatchQueue.main.async {
self.unifiedCoupons = swiftApi().getUnifiedCouponList()
// DispatchQueue.main.async {
// self.unifiedCoupons = swiftApi().getUnifiedCouponList()
self.matchOldSMCoupons()
self.updateMarketBadge()
// self.tableView.reloadData()
self.updateUI()
}
}
// self.matchOldSMCoupons()
// self.updateMarketBadge()
// // self.tableView.reloadData()
// self.updateUI()
// }
// }
setBackButton()
setNavigationTitle("Ιστορικό")
......@@ -302,7 +302,7 @@ import SwiftEventBus
// analysis_pressed event
let dealsAnalysis = swiftApi.WarplyDealsAnalysisEventModel()
dealsAnalysis._isPressed = true
SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
// SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
// let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
// firebaseEvent._eventName = "did_tap_gifts_for_you_badge"
......@@ -312,7 +312,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_deals_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty History")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyHistoryScreen:" + "DealsBanner"))
// }
......@@ -328,7 +328,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_gifts_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty History")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyHistoryScreen:" + "LoyaltyBanner"))
......@@ -343,7 +343,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_market_badge"
firebaseEvent.setParameter = ("screen", "Loyalty History")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyHistoryScreen:" + "MarketBanner"))
......
......@@ -7,7 +7,7 @@
import Foundation
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class MFYViewController: UIViewController {
@IBOutlet weak var mainView: UIView!
......@@ -41,15 +41,15 @@ import SwiftEventBus
tableView.delegate = self
tableView.dataSource = self
SwiftEventBus.onMainThread(self, name: "ccms_retrieved") { result in
print("===== SwiftEventBus ccms_retrieved =====")
self.refreshData()
}
// SwiftEventBus.onMainThread(self, name: "ccms_retrieved") { result in
// print("===== SwiftEventBus ccms_retrieved =====")
// self.refreshData()
// }
SwiftEventBus.onMainThread(self, name: "campaigns_retrieved") { result in
print("===== SwiftEventBus campaigns_retrieved =====")
self.refreshData()
}
// SwiftEventBus.onMainThread(self, name: "campaigns_retrieved") { result in
// print("===== SwiftEventBus campaigns_retrieved =====")
// self.refreshData()
// }
// tableView.clipsToBounds = true
// tableView.layer.cornerRadius = 30
......@@ -183,7 +183,7 @@ import SwiftEventBus
firebaseEvent._eventName = "time_spent_on_loyalty_sdk"
firebaseEvent.setParameter = ("name", "MoreForYou")
firebaseEvent.setParameter = ("seconds", String(seconds))
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
seconds = 0
}
......@@ -283,7 +283,7 @@ extension MFYViewController: UITableViewDelegate, UITableViewDataSource{
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (campaign._ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("Contextual:" + (campaign._ccms?._sessionId ?? "")))
......@@ -310,7 +310,7 @@ extension MFYViewController: UITableViewDelegate, UITableViewDataSource{
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (item._title))
firebaseEvent.setParameter = ("type", "gift")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "TelcoViewController") as! SwiftWarplyFramework.TelcoViewController
......@@ -340,7 +340,7 @@ extension MFYViewController: UITableViewDelegate, UITableViewDataSource{
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (item.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "CouponViewController") as! SwiftWarplyFramework.CouponViewController
......
......@@ -6,7 +6,7 @@
//
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class MarketLoyaltyAnalysisViewController: UIViewController {
......@@ -107,7 +107,7 @@ import SwiftEventBus
firebaseEvent._eventName = "time_spent_on_loyalty_sdk"
firebaseEvent.setParameter = ("name", "GiftsCalculator")
firebaseEvent.setParameter = ("seconds", String(seconds))
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
seconds = 0
}
......
......@@ -6,7 +6,7 @@
//
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class ShareViewController: UIViewController, UITextFieldDelegate, UIPopoverControllerDelegate {
@IBOutlet weak var mainView: UIView!
......@@ -290,7 +290,7 @@ import SwiftEventBus
if (couponsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("coupons_fetched")
// SwiftEventBus.post("coupons_fetched")
self.showSuccessDialog("Συγχαρητήρια!","Μόλις έκανες δώρο ένα κουπόνι!")
}
} else {
......
......@@ -6,7 +6,7 @@
//
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class TelcoViewController: UIViewController, UIPopoverControllerDelegate {
@IBOutlet weak var mainView: UIView!
......@@ -234,7 +234,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
})
......@@ -249,11 +249,11 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "true")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let ccmsEnabled = swiftApi.WarplyCCMSEnabledModel()
ccmsEnabled._isActivated = true
SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
// SwiftEventBus.post("ccms_enabled", sender: ccmsEnabled)
self.showDialog("Το αίτημά σου ολοκληρώθηκε επιτυχώς!","Θα ενημερωθείς άμεσα για την ενεργοποίηση του πακέτου σου.")
// self.postEventRequest()
......@@ -264,7 +264,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
}
......@@ -275,7 +275,7 @@ import SwiftEventBus
firebaseEvent.setParameter = ("name", (self.ccms?._title ?? ""))
firebaseEvent.setParameter = ("type", "gift")
firebaseEvent.setParameter = ("successful", "false")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
self.showDialog("Αποτυχία","Κάτι πήγε στραβά")
}
......
......@@ -8,7 +8,7 @@
import UIKit
// import RSBarcodes_Swift
import AVFoundation
import SwiftEventBus
// import SwiftEventBus
@objc public class UnifiedCouponBarcodeViewController: UIViewController {
@IBOutlet weak var mainView: UIView!
......@@ -100,7 +100,7 @@ import SwiftEventBus
alert.addAction(UIAlertAction(title: "OK", style: .default, handler: { action in
switch action.style{
case .default:
SwiftEventBus.post("refresh_unified_coupons")
// SwiftEventBus.post("refresh_unified_coupons")
self.navigationController?.popViewController(animated: true)
// self.dismiss(animated: true, completion: {})
......
......@@ -7,7 +7,7 @@
import Foundation
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class UnifiedCouponsViewController: UIViewController {
@IBOutlet weak var backgroundImage: UIImageView!
......@@ -23,7 +23,7 @@ import SwiftEventBus
self.hidesBottomBarWhenPushed = true
SwiftEventBus.onBackgroundThread(self, name: "unified_coupons_fetched") { result in
// SwiftEventBus.onBackgroundThread(self, name: "unified_coupons_fetched") { result in
DispatchQueue.main.async {
self.unifiedCoupons = swiftApi().getUnifiedCouponList()
......
......@@ -7,7 +7,7 @@
import Foundation
import UIKit
import SwiftEventBus
// import SwiftEventBus
@objc public class WalletViewController: UIViewController {
@IBOutlet weak var headerImage: UIImageView!
......@@ -87,52 +87,52 @@ import SwiftEventBus
self.hidesBottomBarWhenPushed = true
SwiftEventBus.onBackgroundThread(self, name: "coupons_fetched") { result in
// SwiftEventBus.onBackgroundThread(self, name: "coupons_fetched") { result in
DispatchQueue.main.async {
self.coupons = swiftApi().getCouponList()
self.totalCouponDiscount = Float(round(100 * swiftApi().getLoyaltyBadge()._value) / 100)
self.loyaltyBadge = swiftApi().getLoyaltyBadge()
// DispatchQueue.main.async {
// self.coupons = swiftApi().getCouponList()
// self.totalCouponDiscount = Float(round(100 * swiftApi().getLoyaltyBadge()._value) / 100)
// self.loyaltyBadge = swiftApi().getLoyaltyBadge()
self.handleSpinnerAndEmptyView()
self.tableView.reloadData()
}
}
// self.handleSpinnerAndEmptyView()
// self.tableView.reloadData()
// }
// }
SwiftEventBus.onBackgroundThread(self, name: "unified_coupons_fetched") { result in
DispatchQueue.main.async {
self.unifiedCoupons = swiftApi().getUnifiedCouponList()
// TODO: Maybe add this
// TODO: Uncomment if discounts are shown again in wallet
// self.matchOldSMCoupons()
// self.updateMarketBadge()
self.handleSpinnerAndEmptyView()
self.tableView.reloadData()
}
}
// SwiftEventBus.onBackgroundThread(self, name: "unified_coupons_fetched") { result in
// DispatchQueue.main.async {
// self.unifiedCoupons = swiftApi().getUnifiedCouponList()
// // TODO: Maybe add this
// // TODO: Uncomment if discounts are shown again in wallet
// // self.matchOldSMCoupons()
// // self.updateMarketBadge()
// self.handleSpinnerAndEmptyView()
// self.tableView.reloadData()
// }
// }
SwiftEventBus.onBackgroundThread(self, name: "vouchers_fetched") { result in
// SwiftEventBus.onBackgroundThread(self, name: "vouchers_fetched") { result in
DispatchQueue.main.async {
print("=== vouchers_fetched event ===")
// DispatchQueue.main.async {
// print("=== vouchers_fetched event ===")
self.handleSpinnerAndEmptyView()
// self.showSpinner = false
self.tableView.reloadData()
// self.handleSpinnerAndEmptyView()
// // self.showSpinner = false
// self.tableView.reloadData()
}
}
// }
// }
SwiftEventBus.onBackgroundThread(self, name: "vouchers_service_unavailable") { result in
// SwiftEventBus.onBackgroundThread(self, name: "vouchers_service_unavailable") { result in
DispatchQueue.main.async {
print("=== vouchers_service_unavailable event ===")
// DispatchQueue.main.async {
// print("=== vouchers_service_unavailable event ===")
self.showVouchersFailureDialog()
// self.showVouchersFailureDialog()
}
}
// }
// }
// TODO: DELETE ===>
// let coupon = swiftApi.ActiveDFYCouponModel()
......@@ -668,7 +668,7 @@ import SwiftEventBus
firebaseEvent._eventName = "time_spent_on_loyalty_sdk"
firebaseEvent.setParameter = ("name", "MyRewards")
firebaseEvent.setParameter = ("seconds", String(seconds))
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
seconds = 0
}
......@@ -822,7 +822,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_history_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "LoyaltyHistoryBadge"))
......@@ -836,12 +836,12 @@ import SwiftEventBus
// analysis_pressed event
let dealsAnalysis = swiftApi.WarplyDealsAnalysisEventModel()
dealsAnalysis._isPressed = true
SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
// SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_gifts_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "DealsBanner"))
}
......@@ -850,7 +850,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_deals_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "LoyaltyBanner"))
......@@ -865,7 +865,7 @@ import SwiftEventBus
let couponDetails = swiftApi.ActiveDFYCouponEventModel()
couponDetails._isPressed = true
SwiftEventBus.post("dfy_coupon_details", sender: couponDetails)
// SwiftEventBus.post("dfy_coupon_details", sender: couponDetails)
}
@IBAction func dfyBadgeButtonAction(_ sender: Any) {
......@@ -875,12 +875,12 @@ import SwiftEventBus
// analysis_pressed event
let dealsAnalysis = swiftApi.WarplyDealsAnalysisEventModel()
dealsAnalysis._isPressed = true
SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
// SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_gifts_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "DealsBanner"))
}
......@@ -891,7 +891,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_deals_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "LoyaltyBanner"))
......@@ -908,7 +908,7 @@ import SwiftEventBus
// let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
// firebaseEvent._eventName = "did_tap_deals_for_you_badge"
// firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
// SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
// swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "LoyaltyBanner"))
......@@ -933,17 +933,17 @@ import SwiftEventBus
// analysis_pressed event
let dealsAnalysis = swiftApi.WarplyDealsAnalysisEventModel()
dealsAnalysis._isPressed = true
SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
// SwiftEventBus.post("analysis_pressed", sender: dealsAnalysis)
// let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
// firebaseEvent._eventName = "did_tap_gifts_for_you_badge"
// firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
// SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_deals_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "DealsBanner"))
}
......@@ -954,12 +954,12 @@ import SwiftEventBus
// let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
// firebaseEvent._eventName = "did_tap_deals_for_you_badge"
// firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
// SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_gifts_for_you_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "LoyaltyBanner"))
......@@ -974,7 +974,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_market_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "MarketBanner"))
......@@ -991,14 +991,14 @@ import SwiftEventBus
let couponDetails = swiftApi.ActiveDFYCouponEventModel()
couponDetails._isPressed = true
SwiftEventBus.post("dfy_coupon_details", sender: couponDetails)
// SwiftEventBus.post("dfy_coupon_details", sender: couponDetails)
}
@IBAction func smActiveCouponsBannerButtonAction(_ sender: Any) {
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_market_active_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "ActiveMarketBanner"))
......@@ -1011,7 +1011,7 @@ import SwiftEventBus
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_gifts_for_you_active_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "ActiveLoyaltyBanner"))
......@@ -1356,7 +1356,7 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{
//
// let couponDetails = swiftApi.ActiveDFYCouponEventModel()
// couponDetails._isPressed = true
// SwiftEventBus.post("dfy_coupon_details", sender: couponDetails)
// SwiftEventBus.post("dfy_coupon_details", sender: couponDetails)
//
// } else if (indexPath.section == 3) {
// let couponSetData: swiftApi.CouponSetItemModel? = coupons[indexPath.row].couponset_data
......@@ -1379,11 +1379,11 @@ extension WalletViewController: UITableViewDelegate, UITableViewDataSource{
let firebaseEvent = swiftApi.LoyaltySDKFirebaseEventModel()
firebaseEvent._eventName = "did_tap_vouchers_badge"
firebaseEvent.setParameter = ("screen", "Loyalty Wallet")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
swiftApi().logTrackersEvent("click", ("LoyaltyWalletScreen:" + "VouchersBadge"))
SwiftEventBus.post("vouchers_banner_pressed")
// SwiftEventBus.post("vouchers_banner_pressed")
} else if (indexPath.section == 2) {
// Do nothing
......
......@@ -7,7 +7,7 @@
import Foundation
import SwiftUI
import SwiftEventBus
// import SwiftEventBus
public struct GlobalVariables {
static var campaigns: Array<swiftApi.CampaignItemModel> = []
......@@ -199,7 +199,7 @@ public class swiftApi {
setShowVouchersBanner("null")
}
SwiftEventBus.post("vouchers_fetched")
// SwiftEventBus.post("vouchers_fetched")
}
......@@ -265,7 +265,7 @@ public class swiftApi {
let pacingEvent = swiftApi.HealthEventModel()
pacingEvent._meters = metersCount + oldDayMeters
SwiftEventBus.post("meters_sent", sender: pacingEvent)
// SwiftEventBus.post("meters_sent", sender: pacingEvent)
// print("=== MetersCount ===")
// print(metersCount)
......@@ -416,7 +416,7 @@ public class swiftApi {
GlobalVariables.ccmsCampaigns = campaigns
SwiftEventBus.post("ccms_retrieved")
// SwiftEventBus.post("ccms_retrieved")
}
public func mergeGFYCCMSLoyaltyCampaigns(campaigns: Array<LoyaltyContextualOfferModel>) -> Array<CampaignItemModel> {
......@@ -602,7 +602,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_couponset_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
let couponSetsData = (myCouponsSetsDictionary["MAPP_COUPON"] as! NSArray)
......@@ -615,7 +615,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponset_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
swiftApi().setCouponSetList(couponSetsArray)
......@@ -628,7 +628,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponset_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCouponSetsCallback(nil)
}
......@@ -659,7 +659,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_couponsets_sm_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataResult = responseDataDictionary["result"] as? [[String : Any]?] {
......@@ -671,21 +671,21 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponsets_sm_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponsets_sm_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponsets_sm_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
swiftApi().setCouponSetsDealsList(couponSetsArray)
......@@ -698,13 +698,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponsets_sm_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -899,7 +899,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_user_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// setAllOldCouponList uncluding Supermarkets ==>
var allOldCouponsArray:Array<CouponItemModel> = []
......@@ -929,13 +929,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_user_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -951,7 +951,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_couponset_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
let couponSetsData = (myCouponsSetsDictionary["MAPP_COUPON"] as! NSArray)
......@@ -964,7 +964,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponset_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
swiftApi().setCouponSetList(couponSetsArray)
......@@ -1000,7 +1000,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_couponset_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCouponsCallback(nil)
}
......@@ -1464,7 +1464,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_campaigns_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataMapp = responseDataDictionary["MAPP_CAMPAIGNING"] as? [String: Any] {
if let responseDataCampaigns = responseDataMapp["campaigns"] as? [[String : Any]?] {
......@@ -1522,7 +1522,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_campaigns_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCampaignsCallback(nil)
}
......@@ -1531,7 +1531,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_campaigns_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCampaignsCallback(nil)
}
......@@ -1545,7 +1545,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_campaigns_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCampaignsCallback(nil)
}
......@@ -1567,7 +1567,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_campaigns_personalized_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataContext = responseDataDictionary["context"] as? [String: Any] {
......@@ -1600,7 +1600,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_campaigns_personalized_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCampaignsCallback(nil)
}
......@@ -1609,7 +1609,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_campaigns_personalized_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getCampaignsCallback(nil)
}
......@@ -1623,13 +1623,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_campaigns_personalized_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -2634,7 +2634,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_profile_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
let profileDataResult = (profileDataDictionary["result"] as? [String: Any] ?? ["":""])
......@@ -2652,7 +2652,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_profile_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getProfileCallback(nil)
}
......@@ -2665,13 +2665,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_profile_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -2737,7 +2737,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_login_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
verifyTicketCallback(tempResponse);
......@@ -2747,7 +2747,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_login_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
verifyTicketCallback(tempResponse);
}
......@@ -2756,7 +2756,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_login_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
verifyTicketCallback(nil)
}
......@@ -2771,7 +2771,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_login_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
verifyTicketCallback(nil)
}
......@@ -3669,7 +3669,7 @@ public class swiftApi {
func getCouponsCallback (_ couponsData: Array<swiftApi.CouponItemModel>?) -> Void {
if (couponsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("coupons_fetched")
// SwiftEventBus.post("coupons_fetched")
}
} else {
}
......@@ -3736,7 +3736,7 @@ public class swiftApi {
func getCouponsCallback (_ couponsData: Array<swiftApi.CouponItemModel>?) -> Void {
if (couponsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("coupons_fetched")
// SwiftEventBus.post("coupons_fetched")
}
} else {
}
......@@ -4394,13 +4394,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_customer_state_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_customer_state_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
}
......@@ -4408,7 +4408,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_customer_state_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
consumerIntegrationCallback(tempResponse);
......@@ -4417,7 +4417,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_customer_state_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
consumerIntegrationCallback(nil)
}
......@@ -4432,13 +4432,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_customer_state_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -4465,13 +4465,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_retrieve_coupon_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_coupon_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
}
......@@ -4479,7 +4479,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_coupon_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
redeemCouponSetCallback(tempResponse);
......@@ -4488,7 +4488,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_coupon_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
redeemCouponSetCallback(nil)
}
......@@ -4503,13 +4503,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_coupon_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -4548,7 +4548,7 @@ public class swiftApi {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -4939,7 +4939,7 @@ public class swiftApi {
public func setSeasonalList(_ seasonalCoupons: Array<LoyaltyGiftsForYouPackage>) {
GlobalVariables.seasonalList = seasonalCoupons
SwiftEventBus.post("seasonals_retrieved")
// SwiftEventBus.post("seasonals_retrieved")
}
......@@ -5249,7 +5249,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getPacingDetailsCallback(tempPacingDetails);
......@@ -5257,14 +5257,14 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getPacingDetailsCallback(nil)
}
......@@ -5277,13 +5277,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -5332,7 +5332,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_save_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
let tempResponse = GenericResponseModel(dictionary: responseDataDictionary)
setPacingDetailsCallback(tempResponse);
......@@ -5345,7 +5345,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_save_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
setPacingDetailsCallback(nil)
}
......@@ -5354,7 +5354,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_save_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
setPacingDetailsCallback(nil)
}
......@@ -5366,13 +5366,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_save_pacing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -5469,7 +5469,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
let tempResponse = SharingResponseModel(dictionary: responseDataDictionary)
cosmoteSharingCallback(tempResponse);
......@@ -5477,7 +5477,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
cosmoteSharingCallback(nil)
}
......@@ -5487,7 +5487,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
cosmoteSharingCallback(nil)
}
......@@ -5502,13 +5502,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -5532,7 +5532,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_retrieve_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataDictionary = responseData as? [String: Any] {
......@@ -5547,7 +5547,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
cosmoteSharingCallback(nil)
}
......@@ -5556,7 +5556,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
cosmoteSharingCallback(nil)
}
......@@ -5571,13 +5571,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_retrieve_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -5646,13 +5646,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_coupon_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_coupon_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
}
......@@ -5660,7 +5660,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_coupon_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
couponSharingCallback(tempResponse);
......@@ -5669,7 +5669,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_coupon_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
couponSharingCallback(nil)
}
......@@ -5684,13 +5684,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_coupon_sharing_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -5718,13 +5718,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_submit_order_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_submit_order_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
}
......@@ -5732,7 +5732,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_submit_order_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
submitOrderCallback(tempResponse);
......@@ -5741,7 +5741,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_submit_order_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
submitOrderCallback(nil)
}
......@@ -5756,13 +5756,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_submit_order_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -5790,13 +5790,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_post_event_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_post_event_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
}
......@@ -5804,7 +5804,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_post_event_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
postEventCallback(tempResponse);
......@@ -5813,7 +5813,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_post_event_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
postEventCallback(nil)
}
......@@ -5828,13 +5828,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_post_event_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -6048,7 +6048,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataResult = responseDataDictionary["result"] as? [[String : Any]?] {
......@@ -6078,7 +6078,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getSharingHistoryCallback(nil)
}
......@@ -6087,7 +6087,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getSharingHistoryCallback(nil)
}
......@@ -6103,7 +6103,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataResult = responseDataDictionary["result"] as? [[String : Any]?] {
......@@ -6132,7 +6132,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getSharingHistoryCallback(nil)
}
......@@ -6141,7 +6141,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getSharingHistoryCallback(nil)
}
......@@ -6155,13 +6155,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_sharing_history_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -6188,7 +6188,7 @@ public class swiftApi {
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (item.name ?? ""))
firebaseEvent.setParameter = ("type", "coupon")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "CouponViewController") as! SwiftWarplyFramework.CouponViewController
......@@ -6252,7 +6252,7 @@ public class swiftApi {
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (ccms._title))
firebaseEvent.setParameter = ("type", "gift")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "ContextualViewController") as! SwiftWarplyFramework.ContextualViewController
......@@ -6297,7 +6297,7 @@ public class swiftApi {
firebaseEvent._eventName = "loyalty_sdk_offer_selected"
firebaseEvent.setParameter = ("name", (ccms._title))
firebaseEvent.setParameter = ("type", "gift")
SwiftEventBus.post("firebase", sender: firebaseEvent)
// SwiftEventBus.post("firebase", sender: firebaseEvent)
let storyboard = UIStoryboard(name: "Main", bundle: Bundle(for: MyEmptyClass.self))
let vc = storyboard.instantiateViewController(withIdentifier: "TelcoViewController") as! SwiftWarplyFramework.TelcoViewController
......@@ -6343,7 +6343,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_shops_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataMappShops = responseDataDictionary["MAPP_SHOPS"] as? [String: Any] {
......@@ -6372,7 +6372,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_shops_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getMerchantsCallback(nil)
}
......@@ -6381,7 +6381,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_shops_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getMerchantsCallback(nil)
}
......@@ -6395,7 +6395,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_shops_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getMerchantsCallback(nil)
}
......@@ -6962,7 +6962,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_logout_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
swiftApi().setUserTag("")
swiftApi().setUserNonTelco(false)
......@@ -6977,7 +6977,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_logout_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
logoutCallback(tempResponse);
......@@ -6986,7 +6986,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_logout_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
logoutCallback(nil)
}
......@@ -7139,7 +7139,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_edit_profile_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
swiftApi().getProfileAsync(getProfileCallback, failureCallback: {errorCode in })
}
......@@ -7148,7 +7148,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_edit_profile_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
editProfileCallback(nil)
}
......@@ -7163,13 +7163,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_edit_profile_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......@@ -7235,7 +7235,7 @@ public class swiftApi {
func getCampaignsCallback (_ campaignsData: Array<swiftApi.CampaignItemModel>?) -> Void {
if (campaignsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("campaigns_retrieved")
// SwiftEventBus.post("campaigns_retrieved")
}
} else {
}
......@@ -7251,14 +7251,14 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_read_campaign_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_read_campaign_loyalty" // custom_error_read_campaign_loyalty
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getSingleCampaignCallback(nil)
}
......@@ -7272,7 +7272,7 @@ public class swiftApi {
func getCampaignsCallback (_ campaignsData: Array<swiftApi.CampaignItemModel>?) -> Void {
if (campaignsData != nil) {
DispatchQueue.main.async {
SwiftEventBus.post("campaigns_retrieved")
// SwiftEventBus.post("campaigns_retrieved")
}
} else {
}
......@@ -7285,7 +7285,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_read_campaign_loyalty" // custom_error_read_campaign_loyalty
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
getSingleCampaignCallback(nil)
}
......@@ -7438,7 +7438,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_unified_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let responseDataResult = responseDataDictionary["result"] as? [String: Any] {
if let responseDataCoupons = responseDataResult["coupons"] as? [[String : Any]?] {
......@@ -7495,7 +7495,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_unified_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
successCallback(nil)
}
......@@ -7504,7 +7504,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_unified_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
successCallback(nil)
}
......@@ -7518,7 +7518,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_unified_coupons_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
successCallback(nil)
}
......@@ -7560,7 +7560,7 @@ public class swiftApi {
if (couponsData != nil) {
DispatchQueue.main.async {
// self.matchOldSMCoupons()
SwiftEventBus.post("unified_coupons_fetched")
// SwiftEventBus.post("unified_coupons_fetched")
successCallback(couponsData)
}
} else {
......@@ -7626,13 +7626,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_success_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
} else {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
}
......@@ -7640,7 +7640,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
}
cancelUnifiedCouponCallback(tempResponse);
......@@ -7649,7 +7649,7 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
cancelUnifiedCouponCallback(nil)
}
......@@ -7664,13 +7664,13 @@ public class swiftApi {
let dynatraceEvent = swiftApi.LoyaltySDKDynatraceEventModel()
dynatraceEvent._eventName = "custom_error_cancel_unified_loyalty"
dynatraceEvent._parameters = nil
SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
// SwiftEventBus.post("dynatrace", sender: dynatraceEvent)
if let error = error as? NSError {
// if (error.code == 401) {
// let sessionEvent = swiftApi.LoyaltySDKSessionExpiredEventModel()
// sessionEvent._sessionExpired = true
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// SwiftEventBus.post("sdk_session_expired", sender: sessionEvent)
// }
failureCallback(error.code)
......