mirror of
https://github.com/bitwarden/browser
synced 2025-12-11 22:03:36 +00:00
Send SkipTrial = true to organization create when trial length is 0 (#14701)
This commit is contained in:
@@ -215,6 +215,7 @@ export class TrialBillingStepComponent implements OnInit, OnDestroy {
|
||||
const payment: PaymentInformation = {
|
||||
paymentMethod,
|
||||
billing: this.getBillingInformationFromTaxInfoComponent(),
|
||||
skipTrial: this.trialLength === 0,
|
||||
};
|
||||
|
||||
const response = await this.organizationBillingService.purchaseSubscription({
|
||||
|
||||
@@ -6,4 +6,5 @@ import { OrganizationNoPaymentMethodCreateRequest } from "../../../billing/model
|
||||
export class OrganizationCreateRequest extends OrganizationNoPaymentMethodCreateRequest {
|
||||
paymentMethodType: PaymentMethodType;
|
||||
paymentToken: string;
|
||||
skipTrial?: boolean;
|
||||
}
|
||||
|
||||
@@ -39,6 +39,7 @@ export type BillingInformation = {
|
||||
export type PaymentInformation = {
|
||||
paymentMethod: [string, PaymentMethodType];
|
||||
billing: BillingInformation;
|
||||
skipTrial?: boolean;
|
||||
};
|
||||
|
||||
export type SubscriptionInformation = {
|
||||
|
||||
@@ -174,6 +174,7 @@ export class OrganizationBillingService implements OrganizationBillingServiceAbs
|
||||
const [paymentToken, paymentMethodType] = information.paymentMethod;
|
||||
request.paymentToken = paymentToken;
|
||||
request.paymentMethodType = paymentMethodType;
|
||||
request.skipTrial = information.skipTrial;
|
||||
|
||||
const billingInformation = information.billing;
|
||||
request.billingAddressPostalCode = billingInformation.postalCode;
|
||||
|
||||
Reference in New Issue
Block a user