Adds authentication and pricing pages for user onboarding
Introduces comprehensive user authentication flow with plan selection and registration Includes: - Pricing page with plan details and selection - Payment page with plan summary and card information - Signup page for different plan tiers - Shared authentication layout and design system improvements Enhances user onboarding experience with clear plan information and streamlined signup process
This commit is contained in:
parent
cd092f8290
commit
217a9cd95c
18 changed files with 2312 additions and 165 deletions
101
PlanTempus.Application/Features/Accounts/Models/PlanInfo.cs
Normal file
101
PlanTempus.Application/Features/Accounts/Models/PlanInfo.cs
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
namespace PlanTempus.Application.Features.Accounts.Models;
|
||||
|
||||
public record PlanInfo(
|
||||
string Key,
|
||||
string Name,
|
||||
string UserRange,
|
||||
decimal? PricePerMonth,
|
||||
string BadgeText,
|
||||
string BadgeClass,
|
||||
string BadgeIcon,
|
||||
IReadOnlyList<string> Features,
|
||||
bool RequiresPayment,
|
||||
bool IsContactSales
|
||||
)
|
||||
{
|
||||
public bool IsFree => PricePerMonth == 0;
|
||||
public string PriceDisplay => PricePerMonth.HasValue ? $"{PricePerMonth:0}" : "Kontakt os";
|
||||
}
|
||||
|
||||
public static class PlanCatalog
|
||||
{
|
||||
private static readonly Dictionary<string, PlanInfo> Plans = new()
|
||||
{
|
||||
["basis"] = new PlanInfo(
|
||||
Key: "basis",
|
||||
Name: "Basis",
|
||||
UserRange: "1-3 brugere",
|
||||
PricePerMonth: 0,
|
||||
BadgeText: "Gratis",
|
||||
BadgeClass: "free",
|
||||
BadgeIcon: "ph-gift",
|
||||
Features: new List<string>
|
||||
{
|
||||
"Op til 3 brugere",
|
||||
"Online booking",
|
||||
"Kalender & aftalestyring",
|
||||
"Kundekartotek",
|
||||
"SMS-påmindelser"
|
||||
},
|
||||
RequiresPayment: false,
|
||||
IsContactSales: false
|
||||
),
|
||||
|
||||
["pro"] = new PlanInfo(
|
||||
Key: "pro",
|
||||
Name: "Pro",
|
||||
UserRange: "4-8 brugere",
|
||||
PricePerMonth: 599,
|
||||
BadgeText: "Mest populære",
|
||||
BadgeClass: "popular",
|
||||
BadgeIcon: "ph-star",
|
||||
Features: new List<string>
|
||||
{
|
||||
"Op til 8 brugere",
|
||||
"Alt fra Basis",
|
||||
"Lagerstyring",
|
||||
"Avancerede rapporter",
|
||||
"Gavekort & klippekort",
|
||||
"Prioriteret support"
|
||||
},
|
||||
RequiresPayment: true,
|
||||
IsContactSales: false
|
||||
),
|
||||
|
||||
["enterprise"] = new PlanInfo(
|
||||
Key: "enterprise",
|
||||
Name: "Enterprise",
|
||||
UserRange: "8+ brugere",
|
||||
PricePerMonth: null,
|
||||
BadgeText: "Enterprise",
|
||||
BadgeClass: "enterprise",
|
||||
BadgeIcon: "ph-buildings",
|
||||
Features: new List<string>
|
||||
{
|
||||
"Ubegrænset antal brugere",
|
||||
"Alt fra Pro",
|
||||
"Flere lokationer",
|
||||
"Tilpasset integration",
|
||||
"Dedikeret kontaktperson",
|
||||
"SLA & uptime garanti"
|
||||
},
|
||||
RequiresPayment: false,
|
||||
IsContactSales: true
|
||||
)
|
||||
};
|
||||
|
||||
public static PlanInfo GetPlan(string key)
|
||||
{
|
||||
if (Plans.TryGetValue(key.ToLowerInvariant(), out var plan))
|
||||
return plan;
|
||||
|
||||
// Default to Pro if invalid key
|
||||
return Plans["pro"];
|
||||
}
|
||||
|
||||
public static IEnumerable<PlanInfo> GetAllPlans() => Plans.Values;
|
||||
|
||||
public static PlanInfo Basis => Plans["basis"];
|
||||
public static PlanInfo Pro => Plans["pro"];
|
||||
public static PlanInfo Enterprise => Plans["enterprise"];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue