-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NT-261] Pass refParam with Apple Pay backings #842
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works like a charm
Approved even though I had 1 question (feel free to ping me back if you're going to address it or not - I can do a quick re-review).
Those test descriptions were super helpful, thank you for providing those!
let pledgeViewController = PledgeViewController.instantiate() | ||
pledgeViewController.configureWith(project: project, reward: reward) | ||
pledgeViewController.configureWith(project: project, reward: reward, refTag: refTag) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also inject refTag
from ManageViewPledgeViewController
or is it not going to be necessary?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmmm, I think it's not necessary. The updateBackingPaymentSource
mutation doesn't currently accept a refParam
. I'd imagine that for updating your backing, the backend would automatically set the referrer as update_pledge
or something like that, since there's no real "referrer" for updating a pledge. I'll double check with product though. Regardless I think if we wanted to pass the refParam
with the updateBackingPaymentSource
mutation that would be in a separate PR.
} | ||
selectedShippingRule, | ||
refTag | ||
).map { $0 as CreateBackingData } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this!
π² What
Passes through the
refTag
from the project page all the way to thecreateApplePayBacking
request.π€ Why
So we can track the referrer on Apple Pay backings.
π How
Passes the
RefTag
from the project page to thePledgeViewController
, which then passes it as part of the mutation input for thecreateApplePayBacking
mutation. TherefTag
is always optional.β Acceptance criteria
To test Apple Pay transactions, you must run the app on a device that is Apple Pay capable.
βͺοΈ [KsApi] Input:
which will show you the mutation input for thecreateApplePayBacking
mutation. In the input, you should see the keyrefParam
.