refactor(workspace, users, billing): remove default workspace + rename (#9360)

Replaced user-based parameterization with workspace-focused logic across
seed scripts, mocks, and billing services. Removed redundant `user`
references and standardized to `workspace` to align with updated
business rules. Adjusted mock data and tests to reflect these changes.

Fix https://github.com/twentyhq/twenty/issues/9295
This commit is contained in:
Antoine Moreaux
2025-01-06 12:33:57 +01:00
committed by GitHub
parent 25083e5405
commit 3eb7ec909e
12 changed files with 35 additions and 51 deletions

View File

@ -13,7 +13,7 @@ import { ObjectMetadataItemsDecorator } from '~/testing/decorators/ObjectMetadat
import { SnackBarDecorator } from '~/testing/decorators/SnackBarDecorator';
import { graphqlMocks } from '~/testing/graphqlMocks';
import {
mockDefaultWorkspace,
mockCurrentWorkspace,
mockedWorkspaceMemberData,
} from '~/testing/mock-data/users';
@ -26,7 +26,7 @@ const RelationWorkspaceSetterEffect = () => {
);
useEffect(() => {
setCurrentWorkspace(mockDefaultWorkspace);
setCurrentWorkspace(mockCurrentWorkspace);
setCurrentWorkspaceMember(mockedWorkspaceMemberData);
}, [setCurrentWorkspace, setCurrentWorkspaceMember]);

View File

@ -13,7 +13,7 @@ import { ObjectMetadataItemsDecorator } from '~/testing/decorators/ObjectMetadat
import { SnackBarDecorator } from '~/testing/decorators/SnackBarDecorator';
import { graphqlMocks } from '~/testing/graphqlMocks';
import {
mockDefaultWorkspace,
mockCurrentWorkspace,
mockedWorkspaceMemberData,
} from '~/testing/mock-data/users';
@ -32,7 +32,7 @@ const RelationWorkspaceSetterEffect = () => {
);
useEffect(() => {
setCurrentWorkspace(mockDefaultWorkspace);
setCurrentWorkspace(mockCurrentWorkspace);
setCurrentWorkspaceMember(mockedWorkspaceMemberData);
}, [setCurrentWorkspace, setCurrentWorkspaceMember]);