From 90d6cd40e6d50c85bf78f421489dee2624b0baae Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Thu, 10 Apr 2025 03:52:32 +0000 Subject: [PATCH 1/3] Feat: budget cap config update --- src/lib/sdk/billing.ts | 1 + .../billing/budgetAlert.svelte | 10 ++++++++++ .../billing/budgetCap.svelte | 10 ++++++++++ 3 files changed, 21 insertions(+) diff --git a/src/lib/sdk/billing.ts b/src/lib/sdk/billing.ts index e18ef961a..340ed985d 100644 --- a/src/lib/sdk/billing.ts +++ b/src/lib/sdk/billing.ts @@ -340,6 +340,7 @@ export type Plan = { seats: PlanAddon; }; trialDays: number; + budgetCapEnabled: boolean; isAvailable: boolean; selfService: boolean; premiumSupport: boolean; diff --git a/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte b/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte index 07a5db67a..011e0906d 100644 --- a/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte +++ b/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte @@ -102,6 +102,16 @@ Upgrade to a Pro plan to manage when you receive billing alerts for your organization. + {:else if !$currentPlan.budgetCapEnabled} + + Billing alerts disabled + Billing alerts are disabled for your current plan. For more information + view our pricing guide. + {:else} diff --git a/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte b/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte index 479886016..1db4f9fd3 100644 --- a/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte +++ b/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte @@ -71,6 +71,16 @@ target="_blank" rel="noopener noreferrer">view our pricing guide. + {:else if !$currentPlan.budgetCapEnabled} + + Budget cap disabled + Budget caps are disabled for your current plan. For more information + view our pricing guide. + {:else} From 8d6c993e164c77926d0f291830499d1a40354fa4 Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Thu, 10 Apr 2025 04:06:17 +0000 Subject: [PATCH 2/3] update alert --- .../billing/budgetAlert.svelte | 9 ++------- .../organization-[organization]/billing/budgetCap.svelte | 7 +------ 2 files changed, 3 insertions(+), 13 deletions(-) diff --git a/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte b/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte index 011e0906d..40798d640 100644 --- a/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte +++ b/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte @@ -104,13 +104,8 @@ {:else if !$currentPlan.budgetCapEnabled} - Billing alerts disabled - Billing alerts are disabled for your current plan. For more information - view our pricing guide. + Budget cap disabled + Budget caps are not supported on your current plan. For more information, please reach out to your customer success manager. {:else} diff --git a/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte b/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte index 1db4f9fd3..e8e20cadc 100644 --- a/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte +++ b/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte @@ -74,12 +74,7 @@ {:else if !$currentPlan.budgetCapEnabled} Budget cap disabled - Budget caps are disabled for your current plan. For more information - view our pricing guide. + Budget caps are not supported on your current plan. For more information, please reach out to your customer success manager. {:else} From 6b45f9dae055ee981730d46ac48a9ffe2f80678f Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Thu, 10 Apr 2025 04:08:42 +0000 Subject: [PATCH 3/3] fix format --- .../organization-[organization]/billing/budgetAlert.svelte | 3 ++- .../organization-[organization]/billing/budgetCap.svelte | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte b/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte index 40798d640..b916004eb 100644 --- a/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte +++ b/src/routes/(console)/organization-[organization]/billing/budgetAlert.svelte @@ -105,7 +105,8 @@ {:else if !$currentPlan.budgetCapEnabled} Budget cap disabled - Budget caps are not supported on your current plan. For more information, please reach out to your customer success manager. + Budget caps are not supported on your current plan. For more information, please + reach out to your customer success manager. {:else} diff --git a/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte b/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte index e8e20cadc..88890c45d 100644 --- a/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte +++ b/src/routes/(console)/organization-[organization]/billing/budgetCap.svelte @@ -74,7 +74,8 @@ {:else if !$currentPlan.budgetCapEnabled} Budget cap disabled - Budget caps are not supported on your current plan. For more information, please reach out to your customer success manager. + Budget caps are not supported on your current plan. For more information, please + reach out to your customer success manager. {:else}