Appcelerator Titanium and Apple Pay

时间:2016-07-11 23:24:16

标签: titanium appcelerator applepay

I am trying to use Apple Pay in a Titanium app. So far I've gotten it to work about a third of the time I run the app, the rest of the time the app crashes. My suspicion is that not adding the apple pay entitlement to the app is causing the crash (unfortunately there is no error message in the console when the app crashes).

Has anyone had any luck getting Apple Pay to work in a Titanium app?

2 个答案:

答案 0 :(得分:1)

好吧,如果不宣传我的http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-route53-aliastarget.html,这可能是采用Apple Pay with Titanium的最简单方法。它支持所有主要的Titanium版本,并包含所有可用的本机API。试一试或使用自定义的: - )

答案 1 :(得分:0)

我得到了它的工作。以下是我的模块中代码的要点:https://gist.github.com/zach-babb-moovel/bd4172454cf54a178855e76ca5dd1f48。关键是在dispatch_async调用中包装PKPaymentRequest和后续PKPaymentAuthorizationViewController部分。您还必须确保所有配置文件都已正确设置,并且您为Titanium项目使用自定义Entitlements.plist文件。在这里查看Entitlements.plist:https://github.com/hansemannn/applepaydemo/blob/master/Entitlements.plist了解它应该是什么样的。