Merge branch 'staging' into preprod
This commit is contained in:
commit
3fdc3d15e5
@ -17,19 +17,16 @@ export default class StripeService {
|
|||||||
|
|
||||||
public async createCheckoutSession(subscription: Subscription, frequency: EPaymentFrequency) {
|
public async createCheckoutSession(subscription: Subscription, frequency: EPaymentFrequency) {
|
||||||
let priceId = this.variables.STRIPE_UNLIMITED_SUBSCRIPTION_PRICE_ID;
|
let priceId = this.variables.STRIPE_UNLIMITED_SUBSCRIPTION_PRICE_ID;
|
||||||
if(subscription.type === "STANDARD") {
|
if (subscription.type === "STANDARD") {
|
||||||
if(frequency === EPaymentFrequency.Yearly) {
|
if (frequency === EPaymentFrequency.Yearly) {
|
||||||
priceId = this.variables.STRIPE_STANDARD_ANNUAL_SUBSCRIPTION_PRICE_ID;
|
priceId = this.variables.STRIPE_STANDARD_ANNUAL_SUBSCRIPTION_PRICE_ID;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
priceId = this.variables.STRIPE_STANDARD_SUBSCRIPTION_PRICE_ID;
|
priceId = this.variables.STRIPE_STANDARD_SUBSCRIPTION_PRICE_ID;
|
||||||
}
|
}
|
||||||
}
|
} else if (subscription.type === "UNLIMITED") {
|
||||||
else if(subscription.type === "UNLIMITED") {
|
if (frequency === EPaymentFrequency.Yearly) {
|
||||||
if(frequency === EPaymentFrequency.Yearly) {
|
|
||||||
priceId = this.variables.STRIPE_UNLIMITED_ANNUAL_SUBSCRIPTION_PRICE_ID;
|
priceId = this.variables.STRIPE_UNLIMITED_ANNUAL_SUBSCRIPTION_PRICE_ID;
|
||||||
}
|
} else {
|
||||||
else{
|
|
||||||
priceId = this.variables.STRIPE_UNLIMITED_SUBSCRIPTION_PRICE_ID;
|
priceId = this.variables.STRIPE_UNLIMITED_SUBSCRIPTION_PRICE_ID;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -51,10 +48,8 @@ export default class StripeService {
|
|||||||
env: this.variables.ENV,
|
env: this.variables.ENV,
|
||||||
},
|
},
|
||||||
allow_promotion_codes: true,
|
allow_promotion_codes: true,
|
||||||
|
automatic_tax: { enabled: true },
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public async getStripeSubscriptionByUid(subscriptionId: string) {
|
public async getStripeSubscriptionByUid(subscriptionId: string) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user