module Spaceship::Tunes::IAPStatus
Defines the different states of an in-app purchase
As specified by Apple: developer.apple.com/library/content/documentation/LanguagesUtilities/Conceptual/iTunesConnectInAppPurchase_Guide/Chapters/WorkingWithYourProductsStatus.html
Constants
- APPROVED
Approved (and currently available)
- DELETED
Developer deleted
- DEVELOPER_ACTION_NEEDED
In-app purchase need developer's action
- DEVELOPER_REMOVED_FROM_SALE
The developer took the app from the
App
Store- IN_REVIEW
Currently in Review
- MISSING_METADATA
IAP
created, but missing screenshot/metadata- READY_TO_SUBMIT
You can edit the metadata, change screenshot and more. Need to submit.
- REJECTED
In-app purchase rejected for whatever reason
- WAITING_FOR_REVIEW
Waiting for Apple's Review
Public Class Methods
get_from_string(text)
click to toggle source
Get the iap status matching based on a string (given by App
Store Connect)
# File spaceship/lib/spaceship/tunes/iap_status.rb, line 35 def self.get_from_string(text) mapping = { 'missingMetadata' => MISSING_METADATA, 'readyToSubmit' => READY_TO_SUBMIT, 'waitingForReview' => WAITING_FOR_REVIEW, 'inReview' => IN_REVIEW, 'readyForSale' => APPROVED, 'deleted' => DELETED, 'rejected' => REJECTED, 'developerRemovedFromSale' => DEVELOPER_REMOVED_FROM_SALE, 'developerActionNeeded' => DEVELOPER_ACTION_NEEDED } mapping.each do |itc_status, readable_status| return readable_status if itc_status == text end return nil end