improvement: account setting added to header in order to choose organizations/subscribtions/etc

This commit is contained in:
2026-04-29 21:55:46 +03:30
parent ca9e684ab4
commit 7a847d5326
12 changed files with 517 additions and 82 deletions

View File

@@ -218,7 +218,13 @@ export function AuthProvider({ children }: { children: React.ReactNode }) {
localStorage.setItem('currentOrganizationId', organization.id);
setCurrentOrganization(organization);
setCurrentOrganization({
id: organization.id,
name: organization.name,
type: organization.type as Organization['type'],
isOwner: Boolean((organization as { isOwner?: boolean }).isOwner),
plan: (organization as { plan?: Organization['plan'] }).plan,
});
router.push('/today');