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-06-28 17:33:44 +0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
b484cdaacd0d3e3f09071f36e8e214f0e7bf61b6
b484cdaa
1 parent
8dd91be1
fix constructCcmsUrl
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
42 additions
and
1 deletions
SwiftWarplyFramework/SwiftWarplyFramework/swiftApi.swift
SwiftWarplyFramework/SwiftWarplyFramework/swiftApi.swift
View file @
b484cda
...
...
@@ -1348,7 +1348,48 @@ public class swiftApi {
return
finalUrl
}
public
func
constructCcmsUrl
(
_
campaign
:
LoyaltyContextualOfferModel
)
->
String
{
public
func
constructCcmsUrl
(
_
sessionId
:
String
,
_
campaign
:
LoyaltyContextualOfferModel
)
->
String
{
for
item
in
GlobalVariables
.
campaigns
{
if
(
item
.
loyaltyCampaignId
==
campaign
.
_loyaltyCampaignId
)
{
let
instanceOfMyApi
=
MyApi
()
let
campaignInfo
=
instanceOfMyApi
.
provideInfoForCampaign
()
let
finalUrl
=
(
item
.
index_url
??
""
)
+
"?web_id="
+
(
campaignInfo
?[
"web_id"
]
as!
String
)
+
"&app_uuid="
+
(
campaignInfo
?[
"app_uuid"
]
as!
String
)
+
"&api_key="
+
(
campaignInfo
?[
"api_key"
]
as!
String
)
+
"&session_uuid="
+
(
item
.
session_uuid
??
""
)
+
"&access_token="
+
(
campaignInfo
?[
"access_token"
]
as!
String
)
+
"&refresh_token="
+
(
campaignInfo
?[
"refresh_token"
]
as!
String
)
+
"&client_id="
+
(
campaignInfo
?[
"client_id"
]
as!
String
)
+
"&client_secret="
+
(
campaignInfo
?[
"client_secret"
]
as!
String
)
+
"&Session_ID="
+
sessionId
// (campaign._sessionId as! String)
+
"&businessService="
+
"&offerName="
+
(
campaign
.
_offerName
as!
String
)
+
"&productType="
+
(
campaign
.
_productType
as!
String
)
+
"&provDuration="
+
(
campaign
.
_provDuration
as!
String
)
+
"&noOfRecurrance="
+
(
campaign
.
_noOfRecurrance
as!
String
)
+
"&price="
+
(
campaign
.
_price
as!
String
)
+
"&discount="
+
(
campaign
.
_discount
as!
String
)
+
"&voiceCategory="
+
(
campaign
.
_voiceCategory
as!
String
)
+
"&dataCategory="
+
(
campaign
.
_dataCategory
as!
String
)
+
"&minsValue="
+
(
campaign
.
_minsValue
as!
String
)
+
"&dataValue="
+
(
campaign
.
_dataValue
as!
String
)
+
"&provStepValueMins="
+
(
campaign
.
_provStepValueMins
as!
String
)
+
"&UACIOfferTrackingCode="
+
"&MSISDN="
+
"&OFFERCODE1="
+
"&SCORE="
+
"&ZONE="
+
"&WAVE="
+
"&VALIDITY="
+
"&TREATMENT_CODE="
+
"&GUID="
+
"&OfferAudienceLevel="
;
return
finalUrl
break
;
}
}
return
""
}
...
...
Please
register
or
login
to post a comment