Skip to content

Commit a306071

Browse files
authored
Merge pull request #2172 from appwrite/fix-projects-selection
2 parents ccce9f6 + 16b3afa commit a306071

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

src/lib/components/billing/alerts/selectProjectCloud.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
let error = $state<string | null>(null);
2525
2626
onMount(() => {
27-
projects = page.data.projects?.projects || [];
27+
projects = page.data.allProjects?.projects || [];
2828
});
2929
3030
let projectsToArchive = $derived(

src/routes/(console)/+layout.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@
297297
if (currentOrganizationId === org.$id) return;
298298
if (isCloud) {
299299
currentOrganizationId = org.$id;
300-
checkForProjectsLimit(org, data.projects?.projects?.length || 0);
300+
checkForProjectsLimit(org, data.allProjects?.projects?.length || 0);
301301
checkForEnterpriseTrial(org);
302302
await checkForUsageLimit(org);
303303
checkForMarkedForDeletion(org);

src/routes/(console)/+layout.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export const load: LayoutLoad = async ({ depends, parent }) => {
5555
organizations,
5656
consoleVariables,
5757
version: versionData?.version ?? null,
58-
projects
58+
allProjects: projects
5959
};
6060
};
6161

src/routes/(console)/organization-[organization]/+page.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@
164164
</DropList>
165165
</div>
166166

167-
{#if isCloud && $currentPlan?.projects && $currentPlan?.projects > 0 && data.organization.projects.length > 0 && $canWriteProjects}
167+
{#if isCloud && $currentPlan?.projects && $currentPlan?.projects > 0 && data.organization.projects.length > 0 && data.projects.total > 2 && $canWriteProjects}
168168
<Alert.Inline
169169
title={`${data.projects.total - data.organization.projects.length} projects will be archived on ${toLocaleDate(billingProjectsLimitDate)}`}>
170170
<Typography.Text>

0 commit comments

Comments
 (0)