做自动再生订阅发送SKPaymentTransactionStatePurchased交易时,自动更新? [英] Do auto-renewable subscriptions send an SKPaymentTransactionStatePurchased transaction when they auto-renew?

查看:947
本文介绍了做自动再生订阅发送SKPaymentTransactionStatePurchased交易时,自动更新?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否在AppStore发出一个事务时,它自动更新自动再生订阅?如果是这样,可以把它可靠地通过一个应用程序的下一个时间,如果将自身设置为观察员检测到的应用程序加载:

Does the AppStore send out a transaction when it auto-renews an auto-renewable subscription? If so, can it reliably be detected by an App the next time the App loads if it sets itself as an observer:

[[SKPaymentQueue defaultQueue] addTransactionObserver:self];

将新的自动更新交易拨打电话为:

Will the new auto-renewed transaction make a call to:

-(void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray *)transactions

与transaction.transactionState == SKPaymentTransactionStatePurchased?

with transaction.transactionState==SKPaymentTransactionStatePurchased?

如果这样,太好了。如果不是,这是否意味着你必须在每一个汽车再生利用订阅接近到期日时的时间检查所有交易:

If so, great. If not, does this mean you must examine all transactions every time an auto-renewable subscription approaches expiration using:

 [[SKPaymentQueue defaultQueue] restoreCompletedTransactions]; 

谢谢...

推荐答案

经过一番研究,我可以回答我的问题,并提出了另一个相关的问题。在App Store调用paymentQueue和岗位交易。本次交易是贴有transaction.transactionState == SKPaymentTransactionStateRestored,
不transaction.transactionState == SKPaymentTransactionStatePurchased。

After some research I can answer my own question and raise another related issue. The App Store calls the paymentQueue and posts a transaction. The transaction is posted with transaction.transactionState==SKPaymentTransactionStateRestored, not transaction.transactionState==SKPaymentTransactionStatePurchased.

问题是,不幸的是这被张贴只有一台设备。第二个设备没有得到过帐。因此,要检测自动更新,或者说检测缺乏自动续订,并否认该设备的持续订阅,你必须做一个restoreCompletedTransaction或HTTP POST 64位的EN codeD JSON含最后一笔交易。如果fomer,用户需要给他们的密码;这是侵入性的。如果是后者,许多附加的编码是必需的。所以,我的问题是......为什么不StoreKit有一个命令:

The issue is that unfortunately this gets posted only to one device. A second device does not get the posting. Therefore, to detect the auto-renewal, or rather to detect the lack of an autorenewal and deny the device a continuing subscription, you have to do a restoreCompletedTransaction or "http post a 64-bit encoded JSON containing the last transaction". If the fomer, the user needs to give their password; that's intrusive. If the latter, lots of additional coding is required. So, my question is...why doesn't StoreKit have a command:

(不存在) - [[SKPaymentQueue defaultQueue] restoreAttachedTransactions:(NSArray的*)交易];

(does not exist) - [[SKPaymentQueue defaultQueue] restoreAttachedTransactions:(NSArray *)transactions];

此命令将流动就像restoreCompletedtRansactions但它只会恢复附加交易,而最重要的是,它不要求登录在由用户。它具有相同的安全保护的HTTP POST 64位恩含最后一笔交易codeD JSON,它使得整个应用程序内购买过程中StoreKit完成而不需要网络发帖code。

This command would flow just like a restoreCompletedtRansactions but it would only restore the attached transactions and, most importantly, it would not require log-in by the user. It has the same security protection as the "http post a 64-bit encoded JSON containing the last transaction" and it allows the entire In App Purchase process to be done in StoreKit rather than requiring web posting code.

如果这是有道理的给你们,请建议如何得到这个苹果....谢谢。

If this makes sense to you, please suggest how to get this to Apple....thanks.

这篇关于做自动再生订阅发送SKPaymentTransactionStatePurchased交易时,自动更新?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆