ios – Apple Pay的“付款未完成” – 无法获得令牌

前端之家收集整理的这篇文章主要介绍了ios – Apple Pay的“付款未完成” – 无法获得令牌前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我正在使用PassKit实现Apple Pay,我正在以正确的方式显示对话框并处理委托方法,但每次我使用touch Id验证购买时它都显示“付款未完成”并且从未到达我的委托方法paymentAuthorizationViewController:didAuthorizePayment:完成:.我完全完成了 these things全部设置苹果工资,但我似乎无法获得一个令牌发送到我的支付网关.
PKPaymentRequest *request = [[PKPaymentRequest alloc] init];
self.paymentRequest = request;
request.countryCode = @"US";
request.currencyCode = @"USD";
request.supportedNetworks = @[PKPaymentNetworkAmex,PKPaymentNetworkMasterCard,PKPaymentNetworkVisa];
request.merchantCapabilities = PKMerchantCapabilityEMV;
request.merchantIdentifier = @"merchant.com.*******";
request.requiredShippingAddressFields = PKAddressFieldPostalAddress;
request.requiredBillingAddressFields = PKAddressFieldPostalAddress;

request.paymentSummaryItems = [self paymentSummaryItems];
self.paymentPane = [[PKPaymentAuthorizationViewController alloc] initWithPaymentRequest:request];
self.paymentPane.delegate = self;
if (self.paymentPane) {
    [self presentViewController:self.paymentPane animated:TRUE completion:nil];
}

这就是我所看到的,屏幕就在那里,一遍又一遍地说“再试一次”:

解决方法

终于得到了一个令牌.我需要启用3DS作为支付处理功能
request.merchantCapabilities = PKMerchantCapabilityEMV | PKMerchantCapability3DS;

这就是我用来复制别人代码方法(http://goo.gl/uvkl8F).奇怪,因为根据the docs,3DS是“必需的”:

You must support 3DS; support of EMV is optional.

为什么我必须明确陈述3DS是商家支持的,当它需要超出我.

原文链接:https://www.f2er.com/iOS/334235.html

猜你在找的iOS相关文章