当交易更新时,StoreKit 不会调用 paymentQueue
我正在尝试使用此代码进行交易:
SKPayment *payment = [SKPayment paymentWithProductIdentifier:@"com.this.is.where.the.identifier.is"];
[[SKPaymentQueue defaultQueue] addPayment:payment];
交易进行得很好,但是 -(void) paymentQueue:(SKPaymentQueue *)queue UpdatedTransactions:(NSArray *)transactions
没有被调用,所以有无法更新我的应用程序以启用专业功能。我已将委托协议 SKPaymentTransactionObserver
包含在头文件中。
I am trying to do a transaction using this code:
SKPayment *payment = [SKPayment paymentWithProductIdentifier:@"com.this.is.where.the.identifier.is"];
[[SKPaymentQueue defaultQueue] addPayment:payment];
The transaction goes through fine, but -(void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray *)transactions
isn't called so there is no way of updating my application to enable the pro features. I have included the delegate protocol SKPaymentTransactionObserver
in the header file.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请确保您将观察者添加到付款队列中。
观察者,/代码>将是您在其头文件中实现 SKPaymentTransactionObserver 协议的类的对象。
如果您已经这样做了,请写在这里,以便我可以进一步帮助您。
请阅读以下内容了解更多详情。
http://developer.apple.com/library/ios//#/library/mac/documentation/NetworkingInternet/Conceptual/StoreKitGuide/AddingaStoretoYourApplication/AddingaStoretoYourApplication.html#//apple_ref/doc/uid/TP40008267 -CH101-SW1
please make sure that you are adding an observer to payment queue.
observer,/code> will be object of class in whose header file you are implementing SKPaymentTransactionObserver protocol.
If you have already done that than write here so that i can assist you further.
Please read following for further detail.
http://developer.apple.com/library/ios//#/library/mac/documentation/NetworkingInternet/Conceptual/StoreKitGuide/AddingaStoretoYourApplication/AddingaStoretoYourApplication.html#//apple_ref/doc/uid/TP40008267-CH101-SW1