Manos Chorianopoulos

delete questionnaire campaign if user has userTag

No preview for this file type
......@@ -2012,8 +2012,13 @@ public class swiftApi {
}
public func setCampaignList(_ campaigns: Array<CampaignItemModel>) -> Void {
let userTag = self.getUserTag()
if ((userTag != nil) && (userTag != "")) {
GlobalVariables.campaigns = campaigns.filter { $0.offer_category != "questionnaire" }
} else {
GlobalVariables.campaigns = campaigns
}
}
public class WarplyDealsAnalysisEventModel {
......@@ -2141,8 +2146,14 @@ public class swiftApi {
public func setUniqueCampaignList(_ campaigns: Array<CampaignItemModel>) -> Void {
let userTag = self.getUserTag()
if ((userTag != nil) && (userTag != "")) {
GlobalVariables.campaigns = campaigns.filter { $0.offer_category != "questionnaire" }
} else {
GlobalVariables.campaigns = campaigns
}
}
public func getCampaignList() -> Array<CampaignItemModel> {
......