40 remove self billing feature flag (#4379)
* Define quantity at checkout * Remove billing submenu when not isBillingEnabled * Remove feature flag * Log warning when missing subscription active workspace add or remove member * Display subscribe cta for free usage of twenty * Authorize all settings when subscription canceled or unpaid * Display subscribe cta for workspace with canceled subscription * Replace OneToOne by OneToMany * Add a currentBillingSubscriptionField * Handle multiple subscriptions by workspace * Fix redirection * Fix test * Fix billingState
This commit is contained in:
@ -93,7 +93,10 @@ export const PageChangeEffect = () => {
|
||||
[OnboardingStatus.Unpaid, OnboardingStatus.Canceled].includes(
|
||||
onboardingStatus,
|
||||
) &&
|
||||
!isMatchingLocation(SettingsPath.Billing)
|
||||
!(
|
||||
isMatchingLocation(AppPath.SettingsCatchAll) ||
|
||||
isMatchingLocation(AppPath.PlanRequired)
|
||||
)
|
||||
) {
|
||||
navigate(
|
||||
`${AppPath.SettingsCatchAll.replace('/*', '')}/${SettingsPath.Billing}`,
|
||||
@ -110,7 +113,8 @@ export const PageChangeEffect = () => {
|
||||
) {
|
||||
navigate(AppPath.CreateProfile);
|
||||
} else if (
|
||||
onboardingStatus === OnboardingStatus.Completed &&
|
||||
(onboardingStatus === OnboardingStatus.Completed ||
|
||||
onboardingStatus === OnboardingStatus.CompletedWithoutSubscription) &&
|
||||
isMatchingOnboardingRoute
|
||||
) {
|
||||
navigate(AppPath.Index);
|
||||
|
||||
Reference in New Issue
Block a user