【发布时间】:2016-01-01 21:49:54
【问题描述】:
我知道 iOS 9 中有特定的new method 支持针对特定场景或用例的 Apple Pay 抑制。我有一个需要用以下方法申请:
+ (PKSuppressionRequestToken)requestAutomaticPassPresentationSuppressionWithResponseHandler:(void (^ _Nonnull)(PKAutomaticPassPresentationSuppressionResult result))responseHandler
但是,每次我们调用此方法时,都会得到以下响应:PKAutomaticPassPresentationSuppressionResultDenied (Either the user prevented the suppression, or an internal error occurred)
在文档中标记为重要注意事项:
重要 此方法需要 Apple 颁发的特殊权利。 如果权利不存在,则请求将失败并返回 PKAutomaticPassPresentationSuppressionResultNotSupported 结果。为了 更多信息,请参阅 developer.apple.com/apple-pay/。
我们应该怎么做才能得到PKAutomaticPassPresentationSuppressionResultSuccess的结果?我们在“Apple ID”中启用了 Apple Pay,甚至创建了 Merchand ID,然后再次下载了包含所有这些并包含在项目中的 Development Provisioning Profile。我们也在那里启用了“Apple Pay”功能,但我们仍然收到PKAutomaticPassPresentationSuppressionResultDenied 错误。
测试环境信息:
- 带有支持 Apple Pay 的卡的 iPhone 6
- iOS 9.0.1 (13A404)
谢谢大家
【问题讨论】:
标签: ios objective-c iphone applepay