mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-04-02 21:02:57 +08:00
feat(in-app-purchase-2): update TypeScript definitions (#3037)
This commit is contained in:
parent
bb7b516c50
commit
4ae35cba9a
@ -4,7 +4,7 @@ import { Injectable } from '@angular/core';
|
||||
/**
|
||||
* @name In App Purchase 2
|
||||
* @description
|
||||
* In-App Purchase for Cordova on iOS, Android and Windows
|
||||
* In-App Purchase for Cordova on iOS, Android, Windows, macOS and XBox.
|
||||
*
|
||||
* @usage
|
||||
* ```typescript
|
||||
@ -33,17 +33,17 @@ import { Injectable } from '@angular/core';
|
||||
*
|
||||
* // Updated
|
||||
* this.store.when(productId).updated( (product: IAPProduct) => {
|
||||
* console.log('Loaded' + JSON.stringify(product));
|
||||
* console.log('Updated' + JSON.stringify(product));
|
||||
* });
|
||||
*
|
||||
* // Issue with buying
|
||||
* this.store.when(productId).cancelled( (product) => {
|
||||
* alert('Purchase was Cancelled');
|
||||
* console.error('Purchase was Cancelled');
|
||||
* });
|
||||
*
|
||||
* // Track All Store Errors
|
||||
* this.store.error( (err) => {
|
||||
* alert('Store Error ' + JSON.stringify(err));
|
||||
* console.error('Store Error ' + JSON.stringify(err));
|
||||
* });
|
||||
*
|
||||
* this.store.ready(() => {
|
||||
@ -56,7 +56,7 @@ import { Injectable } from '@angular/core';
|
||||
* // Errors
|
||||
* this.store.when(productId).error( (error) => {
|
||||
* this.loader.dismiss();
|
||||
* alert('An Error Occured' + JSON.stringify(error));
|
||||
* console.error('An Error Occured' + JSON.stringify(error));
|
||||
* });
|
||||
* // Refresh Starts Handlers
|
||||
* console.log('Refresh Store');
|
||||
@ -126,6 +126,30 @@ export interface IAPProduct {
|
||||
|
||||
downloaded: boolean;
|
||||
|
||||
lastRenewalDate: Date;
|
||||
|
||||
expiryDate: Date;
|
||||
|
||||
introPrice: string;
|
||||
|
||||
introPriceMicros: number;
|
||||
|
||||
introPriceNumberOfPeriods: number;
|
||||
|
||||
introPriceSubscriptionPeriod: string;
|
||||
|
||||
introPricePaymentMode: string;
|
||||
|
||||
ineligibleForIntroPrice: boolean;
|
||||
|
||||
billingPeriod: number;
|
||||
|
||||
billingPeriodUnit: string;
|
||||
|
||||
trialPeriod: number;
|
||||
|
||||
trialPeriodUnit: string;
|
||||
|
||||
additionalData: any;
|
||||
|
||||
transaction: any;
|
||||
|
Loading…
x
Reference in New Issue
Block a user