File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ import BudgetLimitAlert from '$routes/(console)/organization-[organization]/budg
4141import TeamReadonlyAlert from '$routes/(console)/organization-[organization]/teamReadonlyAlert.svelte' ;
4242import ProjectsLimit from '$lib/components/billing/alerts/projectsLimit.svelte' ;
4343import EnterpriseTrial from '$routes/(console)/organization-[organization]/enterpriseTrial.svelte' ;
44+ import { ProfileMode , resolvedProfile } from '$lib/profiles/index.svelte' ;
4445
4546export type Tier = 'tier-0' | 'tier-1' | 'tier-2' | 'auto-1' | 'cont-1' | 'ent-1' ;
4647
@@ -572,6 +573,8 @@ export async function checkForMissingPaymentMethod() {
572573
573574// Display upgrade banner for new users after 1 week for 30 days
574575export async function checkForNewDevUpgradePro ( org : Organization ) {
576+ if ( resolvedProfile . id !== ProfileMode . CONSOLE ) return ;
577+
575578 // browser or plan check.
576579 if ( ! browser || org ?. billingPlan !== BillingPlan . FREE ) return ;
577580
Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ import BackupDatabase from '$lib/components/backupDatabaseAlert.svelte';
77import { shouldShowNotification } from '$lib/helpers/notifications' ;
88import { isCloud } from '$lib/system' ;
99import { currentPlan } from '$lib/stores/organization' ;
10+ import { ProfileMode , resolvedProfile } from '$lib/profiles/index.svelte' ;
1011
1112export const database = derived ( page , ( $page ) => $page . data ?. database as Models . Database ) ;
1213
@@ -19,7 +20,10 @@ export async function checkForDatabaseBackupPolicies(
1920 projectId : string ,
2021 database : Models . Database
2122) {
22- // fast path: return if user dismissed the banner
23+ // fast path: not the valid profile to show this!
24+ if ( resolvedProfile . id !== ProfileMode . CONSOLE ) return ;
25+
26+ // fast path: return if user dismissed the banner.
2327 if ( ! shouldShowNotification ( backupsBannerId ) ) return ;
2428
2529 let total = 0 ;
Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ import { isSameDay } from '$lib/helpers/date';
33import { type BottomModalAlertItem , showBottomModalAlert } from '$lib/stores/bottom-alerts' ;
44import DbOperatorsDark from '$lib/images/promos/db-operators-dark.png' ;
55import DbOperatorsLight from '$lib/images/promos/db-operators-light.png' ;
6+ import { ProfileMode , resolvedProfile } from '$lib/profiles/index.svelte' ;
67
78const listOfPromotions : BottomModalAlertItem [ ] = [ ] ;
89
@@ -30,6 +31,9 @@ if (isCloud) {
3031}
3132
3233export function addBottomModalAlerts ( ) {
34+ // fast path: not the valid profile to show this!
35+ if ( resolvedProfile . id !== ProfileMode . CONSOLE ) return ;
36+
3337 listOfPromotions . forEach ( ( promotion ) => showBottomModalAlert ( promotion ) ) ;
3438}
3539
You can’t perform that action at this time.
0 commit comments