-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from mention-me/feature/segment-update
Pass segment through to the enrolment
- Loading branch information
Showing
3 changed files
with
15 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,6 +21,7 @@ class EnrolReferrerViewController: UIViewController { | |
var firstname = "Logan" | ||
var surname = "Smith" | ||
var email = "[email protected]" | ||
var segment = "vip" | ||
var privacyTermsString = "" | ||
var offer: MentionmeOffer? | ||
var shareLinks: [MentionmeShareLink]? | ||
|
@@ -52,10 +53,13 @@ class EnrolReferrerViewController: UIViewController { | |
} | ||
|
||
func checkIfReferrerCanEnrol() { | ||
let parameters = MentionmeCustomerParameters( | ||
emailAddress: email, firstname: firstname, surname: surname) | ||
parameters.segment = segment | ||
|
||
//Check if the enrollment can even happen before trying to enrol the referrer | ||
Mentionme.shared.entryPointForReferrerEnrollment( | ||
mentionmeReferrerEnrollmentRequest: MentionmeReferrerEnrollmentRequest(), | ||
mentionmeReferrerEnrollmentRequest: MentionmeReferrerEnrollmentRequest(mentionmeCustomerParameters: parameters), | ||
situation: "app-check-enrol-referrer", | ||
success: { (url, defaultCallToActionString) in | ||
|
||
|
@@ -82,6 +86,8 @@ class EnrolReferrerViewController: UIViewController { | |
//Creating customer parameters with email , firstname and surname | ||
let parameters = MentionmeCustomerParameters( | ||
emailAddress: email, firstname: firstname, surname: surname) | ||
parameters.segment = segment | ||
|
||
//Creating the customer request needed for the referrer enrolment. | ||
let request = MentionmeCustomerRequest(mentionmeCustomerParameters: parameters) | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,7 +8,7 @@ | |
|
||
Pod::Spec.new do |s| | ||
s.name = 'MentionmeSwift' | ||
s.version = '1.2' | ||
s.version = '2.0' | ||
s.summary = 'Supercharge your customer growth with referral marketing through Mention Me' | ||
|
||
# This description is used to generate tags and improve search results. | ||
|
@@ -24,7 +24,7 @@ Pod::Spec.new do |s| | |
s.author = { 'mention-me' => '[email protected]' } | ||
s.source = { :git => 'https://github.com/mention-me/ios-sdk.git', :tag => s.version.to_s } | ||
|
||
s.ios.deployment_target = '9.3' | ||
s.ios.deployment_target = '11.0' | ||
s.swift_version = '5.0' | ||
s.source_files = 'MentionmeSwift/Classes/**/*' | ||
s.pod_target_xcconfig = { 'SWIFT_VERSION' => '5.0' } | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters