apply Offer To Current Plan
fun applyOfferToCurrentPlan(activity: Activity, zsPlan: ZSPlan, currentPlanCode: String, storeOrderId: String, zsCustomFields: ArrayList<ZSCustomField> = ArrayList(), offerId: String, purchasesUpdatedListener: PurchaseUpdationListener)
Will apply offer to the current subscription of the user based on the product code and offer id details passed. The subscription will be updated in Play Store and the corresponding subscription will be updated in Zoho Billing too.
Parameters
activity
The current activity from which the purchase is initiated.
zs Plan
The plan object ZSPlan to which the user wants to change.
current Plan Code
The product code of the current plan to which the offer has to be applied.
store Order Id
The store order ID of the current plan.
zs Custom Fields
An optional array of custom fields ZSCustomField to be sent along with the subscription data to Zoho Billing.
offer Id
The offer id which has to be applied to the current plan.
purchases Updated Listener
An interface which handles the success or failure result of the purchase flow.