mirror of
https://github.com/bitwarden/server.git
synced 2024-12-23 17:07:42 +01:00
adjust plans and add max subvaults to orgs
This commit is contained in:
parent
7e093a73be
commit
e3cc1b9411
@ -18,8 +18,6 @@ namespace Bit.Core.Models.StaticStore
|
||||
public decimal UserMonthlyPrice { get; set; }
|
||||
public decimal BaseAnnualPrice { get; set; }
|
||||
public decimal UserAnnualPrice { get; set; }
|
||||
public TimeSpan? Trial { get; set; }
|
||||
public Func<DateTime, TimeSpan> Cycle { get; set; }
|
||||
public bool Disabled { get; set; }
|
||||
}
|
||||
}
|
||||
|
@ -13,6 +13,7 @@ namespace Bit.Core.Models.Table
|
||||
public string Plan { get; set; }
|
||||
public PlanType PlanType { get; set; }
|
||||
public short MaxUsers { get; set; }
|
||||
public short? MaxSubvaults { get; set; }
|
||||
public string StripeCustomerId { get; set; }
|
||||
public string StripeSubscriptionId { get; set; }
|
||||
public DateTime CreationDate { get; internal set; } = DateTime.UtcNow;
|
||||
|
@ -94,7 +94,7 @@ namespace Bit.Core.Utilities
|
||||
new Plan
|
||||
{
|
||||
Type = PlanType.Free,
|
||||
BaseUsers = 1,
|
||||
BaseUsers = 2,
|
||||
CanBuyAdditionalUsers = false,
|
||||
Name = "Free"
|
||||
},
|
||||
@ -105,8 +105,7 @@ namespace Bit.Core.Utilities
|
||||
BaseAnnualPrice = 12,
|
||||
UserAnnualPrice = 12,
|
||||
CanBuyAdditionalUsers = true,
|
||||
Trial = new TimeSpan(14, 0, 0, 0),
|
||||
Cycle = now => now.AddYears(1) - now,
|
||||
CanMonthly = false,
|
||||
Name = "Personal",
|
||||
StripeAnnualPlanId = "personal-annual",
|
||||
StripeAnnualUserPlanId = "personal-user-annual"
|
||||
@ -121,8 +120,6 @@ namespace Bit.Core.Utilities
|
||||
UserMonthlyPrice = 2.5M,
|
||||
CanBuyAdditionalUsers = true,
|
||||
CanMonthly = true,
|
||||
Trial = new TimeSpan(14, 0, 0, 0),
|
||||
Cycle = now => now.AddMonths(1) - now,
|
||||
Name = "Teams",
|
||||
StripeAnnualPlanId = "teams-annual",
|
||||
StripeAnnualUserPlanId = "teams-user-annual",
|
||||
|
@ -6,6 +6,7 @@
|
||||
@Plan NVARCHAR(20),
|
||||
@PlanType TINYINT,
|
||||
@MaxUsers SMALLINT,
|
||||
@MaxSubvaults SMALLINT,
|
||||
@StripeCustomerId VARCHAR(50),
|
||||
@StripeSubscriptionId VARCHAR(50),
|
||||
@CreationDate DATETIME2(7),
|
||||
@ -23,6 +24,7 @@ BEGIN
|
||||
[Plan],
|
||||
[PlanType],
|
||||
[MaxUsers],
|
||||
[MaxSubvaults],
|
||||
[StripeCustomerId],
|
||||
[StripeSubscriptionId],
|
||||
[CreationDate],
|
||||
@ -37,6 +39,7 @@ BEGIN
|
||||
@Plan,
|
||||
@PlanType,
|
||||
@MaxUsers,
|
||||
@MaxSubvaults,
|
||||
@StripeCustomerId,
|
||||
@StripeSubscriptionId,
|
||||
@CreationDate,
|
||||
|
@ -6,6 +6,7 @@
|
||||
@Plan NVARCHAR(20),
|
||||
@PlanType TINYINT,
|
||||
@MaxUsers SMALLINT,
|
||||
@MaxSubvaults SMALLINT,
|
||||
@StripeCustomerId VARCHAR(50),
|
||||
@StripeSubscriptionId VARCHAR(50),
|
||||
@CreationDate DATETIME2(7),
|
||||
@ -24,6 +25,7 @@ BEGIN
|
||||
[Plan] = @Plan,
|
||||
[PlanType] = @PlanType,
|
||||
[MaxUsers] = @MaxUsers,
|
||||
[MaxSubvaults] = @MaxSubvaults,
|
||||
[StripeCustomerId] = @StripeCustomerId,
|
||||
[StripeSubscriptionId] = @StripeSubscriptionId,
|
||||
[CreationDate] = @CreationDate,
|
||||
|
@ -6,6 +6,7 @@
|
||||
[Plan] NVARCHAR (20) NOT NULL,
|
||||
[PlanType] TINYINT NOT NULL,
|
||||
[MaxUsers] SMALLINT NULL,
|
||||
[MaxSubvaults] SMALLINT NULL,
|
||||
[StripeCustomerId] VARCHAR (50) NULL,
|
||||
[StripeSubscriptionId] VARCHAR (50) NULL,
|
||||
[CreationDate] DATETIME2 (7) NOT NULL,
|
||||
|
Loading…
Reference in New Issue
Block a user