문제

I have integrated in-app Billing into my android app. And there is one requirement: user should be able to buy (only one existing product) once a year. Is any way to do this? Because now if user have successfully finished purchase process, this product will be available for him forever! Thanks!

도움이 되었습니까?

해결책

You need to use an unmanaged purchase as these can be purchased as often as necessary and are intended to be consumable.

You will also however, lose the convenience of the Android Market handling the license server and you will need to manage that yourself.

다른 팁

Why not make a new product for every new year? Then check in your code whether the user has bought the product for the current year, otherwise offer him to buy it.

As far as I know, you can not take a previously bought product away from a user, so you must find another solution.

From in-App version 2 Subscription is also available. You just create a subscription product and set frequency as yearly. Google will automatically takes care rest of headache.

Tutorial can be found here.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top