1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-01 08:02:49 -05:00

stripe subscription creation

This commit is contained in:
Kyle Spearrin
2017-04-04 10:13:16 -04:00
parent 5187f4c15f
commit a4ef7c906e
10 changed files with 29 additions and 11 deletions

View File

@ -10,6 +10,7 @@ namespace Bit.Core.Models.Api
public string Name { get; set; }
public PlanType PlanType { get; set; }
public string Key { get; set; }
public string CardToken { get; set; }
public virtual OrganizationSignup ToOrganizationSignup(User user)
{
@ -18,7 +19,8 @@ namespace Bit.Core.Models.Api
Owner = user,
OwnerKey = Key,
Name = Name,
Plan = PlanType
Plan = PlanType,
PaymentToken = CardToken
};
}
}

View File

@ -9,12 +9,6 @@ namespace Bit.Core.Models.Business
public User Owner { get; set; }
public string OwnerKey { get; set; }
public Enums.PlanType Plan { get; set; }
public PaymentDetails Payment { get; set; }
public class PaymentDetails
{
public string Name { get; set; }
public string Token { get; set; }
}
public string PaymentToken { get; set; }
}
}

View File

@ -5,6 +5,8 @@ namespace Bit.Core.Models.StaticStore
{
public class Plan
{
public string Name { get; set; }
public string StripeId { get; set; }
public PlanType Type { get; set; }
public short MaxUsers { get; set; }
public decimal Price { get; set; }