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
2024-11-01 11:54:00 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
429855f7a2c6c339df95ac51ea3e862290f8f1e3
429855f7
1 parent
93518ae8
ContextualViewController submitOrder optimizations
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
2 deletions
SwiftWarplyFramework/SwiftWarplyFramework/ContextualViewController.swift
SwiftWarplyFramework/SwiftWarplyFramework/ContextualViewController.swift
View file @
429855f
...
...
@@ -202,7 +202,8 @@ import SwiftEventBus
case
.
default
:
self
.
navigationController
?
.
popViewController
(
animated
:
true
)
swiftApi
()
.
getCouponsAsync
(
getCouponsCallback
,
failureCallback
:
{
errorCode
in
})
// swiftApi().getCouponsAsync(getCouponsCallback, failureCallback: {errorCode in })
swiftApi
()
.
getCouponsAsyncInternal
(
getCouponsCallback
,
failureCallback
:
{
errorCode
in
})
func
getCouponsCallback
(
_
couponsData
:
Array
<
swiftApi
.
CouponItemModel
>
?)
->
Void
{
if
(
couponsData
!=
nil
)
{
...
...
@@ -213,7 +214,24 @@ import SwiftEventBus
}
}
swiftApi
()
.
getCampaignsAsyncNew
(
language
:
"en"
,
filters
:
[
String
:
Any
](),
getCampaignsCallback
,
failureCallback
:
{
errorCode
in
})
var
campaignFound
:
swiftApi
.
CampaignItemModel
?
=
nil
if
let
ccmLoyaltyCampaignId
=
self
.
ccms
?
.
_loyaltyCampaignId
{
let
allCampaigns
=
swiftApi
()
.
getAllCampaignList
()
for
item
in
allCampaigns
{
if
(
item
.
session_uuid
==
ccmLoyaltyCampaignId
)
{
campaignFound
=
item
break
;
}
}
}
if
let
tempCampaign
=
campaignFound
{
swiftApi
()
.
removeCampaignItem
(
campaignArg
:
tempCampaign
)
swiftApi
()
.
getCampaignsAsyncNewInternal
(
getCampaignsCallback
,
failureCallback
:
{
errorCode
in
})
}
// swiftApi().getCampaignsAsyncNew(language: "en", filters: [String : Any](), getCampaignsCallback, failureCallback: {errorCode in })
func
getCampaignsCallback
(
_
campaignsData
:
Array
<
swiftApi
.
CampaignItemModel
>
?)
->
Void
{
if
(
campaignsData
!=
nil
)
{
...
...
Please
register
or
login
to post a comment