Toggle navigation
Toggle navigation
This project
Loading...
Sign in
open-source
/
warply_sdk_framework
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Authored by
Manos Chorianopoulos
2022-11-24 15:09:16 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
d960a51ef16d4734c1582ad38d507022da1087b7
d960a51e
1 parent
d1c6cf1a
fix campaigns refresh after ccms activation
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
6 deletions
SwiftWarplyFramework/SwiftWarplyFramework/CampaignViewController.swift
SwiftWarplyFramework/SwiftWarplyFramework/swiftApi.swift
SwiftWarplyFramework/SwiftWarplyFramework/CampaignViewController.swift
View file @
d960a51
...
...
@@ -198,20 +198,24 @@ var timer2: DispatchSourceTimer?
SwiftEventBus
.
post
(
"coupon_retrieved"
,
sender
:
couponEvent
)
swiftApi
()
.
getCouponsAsync
(
getCouponsCallback
)
swiftApi
()
.
getCampaignsAsyncNew
(
language
:
"en"
,
filters
:
[
String
:
Any
](),
getCampaignsCallback
)
func
getCouponsCallback
(
_
couponsData
:
Array
<
swiftApi
.
CouponItemModel
>
?)
->
Void
{
if
(
couponsData
!=
nil
)
{
DispatchQueue
.
main
.
async
{
SwiftEventBus
.
post
(
"coupons_fetched"
)
}
}
else
{
}
}
// print("========= getCouponsRequest SUCCESSSS CampaignVC =========")
// print("========= getCouponsRequest count CampaignVC =========")
// print(swiftApi().getCouponList().count
)
func
getCampaignsCallback
(
_
campaignsData
:
Array
<
swiftApi
.
CampaignItemModel
>
?)
->
Void
{
if
(
campaignsData
!=
nil
)
{
DispatchQueue
.
main
.
async
{
SwiftEventBus
.
post
(
"campaigns_retrieved"
)
}
}
else
{
// print("========= getCouponsRequest ERROR CampaignVC =========")
}
}
...
...
SwiftWarplyFramework/SwiftWarplyFramework/swiftApi.swift
View file @
d960a51
...
...
@@ -4944,7 +4944,7 @@ public class swiftApi {
swiftApi
()
.
setUserTag
(
""
)
swiftApi
()
.
setUserNonTelco
(
false
)
swiftApi
()
.
setCCMSLoyaltyCampaigns
(
campaigns
:
[])
//
swiftApi().setCCMSLoyaltyCampaigns(campaigns: [])
let
instanceOfMyApi
=
MyApi
()
instanceOfMyApi
.
getCosmoteUserAsync
(
guid
,
requestCallback
,
failureBlock
:
requestFailureCallback
)
...
...
Please
register
or
login
to post a comment