mirror of
https://github.com/twentyhq/twenty
synced 2026-04-21 13:37:22 +00:00
[BREAKING_CHANGE] Deprecate remaining entities standardId (#17639)
# Introduction Following https://github.com/twentyhq/twenty/pull/17632 and https://github.com/twentyhq/twenty/pull/17572 This PR deprecates the agent, skill, field metadata and role `standardId` in favor of the `universalIdentifier` usage ## Note - Removed previous standard ids declaration modules - Twenty-sdk now re-exports the `STANDARD_OBJECTS` universalIdentifier hashmap constant - deleted some sync-metadata deadcode too ( mainly types )
This commit is contained in:
parent
cfdcc0065c
commit
d35d5c0463
118 changed files with 534 additions and 2279 deletions
|
|
@ -22,25 +22,51 @@ Examples of existing syncable entities: `skill`, `agent`, `view`, `viewField`, `
|
|||
|
||||
## Table of Contents
|
||||
|
||||
1. [Overview](#overview)
|
||||
2. [File Structure](#file-structure)
|
||||
3. [Step-by-Step Implementation](#step-by-step-implementation)
|
||||
- [Step 1: Add Metadata Name Constant](#step-1-add-metadata-name-constant-twenty-shared)
|
||||
- [Step 2: Create TypeORM Entity](#step-2-create-typeorm-entity)
|
||||
- [Step 2b: Using JsonbProperty and SerializedRelation Types](#step-2b-using-jsonbproperty-and-serializedrelation-types)
|
||||
- [Step 3: Define Flat Entity Type](#step-3-define-flat-entity-type)
|
||||
- [Step 4: Define Editable Properties](#step-4-define-editable-properties)
|
||||
- [Step 5: Register in Central Constants](#step-5-register-in-central-constants)
|
||||
- [Step 6: Create Cache Service](#step-6-create-cache-service)
|
||||
- [Step 7: Create Flat Entity Module](#step-7-create-flat-entity-module)
|
||||
- [Step 8: Define Action Types](#step-8-define-action-types)
|
||||
- [Step 9: Create Validator Service](#step-9-create-validator-service)
|
||||
- [Step 10: Create Builder Service](#step-10-create-builder-service)
|
||||
- [Step 11: Create Action Handlers](#step-11-create-action-handlers-runner)
|
||||
- [Step 12: Wire in Orchestrator Service](#step-12-wire-in-orchestrator-service-critical)
|
||||
- [Step 13: Register in Modules](#step-13-register-in-modules)
|
||||
4. [Using the Entity in Services](#using-the-entity-in-services)
|
||||
5. [Integration Tests](#integration-tests)
|
||||
- [Creating a New Syncable Entity](#creating-a-new-syncable-entity)
|
||||
- [What is a Syncable Entity?](#what-is-a-syncable-entity)
|
||||
- [Table of Contents](#table-of-contents)
|
||||
- [Overview](#overview)
|
||||
- [Key Design Principle: Separation of Concerns](#key-design-principle-separation-of-concerns)
|
||||
- [File Structure](#file-structure)
|
||||
- [Step-by-Step Implementation](#step-by-step-implementation)
|
||||
- [Step 1: Add Metadata Name Constant (twenty-shared)](#step-1-add-metadata-name-constant-twenty-shared)
|
||||
- [Step 2: Create TypeORM Entity](#step-2-create-typeorm-entity)
|
||||
- [Step 2b: Using JsonbProperty and SerializedRelation Types](#step-2b-using-jsonbproperty-and-serializedrelation-types)
|
||||
- [JsonbProperty Wrapper](#jsonbproperty-wrapper)
|
||||
- [SerializedRelation Type](#serializedrelation-type)
|
||||
- [Complete Example](#complete-example)
|
||||
- [Step 3: Define Flat Entity Type](#step-3-define-flat-entity-type)
|
||||
- [Step 4: Define Editable Properties](#step-4-define-editable-properties)
|
||||
- [Step 5: Register in Central Constants](#step-5-register-in-central-constants)
|
||||
- [5a. All Flat Entity Types Registry](#5a-all-flat-entity-types-registry)
|
||||
- [5b. Properties to Compare and Stringify](#5b-properties-to-compare-and-stringify)
|
||||
- [5c. Metadata Relations](#5c-metadata-relations)
|
||||
- [5d. Required Metadata for Validation](#5d-required-metadata-for-validation)
|
||||
- [Step 6: Create Cache Service](#step-6-create-cache-service)
|
||||
- [Step 7: Create Flat Entity Module](#step-7-create-flat-entity-module)
|
||||
- [Step 8: Define Action Types](#step-8-define-action-types)
|
||||
- [Step 9: Create Validator Service](#step-9-create-validator-service)
|
||||
- [Step 10: Create Builder Service](#step-10-create-builder-service)
|
||||
- [Step 11: Create Action Handlers (Runner)](#step-11-create-action-handlers-runner)
|
||||
- [Step 12: Wire in Orchestrator Service (CRITICAL)](#step-12-wire-in-orchestrator-service-critical)
|
||||
- [Step 13: Register in Modules](#step-13-register-in-modules)
|
||||
- [13a. Builder Module](#13a-builder-module)
|
||||
- [13b. Validators Module](#13b-validators-module)
|
||||
- [13c. Action Handlers Module](#13c-action-handlers-module)
|
||||
- [Using the Entity in Services](#using-the-entity-in-services)
|
||||
- [Integration Tests](#integration-tests)
|
||||
- [Checklist](#checklist)
|
||||
- [Syncable Entity Requirements](#syncable-entity-requirements)
|
||||
- [JSONB Properties and Serialized Relations](#jsonb-properties-and-serialized-relations)
|
||||
- [Registration (twenty-shared)](#registration-twenty-shared)
|
||||
- [Flat Entity Definition](#flat-entity-definition)
|
||||
- [Central Constants Registration](#central-constants-registration)
|
||||
- [Cache Layer](#cache-layer)
|
||||
- [Migration Builder](#migration-builder)
|
||||
- [Migration Runner](#migration-runner)
|
||||
- [Orchestrator Wiring (⚠️ COMMONLY FORGOTTEN)](#orchestrator-wiring-️-commonly-forgotten)
|
||||
- [Module Registration](#module-registration)
|
||||
- [Testing](#testing)
|
||||
|
||||
---
|
||||
|
||||
|
|
@ -177,9 +203,6 @@ export class MyEntityEntity
|
|||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@Column({ nullable: true, type: 'uuid' })
|
||||
standardId: string | null;
|
||||
|
||||
@Column({ nullable: false })
|
||||
name: string;
|
||||
|
||||
|
|
@ -345,9 +368,6 @@ export class WidgetEntity extends SyncableEntity implements Required<WidgetEntit
|
|||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@Column({ nullable: true, type: 'uuid' })
|
||||
standardId: string | null;
|
||||
|
||||
@Column({ nullable: false })
|
||||
name: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ export class PostCard {
|
|||
label: 'Notes',
|
||||
icon: 'IconComment',
|
||||
inverseSideTargetUniversalIdentifier:
|
||||
STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS.note,
|
||||
STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS.note.universalIdentifier,
|
||||
onDelete: OnDeleteAction.CASCADE,
|
||||
})
|
||||
notes: Note[];
|
||||
|
|
|
|||
|
|
@ -70,7 +70,6 @@ export type Agent = {
|
|||
prompt: Scalars['String'];
|
||||
responseFormat?: Maybe<Scalars['JSON']>;
|
||||
roleId?: Maybe<Scalars['UUID']>;
|
||||
standardId?: Maybe<Scalars['UUID']>;
|
||||
updatedAt: Scalars['DateTime'];
|
||||
};
|
||||
|
||||
|
|
@ -4101,7 +4100,6 @@ export type Role = {
|
|||
permissionFlags?: Maybe<Array<PermissionFlag>>;
|
||||
rowLevelPermissionPredicateGroups?: Maybe<Array<RowLevelPermissionPredicateGroup>>;
|
||||
rowLevelPermissionPredicates?: Maybe<Array<RowLevelPermissionPredicate>>;
|
||||
standardId?: Maybe<Scalars['UUID']>;
|
||||
universalIdentifier?: Maybe<Scalars['UUID']>;
|
||||
workspaceMembers: Array<WorkspaceMember>;
|
||||
};
|
||||
|
|
@ -4306,7 +4304,6 @@ export type Skill = {
|
|||
isCustom: Scalars['Boolean'];
|
||||
label: Scalars['String'];
|
||||
name: Scalars['String'];
|
||||
standardId?: Maybe<Scalars['UUID']>;
|
||||
updatedAt: Scalars['DateTime'];
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -70,7 +70,6 @@ export type Agent = {
|
|||
prompt: Scalars['String'];
|
||||
responseFormat?: Maybe<Scalars['JSON']>;
|
||||
roleId?: Maybe<Scalars['UUID']>;
|
||||
standardId?: Maybe<Scalars['UUID']>;
|
||||
updatedAt: Scalars['DateTime'];
|
||||
};
|
||||
|
||||
|
|
@ -3940,7 +3939,6 @@ export type Role = {
|
|||
permissionFlags?: Maybe<Array<PermissionFlag>>;
|
||||
rowLevelPermissionPredicateGroups?: Maybe<Array<RowLevelPermissionPredicateGroup>>;
|
||||
rowLevelPermissionPredicates?: Maybe<Array<RowLevelPermissionPredicate>>;
|
||||
standardId?: Maybe<Scalars['UUID']>;
|
||||
universalIdentifier?: Maybe<Scalars['UUID']>;
|
||||
workspaceMembers: Array<WorkspaceMember>;
|
||||
};
|
||||
|
|
@ -4145,7 +4143,6 @@ export type Skill = {
|
|||
isCustom: Scalars['Boolean'];
|
||||
label: Scalars['String'];
|
||||
name: Scalars['String'];
|
||||
standardId?: Maybe<Scalars['UUID']>;
|
||||
updatedAt: Scalars['DateTime'];
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
export { STANDARD_OBJECT_IDS as STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS } from 'twenty-shared/metadata';
|
||||
export { STANDARD_OBJECTS as STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS } from 'twenty-shared/metadata';
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import { InjectDataSource, InjectRepository } from '@nestjs/typeorm';
|
||||
|
||||
import { Command } from 'nest-commander';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
import {
|
||||
FieldMetadataType,
|
||||
type FieldMetadataSettings,
|
||||
|
|
@ -28,9 +29,7 @@ import { WorkspaceCacheStorageService } from 'src/engine/workspace-cache-storage
|
|||
import { WorkspaceCacheService } from 'src/engine/workspace-cache/services/workspace-cache.service';
|
||||
import { type WorkspaceCacheKeyName } from 'src/engine/workspace-cache/types/workspace-cache-key.type';
|
||||
import { getWorkspaceSchemaName } from 'src/engine/workspace-datasource/utils/get-workspace-schema-name.util';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { TWENTY_STANDARD_APPLICATION } from 'src/engine/workspace-manager/twenty-standard-application/constants/twenty-standard-applications';
|
||||
import { ATTACHMENT_STANDARD_FIELD_IDS } from 'src/engine/workspace-manager/workspace-migration/constant/standard-field-ids';
|
||||
|
||||
type RelationFieldMetadataSettings =
|
||||
FieldMetadataSettings<FieldMetadataType.RELATION>;
|
||||
|
|
@ -199,7 +198,8 @@ export class MigrateAttachmentToMorphRelationsCommand extends ActiveOrSuspendedW
|
|||
|
||||
this.logger.log(`✅ Successfully migrated attachment records`);
|
||||
|
||||
const morphId = ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId;
|
||||
const morphId =
|
||||
STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId;
|
||||
|
||||
for (const {
|
||||
field: fieldToMigrate,
|
||||
|
|
|
|||
|
|
@ -0,0 +1,31 @@
|
|||
import { type MigrationInterface, type QueryRunner } from 'typeorm';
|
||||
|
||||
export class DropStandardIdFromCoreEntities1770047816358
|
||||
implements MigrationInterface
|
||||
{
|
||||
name = 'DropStandardIdFromCoreEntities1770047816358';
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "core"."agent" DROP COLUMN "standardId"`,
|
||||
);
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "core"."role" DROP COLUMN "standardId"`,
|
||||
);
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "core"."fieldMetadata" DROP COLUMN "standardId"`,
|
||||
);
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "core"."skill" DROP COLUMN "standardId"`,
|
||||
);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE "core"."skill" ADD "standardId" uuid`);
|
||||
await queryRunner.query(
|
||||
`ALTER TABLE "core"."fieldMetadata" ADD "standardId" uuid`,
|
||||
);
|
||||
await queryRunner.query(`ALTER TABLE "core"."role" ADD "standardId" uuid`);
|
||||
await queryRunner.query(`ALTER TABLE "core"."agent" ADD "standardId" uuid`);
|
||||
}
|
||||
}
|
||||
|
|
@ -471,7 +471,6 @@ export class ApplicationSyncService {
|
|||
isNullable: fieldToCreate.isNullable ?? true,
|
||||
objectMetadataId: objectId,
|
||||
universalIdentifier: fieldToCreate.universalIdentifier,
|
||||
standardId: fieldToCreate.universalIdentifier,
|
||||
applicationId: ownerFlatApplication.id,
|
||||
isCustom: true,
|
||||
workspaceId,
|
||||
|
|
@ -545,7 +544,6 @@ export class ApplicationSyncService {
|
|||
icon: relation.icon ?? undefined,
|
||||
objectMetadataId: objectId,
|
||||
universalIdentifier: relation.universalIdentifier,
|
||||
standardId: relation.universalIdentifier,
|
||||
applicationId: ownerFlatApplication.id,
|
||||
isCustom: true,
|
||||
workspaceId,
|
||||
|
|
@ -677,7 +675,6 @@ export class ApplicationSyncService {
|
|||
labelPlural: objectToCreate.labelPlural,
|
||||
icon: objectToCreate.icon || undefined,
|
||||
description: objectToCreate.description || undefined,
|
||||
standardId: objectToCreate.universalIdentifier,
|
||||
dataSourceId: dataSourceMetadata.id,
|
||||
universalIdentifier: objectToCreate.universalIdentifier,
|
||||
applicationId: ownerFlatApplication.id,
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
import deepEqual from 'deep-equal';
|
||||
import { FieldMetadataType, type ObjectRecord } from 'twenty-shared/types';
|
||||
import { fastDeepEqual } from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatEntityMaps } from 'src/engine/metadata-modules/flat-entity/types/flat-entity-maps.type';
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { buildFieldMapsFromFlatObjectMetadata } from 'src/engine/metadata-modules/flat-field-metadata/utils/build-field-maps-from-flat-object-metadata.util';
|
||||
import { type FlatObjectMetadata } from 'src/engine/metadata-modules/flat-object-metadata/types/flat-object-metadata.type';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
const LARGE_JSON_FIELDS: Record<string, Set<string>> = {
|
||||
[STANDARD_OBJECTS.workflowVersion.universalIdentifier]: new Set([
|
||||
|
|
|
|||
|
|
@ -20,9 +20,6 @@ export class AgentDTO {
|
|||
@Field(() => UUIDScalarType)
|
||||
id: string;
|
||||
|
||||
@Field(() => UUIDScalarType, { nullable: true })
|
||||
standardId?: string | null;
|
||||
|
||||
@IsString()
|
||||
@Field()
|
||||
name: string;
|
||||
|
|
|
|||
|
|
@ -15,9 +15,9 @@ import GraphQLJSON from 'graphql-type-json';
|
|||
import { UUIDScalarType } from 'src/engine/api/graphql/workspace-schema-builder/graphql-types/scalars';
|
||||
import { AgentResponseFormat } from 'src/engine/metadata-modules/ai/ai-agent/types/agent-response-format.type';
|
||||
import { ModelConfiguration } from 'src/engine/metadata-modules/ai/ai-agent/types/modelConfiguration';
|
||||
import { ModelId } from 'src/engine/metadata-modules/ai/ai-models/constants/ai-models.const';
|
||||
import { AgentResponseFormatJson } from 'src/engine/metadata-modules/ai/ai-agent/validators/agent-response-format-json.validator';
|
||||
import { AgentResponseFormatText } from 'src/engine/metadata-modules/ai/ai-agent/validators/agent-response-format-text.validator';
|
||||
import { ModelId } from 'src/engine/metadata-modules/ai/ai-models/constants/ai-models.const';
|
||||
|
||||
@InputType()
|
||||
export class CreateAgentInput {
|
||||
|
|
@ -82,9 +82,6 @@ export class CreateAgentInput {
|
|||
@Field(() => [String], { nullable: true })
|
||||
evaluationInputs?: string[];
|
||||
|
||||
@HideField()
|
||||
standardId?: string;
|
||||
|
||||
@HideField()
|
||||
applicationId?: string;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,9 +30,6 @@ export class AgentEntity
|
|||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@Column({ nullable: true, type: 'uuid' })
|
||||
standardId: string | null;
|
||||
|
||||
@Column({ nullable: false })
|
||||
name: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { isWorkflowRelatedObject } from 'src/engine/metadata-modules/ai/ai-agent/utils/is-workflow-related-object.util';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
describe('isWorkflowRelatedObject', () => {
|
||||
it('should return true for workflow-related objects', () => {
|
||||
|
|
|
|||
|
|
@ -32,7 +32,6 @@ export const fromCreateAgentInputToFlatAgent = ({
|
|||
'description',
|
||||
'prompt',
|
||||
'modelId',
|
||||
'standardId',
|
||||
'applicationId',
|
||||
'roleId',
|
||||
],
|
||||
|
|
@ -40,12 +39,9 @@ export const fromCreateAgentInputToFlatAgent = ({
|
|||
|
||||
const createdAt = new Date().toISOString();
|
||||
const agentId = v4();
|
||||
const standardId = createAgentInput.standardId ?? null;
|
||||
const universalIdentifier = standardId ?? agentId;
|
||||
|
||||
const flatAgentToCreate: FlatAgent = {
|
||||
id: agentId,
|
||||
standardId,
|
||||
name: isNonEmptyString(createAgentInput.name)
|
||||
? createAgentInput.name
|
||||
: computeMetadataNameFromLabel({ label: createAgentInput.label }),
|
||||
|
|
@ -57,7 +53,7 @@ export const fromCreateAgentInputToFlatAgent = ({
|
|||
responseFormat: createAgentInput.responseFormat ?? { type: 'text' },
|
||||
workspaceId,
|
||||
isCustom: true,
|
||||
universalIdentifier,
|
||||
universalIdentifier: v4(),
|
||||
applicationId: createAgentInput.applicationId,
|
||||
modelConfiguration: createAgentInput.modelConfiguration ?? null,
|
||||
evaluationInputs: createAgentInput.evaluationInputs ?? [],
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
// All workflow-related standard object IDs that should be filtered out from agent access
|
||||
const WORKFLOW_STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS = [
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
// All workflow-related standard object IDs that should be filtered out from agent access
|
||||
const WORKFLOW_STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS = [
|
||||
|
|
|
|||
|
|
@ -28,9 +28,6 @@ export class CreateFieldInput extends OmitType(
|
|||
@HideField()
|
||||
universalIdentifier?: string;
|
||||
|
||||
@HideField()
|
||||
standardId?: string;
|
||||
|
||||
@HideField()
|
||||
applicationId?: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -64,9 +64,6 @@ export class FieldMetadataEntity<
|
|||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@Column({ nullable: true, type: 'uuid' })
|
||||
standardId: string | null;
|
||||
|
||||
@Column({ nullable: false, type: 'uuid' })
|
||||
objectMetadataId: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@ export const fromFlatAgentWithRoleIdToAgentDto = ({
|
|||
name,
|
||||
prompt,
|
||||
responseFormat,
|
||||
standardId,
|
||||
updatedAt,
|
||||
workspaceId,
|
||||
roleId,
|
||||
|
|
@ -31,7 +30,6 @@ export const fromFlatAgentWithRoleIdToAgentDto = ({
|
|||
name,
|
||||
prompt,
|
||||
responseFormat,
|
||||
standardId,
|
||||
updatedAt: new Date(updatedAt),
|
||||
workspaceId,
|
||||
applicationId: applicationId ?? undefined,
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@ export const transformAgentEntityToFlatAgent = ({
|
|||
deletedAt: agentEntity.deletedAt?.toISOString() ?? null,
|
||||
updatedAt: agentEntity.updatedAt.toISOString(),
|
||||
id: agentEntity.id,
|
||||
standardId: agentEntity.standardId,
|
||||
name: agentEntity.name,
|
||||
label: agentEntity.label,
|
||||
icon: agentEntity.icon,
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import { type MetadataEntity } from 'src/engine/metadata-modules/flat-entity/typ
|
|||
|
||||
type ExtractRelationIdProperties<T> = {
|
||||
[K in keyof T]: K extends `${infer _}Id`
|
||||
? K extends 'id' | 'workspaceId' | 'standardId'
|
||||
? K extends 'id' | 'workspaceId'
|
||||
? never
|
||||
: T[K] extends string | null | undefined
|
||||
? K
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: 'f51cfa5d-7190-48a5-b548-3e542322c144',
|
||||
standardId: '20202020-87a5-48f8-bbf7-ade388825a57',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -36,7 +35,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
fullPath: getFlatFieldMetadataMock({
|
||||
id: '38207e43-a958-4058-bc32-36f838d102d3',
|
||||
standardId: '20202020-0d19-453d-8e8d-fbcda8ca3747',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'fullPath',
|
||||
|
|
@ -60,7 +58,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
type: getFlatFieldMetadataMock({
|
||||
id: '840360e7-efa6-4ca2-a0d6-113b79474b98',
|
||||
standardId: '20202020-a417-49b8-a40b-f6a7874caa0d',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'type',
|
||||
|
|
@ -84,7 +81,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '8662ced6-5e48-4576-993f-1be479dba176',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -108,7 +104,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '367923d5-658b-4b7b-9381-6f8e6cf84c85',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -132,7 +127,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: 'b81f8f1b-4173-4176-bc3c-fe1b6a45a0dc',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -156,7 +150,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'eab57da6-41ae-45e8-a5ee-014cfcab450f',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -180,7 +173,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
author: getFlatFieldMetadataMock({
|
||||
id: '99724bb6-7a84-4b54-9b3f-dab730ab445a',
|
||||
standardId: '20202020-6501-4ac5-a4ef-b2f8522ef6cd',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'author',
|
||||
|
|
@ -208,7 +200,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
task: getFlatFieldMetadataMock({
|
||||
id: 'bd823f17-f923-4f0d-8533-51d7bc062975',
|
||||
standardId: '20202020-51e5-4621-9cf8-215487951c4b',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'task',
|
||||
|
|
@ -236,7 +227,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
note: getFlatFieldMetadataMock({
|
||||
id: '5a98eb2b-1120-42e3-afd3-09d7da642fba',
|
||||
standardId: '20202020-4f4b-4503-a6fc-6b982f3dffb5',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'note',
|
||||
|
|
@ -264,7 +254,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
person: getFlatFieldMetadataMock({
|
||||
id: '6938c2ec-ebcc-4f30-8d38-2c9c40228c53',
|
||||
standardId: '20202020-0158-4aa2-965c-5cdafe21ffa2',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'person',
|
||||
|
|
@ -292,7 +281,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: '0bacf73b-f45b-4683-85b4-3e812e6228bf',
|
||||
standardId: '20202020-ceab-4a28-b546-73b06b4c08d5',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -320,7 +308,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
opportunity: getFlatFieldMetadataMock({
|
||||
id: 'da72fbe2-a5aa-42b5-b6bd-482a3919eb20',
|
||||
standardId: '20202020-7374-499d-bea3-9354890755b5',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'opportunity',
|
||||
|
|
@ -348,7 +335,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
rocket: getFlatFieldMetadataMock({
|
||||
id: 'ba23019c-7f25-42c3-8138-622e61c42968',
|
||||
standardId: '20202020-ca2d-47c0-8253-9d0b662fb01a',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'rocket',
|
||||
|
|
@ -376,7 +362,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pet: getFlatFieldMetadataMock({
|
||||
id: '317a33ef-117e-4953-86d4-c4a9670a2ce3',
|
||||
standardId: '20202020-b715-4658-8b6a-5359824dbddd',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pet',
|
||||
|
|
@ -404,7 +389,6 @@ export const ATTACHMENT_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
surveyResult: getFlatFieldMetadataMock({
|
||||
id: 'a09463e6-5e56-4965-bc8a-2faa23a64672',
|
||||
standardId: '20202020-58b5-4f6c-8402-06b2bf3ea064',
|
||||
objectMetadataId: '819ed5ff-312f-4423-8e95-02a691cf5c27',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'surveyResult',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const COMPANY_FLAT_FIELDS_MOCK = {
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: '12b304b6-ea97-4dcc-9415-9f7b2ac4b729',
|
||||
standardId: '20202020-4d99-4e2e-a84c-4a27837b1ece',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -36,7 +35,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
domainName: getFlatFieldMetadataMock({
|
||||
id: 'f4b67402-1686-491f-a3c7-f70ac9b021cf',
|
||||
standardId: '20202020-0c28-43d8-8ba5-3659924d3489',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'domainName',
|
||||
|
|
@ -65,7 +63,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
employees: getFlatFieldMetadataMock({
|
||||
id: '721d26f0-238d-4d55-a1a2-62f915631c4d',
|
||||
standardId: '20202020-8965-464a-8a75-74bafc152a0b',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.NUMBER,
|
||||
name: 'employees',
|
||||
|
|
@ -89,7 +86,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
linkedinLink: getFlatFieldMetadataMock({
|
||||
id: '6acb80a0-dab8-4d97-a0c8-15e4a495fb54',
|
||||
standardId: '20202020-ebeb-4beb-b9ad-6848036fb451',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'linkedinLink',
|
||||
|
|
@ -117,7 +113,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
xLink: getFlatFieldMetadataMock({
|
||||
id: 'fc630bbb-aa2c-4554-aa4f-9afc0b0567f9',
|
||||
standardId: '20202020-6f64-4fd9-9580-9c1991c7d8c3',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'xLink',
|
||||
|
|
@ -145,7 +140,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
annualRecurringRevenue: getFlatFieldMetadataMock({
|
||||
id: '1e34d871-3e1a-4903-850e-1e4bc6b1d72b',
|
||||
standardId: '20202020-602a-495c-9776-f5d5b11d227b',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.CURRENCY,
|
||||
name: 'annualRecurringRevenue',
|
||||
|
|
@ -170,7 +164,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
address: getFlatFieldMetadataMock({
|
||||
id: '1bd4dc61-e644-4a9e-8899-cacdf43571a1',
|
||||
standardId: '20202020-c5ce-4adc-b7b6-9c0979fc55e7',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.ADDRESS,
|
||||
name: 'address',
|
||||
|
|
@ -203,7 +196,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
idealCustomerProfile: getFlatFieldMetadataMock({
|
||||
id: '8b75a4f1-dc7d-4fa3-b778-616ab9128c31',
|
||||
standardId: '20202020-ba6b-438a-8213-2c5ba28d76a2',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.BOOLEAN,
|
||||
name: 'idealCustomerProfile',
|
||||
|
|
@ -228,7 +220,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: 'ed081dac-ff61-4fe1-bc2c-073644b61c28',
|
||||
standardId: '20202020-9b4e-462b-991d-a0ee33326454',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -252,7 +243,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: 'dbbddd40-a72b-47fe-9ecf-9bdd4282369a',
|
||||
standardId: '20202020-fabc-451d-ab7d-412170916baa',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -280,7 +270,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: 'b2850ac5-d368-44ab-bc79-b1bf7212e5fb',
|
||||
standardId: '85c71601-72f9-4b7b-b343-d46100b2c74d',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
@ -304,7 +293,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '982dff40-66c9-4b9b-b3ec-8fa7076ea3a6',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -328,7 +316,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: 'e2f65a26-0210-4f22-954b-7d448abbdb28',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -352,7 +339,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '26518091-a31b-4716-8627-4e2d25bc0e60',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -376,7 +362,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: '29ba1ee7-fc21-441c-8acc-45d9e56751e3',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -400,7 +385,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
people: getFlatFieldMetadataMock({
|
||||
id: 'b0563539-f027-40c5-a14c-ee7a25ff6fd9',
|
||||
standardId: '20202020-3213-4ddf-9494-6422bcff8d7c',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'people',
|
||||
|
|
@ -424,7 +408,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
accountOwner: getFlatFieldMetadataMock({
|
||||
id: '86c6692b-bed5-4ef1-bad0-657e56a85eba',
|
||||
standardId: '20202020-95b8-4e10-9881-edb5d4765f9d',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'accountOwner',
|
||||
|
|
@ -453,7 +436,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
taskTargets: getFlatFieldMetadataMock({
|
||||
id: '4f9138da-cd36-4df4-98f9-ebabe036b141',
|
||||
standardId: '20202020-cb17-4a61-8f8f-3be6730480de',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'taskTargets',
|
||||
|
|
@ -477,7 +459,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
noteTargets: getFlatFieldMetadataMock({
|
||||
id: '56b9dc8a-0379-42cf-ab31-8db7061f5a2a',
|
||||
standardId: '20202020-bae0-4556-a74a-a9c686f77a88',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'noteTargets',
|
||||
|
|
@ -501,7 +482,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
opportunities: getFlatFieldMetadataMock({
|
||||
id: '3eda8c8e-74e4-401f-bb0e-470db5b267e6',
|
||||
standardId: '20202020-add3-4658-8e23-d70dccb6d0ec',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'opportunities',
|
||||
|
|
@ -525,7 +505,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '72415216-fed4-450b-aa00-691e37718b01',
|
||||
standardId: '20202020-4d1d-41ac-b13b-621631298d55',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
@ -549,7 +528,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: '44a572c5-d620-47f5-943a-346ae967e99e',
|
||||
standardId: '20202020-c1b5-4120-b0f0-987ca401ed53',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -573,7 +551,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: 'cc78390f-f570-4c2c-9f19-2a8fef67f4f6',
|
||||
standardId: '20202020-0414-4daf-9c0d-64fe7b27f89f',
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
@ -597,7 +574,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
tagline: getFlatFieldMetadataMock({
|
||||
id: 'f869f4ed-e440-486a-8392-be33ab327cf4',
|
||||
standardId: null,
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'tagline',
|
||||
|
|
@ -621,7 +597,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
introVideo: getFlatFieldMetadataMock({
|
||||
id: '339b52b7-adfb-4bd3-ae42-0697da92c0fa',
|
||||
standardId: null,
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'introVideo',
|
||||
|
|
@ -649,7 +624,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workPolicy: getFlatFieldMetadataMock({
|
||||
id: '74c546c1-b183-41d0-ac20-aecde83bf674',
|
||||
standardId: null,
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.MULTI_SELECT,
|
||||
name: 'workPolicy',
|
||||
|
|
@ -695,7 +669,6 @@ export const COMPANY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
visaSponsorship: getFlatFieldMetadataMock({
|
||||
id: '5e48697e-a3d0-4faa-b79c-bddd8c7ae17f',
|
||||
standardId: null,
|
||||
objectMetadataId: '7f5c2c7a-bb23-46fb-b59d-9b7a52a8d1cc',
|
||||
type: FieldMetadataType.BOOLEAN,
|
||||
name: 'visaSponsorship',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const FAVORITE_FLAT_FIELDS_MOCK = {
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '64dbf3ef-a352-44bb-9055-f95822f18d0a',
|
||||
standardId: '20202020-dd26-42c6-8c3c-2a7598c204f6',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.NUMBER,
|
||||
name: 'position',
|
||||
|
|
@ -36,7 +35,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '49f58497-4e7c-49e6-b3bc-c91d4b8a8ddc',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -60,7 +58,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '0606a76c-8a72-48ca-90c6-526c729c25eb',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -84,7 +81,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: 'fb202982-0c8e-4917-8dda-acb8248be749',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -108,7 +104,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'ef52e151-a974-470f-bbe7-f345fd4eca65',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -132,7 +127,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
forWorkspaceMember: getFlatFieldMetadataMock({
|
||||
id: '07f2c3ba-63d1-4e44-bac4-bc4591e51bac',
|
||||
standardId: '20202020-ce63-49cb-9676-fdc0c45892cd',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'forWorkspaceMember',
|
||||
|
|
@ -160,7 +154,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
person: getFlatFieldMetadataMock({
|
||||
id: '013cec20-e9cc-42db-b9b9-ff6bd0f52abd',
|
||||
standardId: '20202020-c428-4f40-b6f3-86091511c41c',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'person',
|
||||
|
|
@ -188,7 +181,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: '9a11532c-6839-46ed-a2f5-ed03f88b86f6',
|
||||
standardId: '20202020-cff5-4682-8bf9-069169e08279',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -216,7 +208,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favoriteFolder: getFlatFieldMetadataMock({
|
||||
id: 'fabbe669-b8fc-49fe-8010-f13d01eb61f1',
|
||||
standardId: '20202020-f658-4d12-8b4d-248356aa4bd9',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favoriteFolder',
|
||||
|
|
@ -244,7 +235,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
opportunity: getFlatFieldMetadataMock({
|
||||
id: '6380cf8e-4327-4d1e-ad21-1826ce4ecf05',
|
||||
standardId: '20202020-dabc-48e1-8318-2781a2b32aa2',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'opportunity',
|
||||
|
|
@ -272,7 +262,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workflow: getFlatFieldMetadataMock({
|
||||
id: '12c20527-9b1d-4922-9650-00cc31b26387',
|
||||
standardId: '20202020-b11b-4dc8-999a-6bd0a947b463',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workflow',
|
||||
|
|
@ -300,7 +289,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workflowVersion: getFlatFieldMetadataMock({
|
||||
id: '5cb92f25-c067-4e19-afb3-c7cc038ed1a4',
|
||||
standardId: '20202020-e1b8-4caf-b55a-3ab4d4cbcd21',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workflowVersion',
|
||||
|
|
@ -328,7 +316,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workflowRun: getFlatFieldMetadataMock({
|
||||
id: 'a4bdd0d8-c36f-4519-812b-be4800ab14b0',
|
||||
standardId: '20202020-db5a-4fe4-9a13-9afa22b1e762',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workflowRun',
|
||||
|
|
@ -356,7 +343,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
task: getFlatFieldMetadataMock({
|
||||
id: 'db16ab78-ea3f-4b67-93e3-6ad9ab1b7273',
|
||||
standardId: '20202020-1b1b-4b3b-8b1b-7f8d6a1d7d5c',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'task',
|
||||
|
|
@ -384,7 +370,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
note: getFlatFieldMetadataMock({
|
||||
id: 'a61baf0f-2d43-4fda-9baf-efb000c17ecd',
|
||||
standardId: '20202020-1f25-43fe-8b00-af212fdde824',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'note',
|
||||
|
|
@ -412,7 +397,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
view: getFlatFieldMetadataMock({
|
||||
id: 'accd216c-790e-4bd2-83bb-0700e06d0e5c',
|
||||
standardId: '20202020-5a93-4fa9-acce-e73481a0bbdf',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'view',
|
||||
|
|
@ -440,7 +424,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
rocket: getFlatFieldMetadataMock({
|
||||
id: '9448627d-725d-499e-a071-90fd5cfcf0ea',
|
||||
standardId: '20202020-78f7-4d7d-86e9-7562ced0b381',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'rocket',
|
||||
|
|
@ -468,7 +451,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pet: getFlatFieldMetadataMock({
|
||||
id: 'd34b4048-bf0c-4c61-8ffe-59f1838a2cc4',
|
||||
standardId: '20202020-1bd7-4d10-80dc-968b9f5d1a8a',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pet',
|
||||
|
|
@ -496,7 +478,6 @@ export const FAVORITE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
surveyResult: getFlatFieldMetadataMock({
|
||||
id: '9cdfb5a1-bb9c-4a59-811d-f5a1034a8f8b',
|
||||
standardId: '20202020-d049-4912-80ee-43b09fe3b0ac',
|
||||
objectMetadataId: 'f4749ffb-dde8-44ff-8b01-d3fc82df0ba2',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'surveyResult',
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '5894ab56-99b7-49e8-98be-dd6524250df5',
|
||||
standardId: '20202020-5278-4bde-8909-2cec74d43744',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.NUMBER,
|
||||
name: 'position',
|
||||
|
|
@ -32,7 +31,6 @@ export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: '1502abe0-b2f8-43a7-ae55-91c826b34ffe',
|
||||
standardId: '20202020-82a3-4537-8ff0-dbce7eec35d6',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -56,7 +54,6 @@ export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '85ab1864-0a92-4682-8583-82e8b696410b',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -80,7 +77,6 @@ export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: 'a92b4b66-c2de-483e-8973-6f12bf36ac1a',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -104,7 +100,6 @@ export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '3907fc24-3bf0-4f0b-88be-f9635e473145',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -128,7 +123,6 @@ export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: '52dcb335-5ce1-4165-a30b-4a61e84af21f',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -152,7 +146,6 @@ export const FAVORITE_FOLDER_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '71b95076-6b8d-45c9-9a7c-ab981b81bd1b',
|
||||
standardId: '20202020-b5e3-4b42-8af2-03cd4fd2e4d2',
|
||||
objectMetadataId: '35763b74-1abe-4c4b-9eab-27693f0ee06d',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
|
|||
|
|
@ -39,7 +39,6 @@ export const getFlatFieldMetadataMock = <T extends FieldMetadataType>(
|
|||
isUIReadOnly: false,
|
||||
isLabelSyncedWithName: false,
|
||||
isSystem: false,
|
||||
standardId: null,
|
||||
standardOverrides: null,
|
||||
workspaceId: faker.string.uuid(),
|
||||
applicationId: faker.string.uuid(),
|
||||
|
|
@ -63,7 +62,6 @@ export const getStandardFlatFieldMetadataMock = (
|
|||
overrides: Omit<FlatFieldMetadataOverrides, 'isCustom' | 'isSystem'>,
|
||||
) => {
|
||||
return getFlatFieldMetadataMock({
|
||||
standardId: faker.string.uuid(),
|
||||
standardOverrides: {},
|
||||
isCustom: false,
|
||||
isSystem: true,
|
||||
|
|
|
|||
|
|
@ -51,7 +51,6 @@ export const getRelationTargetFlatFieldMetadataMock = ({
|
|||
isUIReadOnly: false,
|
||||
isLabelSyncedWithName: false,
|
||||
isSystem: false,
|
||||
standardId: null,
|
||||
standardOverrides: null,
|
||||
workspaceId: faker.string.uuid(),
|
||||
objectMetadataId,
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const NOTE_FLAT_FIELDS_MOCK = {
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '3ea4b48b-3b88-4db5-b455-c7c77b208599',
|
||||
standardId: '20202020-368d-4dc2-943f-ed8a49c7fdfb',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -32,7 +31,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
title: getFlatFieldMetadataMock({
|
||||
id: '3cb30a3f-31c1-47d3-a61e-e537615390c8',
|
||||
standardId: '20202020-faeb-4c76-8ba6-ccbb0b4a965f',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'title',
|
||||
|
|
@ -56,7 +54,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
bodyV2: getFlatFieldMetadataMock({
|
||||
id: 'acb2973c-7e46-4296-ac79-8b8d163b6d85',
|
||||
standardId: '20202020-a7bb-4d94-be51-8f25181502c8',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.RICH_TEXT_V2,
|
||||
name: 'bodyV2',
|
||||
|
|
@ -80,7 +77,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: '1caa79de-f2ec-405c-8667-7a65e9a3bcbf',
|
||||
standardId: '20202020-0d79-4e21-ab77-5a394eff97be',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -108,7 +104,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: '597b0c10-840e-4ba5-99db-7ef834a72bed',
|
||||
standardId: '20202020-7ea8-44d4-9d4c-51dd2a757950',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
@ -132,7 +127,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '6ece96a9-2948-4735-8c8a-40cdb76e23b8',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -156,7 +150,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '0b849709-eee4-4d63-9fef-058cfdd0c098',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -180,7 +173,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '8b4fe2dd-f4fa-4365-964d-d8f0dd7890cd',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -204,7 +196,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'fbf20b48-0aca-49a2-b3a8-67d0d7dfe104',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -228,7 +219,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
noteTargets: getFlatFieldMetadataMock({
|
||||
id: '3a13d398-b7e6-4871-a5f8-5446806b3e5b',
|
||||
standardId: '20202020-1f25-43fe-8b00-af212fdde823',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'noteTargets',
|
||||
|
|
@ -252,7 +242,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: '4d4b3225-ddd2-4d76-a4d6-bcdd43a256e8',
|
||||
standardId: '20202020-4986-4c92-bf19-39934b149b16',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -276,7 +265,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: '1207d260-db2c-41d4-bb09-34ea1188978f',
|
||||
standardId: '20202020-7030-42f8-929c-1a57b25d6bce',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
@ -300,7 +288,6 @@ export const NOTE_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '065a1ede-f773-48ca-84bf-70f61d838396',
|
||||
standardId: '20202020-4d1d-41ac-b13b-621631298d67',
|
||||
objectMetadataId: '1253e3e5-5b00-4a34-93b8-02f3dc6e2b7c',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '3ef6c3df-6569-4d00-b1ae-3893e8e55a7e',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -36,7 +35,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '3cecf38d-1186-4e66-9eb6-06516d3b3172',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -60,7 +58,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '41e0ee99-7319-4709-a11a-b0d624625359',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -84,7 +81,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: '3ef1221e-649f-41f9-a360-12896e3c0935',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -108,7 +104,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
note: getFlatFieldMetadataMock({
|
||||
id: 'b1e812b7-604e-459b-9449-31fa414b315c',
|
||||
standardId: '20202020-57f3-4f50-9599-fc0f671df003',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'note',
|
||||
|
|
@ -136,7 +131,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
person: getFlatFieldMetadataMock({
|
||||
id: '560c71ff-254f-4baf-a4d1-054c53444f41',
|
||||
standardId: '20202020-38ca-4aab-92f5-8a605ca2e4c5',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'person',
|
||||
|
|
@ -164,7 +158,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: 'd1d3f9eb-1447-4adb-bc2b-f133bc58ac35',
|
||||
standardId: 'c500fbc0-d6f2-4982-a959-5a755431696c',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -192,7 +185,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
opportunity: getFlatFieldMetadataMock({
|
||||
id: 'f42eac2a-8d99-4259-b69a-549abd553eda',
|
||||
standardId: '20202020-4e42-417a-a705-76581c9ade79',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'opportunity',
|
||||
|
|
@ -220,7 +212,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
rocket: getFlatFieldMetadataMock({
|
||||
id: '4212b3d7-dd9f-4da9-85f7-2fa69a42296f',
|
||||
standardId: '20202020-52b6-4d5e-8f21-ed8b7c09c4a9',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'rocket',
|
||||
|
|
@ -248,7 +239,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pet: getFlatFieldMetadataMock({
|
||||
id: 'd88d0737-e83a-47b1-b701-8edfe4a2ae2e',
|
||||
standardId: '20202020-c54e-4804-8b0d-8795e5166432',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pet',
|
||||
|
|
@ -276,7 +266,6 @@ export const NOTETARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
surveyResult: getFlatFieldMetadataMock({
|
||||
id: '7f444190-cb0e-4417-9c61-e59d8969b7f7',
|
||||
standardId: '20202020-75c4-4165-8146-dfdc2a76b940',
|
||||
objectMetadataId: '12e3cb51-c3de-4192-b0d5-965d48d001c0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'surveyResult',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: '5f510348-58e9-4ded-8dbe-144ae3644bd4',
|
||||
standardId: '20202020-8609-4f65-a2d9-44009eb422b5',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -36,7 +35,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
amount: getFlatFieldMetadataMock({
|
||||
id: '2713c658-cfad-4bc2-a6a0-adc4815185a1',
|
||||
standardId: '20202020-583e-4642-8533-db761d5fa82f',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.CURRENCY,
|
||||
name: 'amount',
|
||||
|
|
@ -60,7 +58,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
closeDate: getFlatFieldMetadataMock({
|
||||
id: '1d15aa71-38ea-473f-aac9-e4519882213f',
|
||||
standardId: '20202020-527e-44d6-b1ac-c4158d307b97',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'closeDate',
|
||||
|
|
@ -84,7 +81,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
stage: getFlatFieldMetadataMock({
|
||||
id: '4642f809-f302-4525-8af1-3f3ad79998fb',
|
||||
standardId: '20202020-6f76-477d-8551-28cd65b2b4b9',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.SELECT,
|
||||
name: 'stage',
|
||||
|
|
@ -144,7 +140,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: 'd4ca6cb7-fbdb-4e27-b5be-ac9f3a17cf0a',
|
||||
standardId: '20202020-806d-493a-bbc6-6313e62958e2',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -168,7 +163,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: '29222276-99f1-4443-b5d6-6ea6aa16f28a',
|
||||
standardId: '20202020-a63e-4a62-8e63-42a51828f831',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -196,7 +190,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: '0ba0c3f0-41f1-4c49-b28b-0a04adddbc7c',
|
||||
standardId: '428a0da5-4b2e-4ce3-b695-89a8b384e6e3',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
@ -220,7 +213,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '06f91646-dd7c-481d-b2d9-6dc02b9b6ca8',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -244,7 +236,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '9cc5c7c6-d9eb-46aa-b4a9-e5a922749b14',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -268,7 +259,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '04629f30-4fdc-4084-bf3f-7f254acc6cf8',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -292,7 +282,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: '07435758-30b2-4d10-a2c3-947b8db7797f',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -316,7 +305,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pointOfContact: getFlatFieldMetadataMock({
|
||||
id: '0e55bf63-1ffb-4f74-89f2-edd5a6a6686c',
|
||||
standardId: '20202020-8dfb-42fc-92b6-01afb759ed16',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pointOfContact',
|
||||
|
|
@ -344,7 +332,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: '512890f1-4da0-4b96-bb71-5ccabefb82e7',
|
||||
standardId: '20202020-cbac-457e-b565-adece5fc815f',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -372,7 +359,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '87bb9924-a1cc-4357-9c8a-52141dabf266',
|
||||
standardId: '20202020-a1c2-4500-aaae-83ba8a0e827a',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
@ -396,7 +382,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
taskTargets: getFlatFieldMetadataMock({
|
||||
id: 'c0c9f9ac-0d40-4206-90e5-0d1e14f8a09f',
|
||||
standardId: '20202020-59c0-4179-a208-4a255f04a5be',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'taskTargets',
|
||||
|
|
@ -420,7 +405,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
noteTargets: getFlatFieldMetadataMock({
|
||||
id: '36210a54-a72e-4530-a1eb-a0420c53e551',
|
||||
standardId: '20202020-dd3f-42d5-a382-db58aabf43d3',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'noteTargets',
|
||||
|
|
@ -444,7 +428,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: '16515578-a6ce-48af-a303-2005bb8492f0',
|
||||
standardId: '20202020-87c7-4118-83d6-2f4031005209',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -468,7 +451,6 @@ export const OPPORTUNITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: '7826944b-3b21-4448-892e-5a2a68161313',
|
||||
standardId: '20202020-30e2-421f-96c7-19c69d1cf631',
|
||||
objectMetadataId: 'e6996bbf-dd41-423a-9324-8546f5b22fa7',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const PERSON_FLAT_FIELDS_MOCK = {
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: 'f410c1cd-2523-4802-be8e-1acc852b4b1a',
|
||||
standardId: '20202020-3875-44d5-8c33-a6239011cab8',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.FULL_NAME,
|
||||
name: 'name',
|
||||
|
|
@ -36,7 +35,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
emails: getFlatFieldMetadataMock({
|
||||
id: '012dd567-b7d9-4088-a0c1-4ded96a25e35',
|
||||
standardId: '20202020-3c51-43fa-8b6e-af39e29368ab',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.EMAILS,
|
||||
name: 'emails',
|
||||
|
|
@ -60,7 +58,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
linkedinLink: getFlatFieldMetadataMock({
|
||||
id: '86e35da6-151d-47e3-8745-bb1e652b789c',
|
||||
standardId: '20202020-f1af-48f7-893b-2007a73dd508',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'linkedinLink',
|
||||
|
|
@ -88,7 +85,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
xLink: getFlatFieldMetadataMock({
|
||||
id: 'c9d36790-a449-4108-91e1-c6ad6e3379fb',
|
||||
standardId: '20202020-8fc2-487c-b84a-55a99b145cfd',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'xLink',
|
||||
|
|
@ -116,7 +112,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
jobTitle: getFlatFieldMetadataMock({
|
||||
id: 'ab82c659-b553-4317-9708-998f6884c72e',
|
||||
standardId: '20202020-b0d0-415a-bef9-640a26dacd9b',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'jobTitle',
|
||||
|
|
@ -140,7 +135,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
phones: getFlatFieldMetadataMock({
|
||||
id: '4955e9cb-a740-49fa-9c91-69ec74a6b3df',
|
||||
standardId: '20202020-0638-448e-8825-439134618022',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.PHONES,
|
||||
name: 'phones',
|
||||
|
|
@ -169,7 +163,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
city: getFlatFieldMetadataMock({
|
||||
id: '61ad7592-6465-4a24-a863-0320cf7830a6',
|
||||
standardId: '20202020-5243-4ffb-afc5-2c675da41346',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'city',
|
||||
|
|
@ -193,7 +186,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
avatarUrl: getFlatFieldMetadataMock({
|
||||
id: '05e46775-93e9-46c4-8b6f-94829045b1ad',
|
||||
standardId: '20202020-b8a6-40df-961c-373dc5d2ec21',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'avatarUrl',
|
||||
|
|
@ -217,7 +209,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '5162d850-29dd-474e-982b-24257b57fd46',
|
||||
standardId: '20202020-fcd5-4231-aff5-fff583eaa0b1',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -241,7 +232,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: '1a3de345-4f47-4dc9-b328-61c802efa36e',
|
||||
standardId: '20202020-f6ab-4d98-af24-a3d5b664148a',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -269,7 +259,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: '1d7f79d4-7811-45dc-8f9f-5dbd4863d0a1',
|
||||
standardId: '57d1d7ad-fa10-44fc-82f3-ad0959ec2534',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
@ -293,7 +282,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: 'd9b3e129-49ce-4843-a813-9d16f2239472',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -317,7 +305,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '9fec2460-6fd2-4aaf-8781-78893ba61d6d',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -341,7 +328,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '6a00c4b7-d77c-4268-85e7-9e3a597bd0e7',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -365,7 +351,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'a9f5469d-d7ff-42f6-b3a7-399c8ab8b468',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -389,7 +374,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: 'ee247ca6-fdaa-4a56-87a2-730cf84f5f29',
|
||||
standardId: '20202020-e2f3-448e-b34c-2d625f0025fd',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -417,7 +401,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pointOfContactForOpportunities: getFlatFieldMetadataMock({
|
||||
id: '7580c1b1-e8f9-480b-bd41-38b20df35777',
|
||||
standardId: '20202020-911b-4a7d-b67b-918aa9a5b33a',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pointOfContactForOpportunities',
|
||||
|
|
@ -442,7 +425,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
taskTargets: getFlatFieldMetadataMock({
|
||||
id: '9609ca31-215e-47fd-9b3b-ab200acb2fa8',
|
||||
standardId: '20202020-584b-4d3e-88b6-53ab1fa03c3a',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'taskTargets',
|
||||
|
|
@ -466,7 +448,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
noteTargets: getFlatFieldMetadataMock({
|
||||
id: '60388ed8-45f6-4fb5-8752-81c73e13f4ab',
|
||||
standardId: '20202020-c8fc-4258-8250-15905d3fcfec',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'noteTargets',
|
||||
|
|
@ -490,7 +471,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: 'a1a72bee-1c15-4598-ba23-67ba8e3e505d',
|
||||
standardId: '20202020-4073-4117-9cf1-203bcdc91cbd',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
@ -514,7 +494,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: '367ad117-de09-466c-94f8-ce99d951b5ce',
|
||||
standardId: '20202020-cd97-451f-87fa-bcb789bdbf3a',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -538,7 +517,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
messageParticipants: getFlatFieldMetadataMock({
|
||||
id: '22dcab3c-939c-4b8d-bd7c-4c4d58588460',
|
||||
standardId: '20202020-498e-4c61-8158-fa04f0638334',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'messageParticipants',
|
||||
|
|
@ -562,7 +540,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
calendarEventParticipants: getFlatFieldMetadataMock({
|
||||
id: '9e82a873-2988-4d9d-af04-81f2d947f4ec',
|
||||
standardId: '20202020-52ee-45e9-a702-b64b3753e3a9',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'calendarEventParticipants',
|
||||
|
|
@ -586,7 +563,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: 'b1457347-545b-4a42-9c68-bc655952229a',
|
||||
standardId: '20202020-a43e-4873-9c23-e522de906ce5',
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
@ -610,7 +586,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
intro: getFlatFieldMetadataMock({
|
||||
id: '94c95bfa-88bc-4271-87c2-08e6df084a15',
|
||||
standardId: null,
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'intro',
|
||||
|
|
@ -634,7 +609,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
whatsapp: getFlatFieldMetadataMock({
|
||||
id: 'adc26aa8-d146-49d2-a037-77e15d8b20fc',
|
||||
standardId: null,
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.PHONES,
|
||||
name: 'whatsapp',
|
||||
|
|
@ -663,7 +637,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workPreference: getFlatFieldMetadataMock({
|
||||
id: '421b5788-94dd-40b0-8d5f-6c649d7464c4',
|
||||
standardId: null,
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.MULTI_SELECT,
|
||||
name: 'workPreference',
|
||||
|
|
@ -709,7 +682,6 @@ export const PERSON_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
performanceRating: getFlatFieldMetadataMock({
|
||||
id: 'f75b0e71-e34c-4bc9-bb91-55a94127ab82',
|
||||
standardId: null,
|
||||
objectMetadataId: '843e0b67-9619-4628-91c4-2fa62256a611',
|
||||
type: FieldMetadataType.RATING,
|
||||
name: 'performanceRating',
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const PET_FLAT_FIELDS_MOCK = {
|
||||
noteTargets: getFlatFieldMetadataMock({
|
||||
id: '98afd46e-0259-4c87-969d-16e7e660e007',
|
||||
standardId: '20202020-01fd-4f37-99dc-9427a444018a',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'noteTargets',
|
||||
|
|
@ -32,7 +31,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: 'ce25501a-1cc6-44c5-9158-b602db0efaca',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -56,7 +54,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: '4311d4e0-ce63-479c-a4da-5b244e2348cc',
|
||||
standardId: '20202020-ba07-4ffd-ba63-009491f5749c',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -80,7 +77,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '0bbe259b-0fd1-43ca-922f-1c0b7960efbe',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -104,7 +100,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: 'c96d123d-4c13-47ee-85bf-00428ce5e242',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -128,7 +123,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'bbfd9b09-be13-4232-af2c-585a9137aa62',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -152,7 +146,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: '2090b892-376c-4349-990d-6a789b53e31d',
|
||||
standardId: '20202020-be0e-4971-865b-32ca87cbb315',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -176,7 +169,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '3087f7da-f422-4b69-9b95-fadef79dd12a',
|
||||
standardId: '20202020-c2bd-4e16-bb9a-c8b0411bf49d',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -200,7 +192,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: '4eb74f21-1cb4-46b5-b3bb-4e41108e70d9',
|
||||
standardId: '20202020-f1ef-4ba4-8f33-1a4577afa477',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
@ -224,7 +215,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '80bc4e7a-6bd1-4f2b-98b1-6333c631cc1a',
|
||||
standardId: '20202020-a4a7-4686-b296-1c6c3482ee21',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
@ -248,7 +238,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: '231903d0-3b14-47ed-9a88-fbf11031c451',
|
||||
standardId: '20202020-8d59-46ca-b7b2-73d167712134',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -272,7 +261,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
taskTargets: getFlatFieldMetadataMock({
|
||||
id: '3cae8259-ece8-4b81-9044-f5abae5ff25c',
|
||||
standardId: '20202020-0860-4566-b865-bff3c626c303',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'taskTargets',
|
||||
|
|
@ -296,7 +284,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: '0db37175-e573-43e4-bd83-fa71923fde0c',
|
||||
standardId: '70e56537-18ef-4811-b1c7-0a444006b815',
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
@ -320,7 +307,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
species: getFlatFieldMetadataMock({
|
||||
id: '0292cc51-246f-40b8-99e8-3345dac0e688',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.SELECT,
|
||||
name: 'species',
|
||||
|
|
@ -387,7 +373,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
traits: getFlatFieldMetadataMock({
|
||||
id: '5aaf6be0-b9f5-4222-9810-941d5ab58527',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.MULTI_SELECT,
|
||||
name: 'traits',
|
||||
|
|
@ -454,7 +439,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
comments: getFlatFieldMetadataMock({
|
||||
id: '2e726631-d80a-4594-9a5a-3cca0c2a50a9',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'comments',
|
||||
|
|
@ -478,7 +462,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
age: getFlatFieldMetadataMock({
|
||||
id: 'ed1573cf-b29e-4d4f-a8e3-19d472d28c0d',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.NUMBER,
|
||||
name: 'age',
|
||||
|
|
@ -502,7 +485,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
location: getFlatFieldMetadataMock({
|
||||
id: '7b05e127-d0ea-422a-8f98-ef48f41d4388',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.ADDRESS,
|
||||
name: 'location',
|
||||
|
|
@ -535,7 +517,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
vetPhone: getFlatFieldMetadataMock({
|
||||
id: '92c856ef-5b4b-4202-8c23-b2f22f959eda',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.PHONES,
|
||||
name: 'vetPhone',
|
||||
|
|
@ -564,7 +545,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
vetEmail: getFlatFieldMetadataMock({
|
||||
id: '2c89697d-925a-485c-a0ed-adf2f1228e0f',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.EMAILS,
|
||||
name: 'vetEmail',
|
||||
|
|
@ -588,7 +568,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
birthday: getFlatFieldMetadataMock({
|
||||
id: '13c5b4ed-5746-494f-856b-081bdbb4a8ec',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.DATE,
|
||||
name: 'birthday',
|
||||
|
|
@ -612,7 +591,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
isGoodWithKids: getFlatFieldMetadataMock({
|
||||
id: 'ec3bf27e-70e6-4d4a-932e-6ef026013603',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.BOOLEAN,
|
||||
name: 'isGoodWithKids',
|
||||
|
|
@ -636,7 +614,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pictures: getFlatFieldMetadataMock({
|
||||
id: '8aa0a700-c308-4d8b-8fbd-f545daa8980a',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.LINKS,
|
||||
name: 'pictures',
|
||||
|
|
@ -664,7 +641,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
averageCostOfKibblePerMonth: getFlatFieldMetadataMock({
|
||||
id: '37421848-b64d-4827-be33-da4e337acbb6',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.CURRENCY,
|
||||
name: 'averageCostOfKibblePerMonth',
|
||||
|
|
@ -688,7 +664,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
makesOwnerThinkOf: getFlatFieldMetadataMock({
|
||||
id: '84b874dc-983d-47eb-9c67-54f557a99f60',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.FULL_NAME,
|
||||
name: 'makesOwnerThinkOf',
|
||||
|
|
@ -712,7 +687,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
soundSwag: getFlatFieldMetadataMock({
|
||||
id: '42e6c0d2-6d00-4c77-b179-890af8c56236',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RATING,
|
||||
name: 'soundSwag',
|
||||
|
|
@ -767,7 +741,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
bio: getFlatFieldMetadataMock({
|
||||
id: 'fa0ec409-0f29-4b19-b304-31d1018a2344',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RICH_TEXT,
|
||||
name: 'bio',
|
||||
|
|
@ -791,7 +764,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
interestingFacts: getFlatFieldMetadataMock({
|
||||
id: '2b806a74-e7a5-4ec7-b902-67cf811e8bda',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.ARRAY,
|
||||
name: 'interestingFacts',
|
||||
|
|
@ -815,7 +787,6 @@ export const PET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
extraData: getFlatFieldMetadataMock({
|
||||
id: 'a79bd7c8-c7ce-416a-9d12-a05335c9c596',
|
||||
standardId: null,
|
||||
objectMetadataId: 'd34e0f07-1b8c-4de0-938e-599cf05e1f7f',
|
||||
type: FieldMetadataType.RAW_JSON,
|
||||
name: 'extraData',
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const ROCKET_FLAT_FIELDS_MOCK = {
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: 'c7c23914-80c4-46d2-a559-1ce20d07fb3c',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -32,7 +31,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: '9c10de36-1ade-4be1-af78-c4fc55669fbd',
|
||||
standardId: '20202020-ba07-4ffd-ba63-009491f5749c',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -56,7 +54,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '7aa0896a-82dd-43c0-b38f-a316a8064d51',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -80,7 +77,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '1ca95b19-f02d-43c1-b9ae-8a9d522bb34b',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -104,7 +100,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'aae8d11a-27b3-4844-a68f-a2023ae12443',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -128,7 +123,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: '23ebf744-88ad-4d0f-9084-a63e29c4655b',
|
||||
standardId: '20202020-be0e-4971-865b-32ca87cbb315',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -152,7 +146,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '2f1976a6-ae59-43c5-85bc-49fb8fd03e18',
|
||||
standardId: '20202020-c2bd-4e16-bb9a-c8b0411bf49d',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -176,7 +169,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: '53a223cc-a445-420d-8698-1a9137039448',
|
||||
standardId: '20202020-f1ef-4ba4-8f33-1a4577afa477',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
@ -200,7 +192,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '14010360-f3c2-442e-b05f-43c30158f246',
|
||||
standardId: '20202020-a4a7-4686-b296-1c6c3482ee21',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
@ -224,7 +215,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: 'f5984acf-5128-42ac-840f-9d2888423699',
|
||||
standardId: '20202020-8d59-46ca-b7b2-73d167712134',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -248,7 +238,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
noteTargets: getFlatFieldMetadataMock({
|
||||
id: 'c91376fb-20bd-47c7-8922-b64f7db51cfa',
|
||||
standardId: '20202020-01fd-4f37-99dc-9427a444018a',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'noteTargets',
|
||||
|
|
@ -272,7 +261,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
taskTargets: getFlatFieldMetadataMock({
|
||||
id: '80e3b587-69ec-48bc-a872-20105c3b7df4',
|
||||
standardId: '20202020-0860-4566-b865-bff3c626c303',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'taskTargets',
|
||||
|
|
@ -296,7 +284,6 @@ export const ROCKET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: 'e7609ea3-5a88-4d64-b0c1-eefd4602361a',
|
||||
standardId: '70e56537-18ef-4811-b1c7-0a444006b815',
|
||||
objectMetadataId: 'd78ec657-74a4-4652-a350-1f44ff62970a',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const TASK_FLAT_FIELDS_MOCK = {
|
||||
position: getFlatFieldMetadataMock({
|
||||
id: '53134864-086f-40ab-a455-11417542ebd4',
|
||||
standardId: '20202020-7d47-4690-8a98-98b9a0c05dd8',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.POSITION,
|
||||
name: 'position',
|
||||
|
|
@ -36,7 +35,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
title: getFlatFieldMetadataMock({
|
||||
id: '88e4eeac-1d47-4e44-a795-bb5ca93c6557',
|
||||
standardId: '20202020-b386-4cb7-aa5a-08d4a4d92680',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'title',
|
||||
|
|
@ -60,7 +58,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
bodyV2: getFlatFieldMetadataMock({
|
||||
id: '161570ed-7fcd-4172-a5d1-c773cd9afe76',
|
||||
standardId: '20202020-4aa0-4ae8-898d-7df0afd47ab1',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.RICH_TEXT_V2,
|
||||
name: 'bodyV2',
|
||||
|
|
@ -84,7 +81,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
dueAt: getFlatFieldMetadataMock({
|
||||
id: '1723b01e-e10b-4410-8cc2-3e0b937754e4',
|
||||
standardId: '20202020-fd99-40da-951b-4cb9a352fce3',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'dueAt',
|
||||
|
|
@ -108,7 +104,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
status: getFlatFieldMetadataMock({
|
||||
id: '44924cd6-fa70-4239-8c22-f17107f83574',
|
||||
standardId: '20202020-70bc-48f9-89c5-6aa730b151e0',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.SELECT,
|
||||
name: 'status',
|
||||
|
|
@ -154,7 +149,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdBy: getFlatFieldMetadataMock({
|
||||
id: '575c3d51-5cdc-4ff0-aa67-dcc7f1ba2448',
|
||||
standardId: '20202020-1a04-48ab-a567-576965ae5387',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.ACTOR,
|
||||
name: 'createdBy',
|
||||
|
|
@ -182,7 +176,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
searchVector: getFlatFieldMetadataMock({
|
||||
id: 'bc00547b-b4c5-4d49-a4f1-97159df5cbc1',
|
||||
standardId: '20202020-4746-4e2f-870c-52b02c67c90d',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.TS_VECTOR,
|
||||
name: 'searchVector',
|
||||
|
|
@ -206,7 +199,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: 'dc9b18f9-237c-40ba-97c1-e92c2d7c8e2e',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -230,7 +222,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '10c9e428-0739-48a6-8c39-28e6935dfb7c',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -254,7 +245,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: 'cafcc785-7940-4d27-92e3-ba4b5be5af03',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -278,7 +268,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: 'aa440383-fb91-492c-948f-5b57275cf8e1',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -302,7 +291,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
taskTargets: getFlatFieldMetadataMock({
|
||||
id: 'cd08bc00-d02c-48d4-a1ac-a0cfa13742b7',
|
||||
standardId: '20202020-de9c-4d0e-a452-713d4a3e5fc7',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'taskTargets',
|
||||
|
|
@ -326,7 +314,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
attachments: getFlatFieldMetadataMock({
|
||||
id: '00fd339a-6431-465d-9524-09b5c804f497',
|
||||
standardId: '20202020-794d-4783-a8ff-cecdb15be139',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'attachments',
|
||||
|
|
@ -350,7 +337,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
assignee: getFlatFieldMetadataMock({
|
||||
id: '0e18f5e1-32c3-4daa-b282-ab64fb629b20',
|
||||
standardId: '20202020-065a-4f42-a906-e20422c1753f',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'assignee',
|
||||
|
|
@ -378,7 +364,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
timelineActivities: getFlatFieldMetadataMock({
|
||||
id: '3536b3af-76a2-44f5-9d89-1961a0a0a763',
|
||||
standardId: '20202020-c778-4278-99ee-23a2837aee64',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'timelineActivities',
|
||||
|
|
@ -402,7 +387,6 @@ export const TASK_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
favorites: getFlatFieldMetadataMock({
|
||||
id: '33e4eff0-ff0f-4530-802a-cd630481ee84',
|
||||
standardId: '20202020-4d1d-41ac-b13b-621631298d65',
|
||||
objectMetadataId: '3186920d-2a15-4b5f-96c7-2bf6567024b0',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'favorites',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: '762d956d-d11a-4fe6-b6c1-182b9f63a56b',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -36,7 +35,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: '040784f1-4b59-4033-b4c7-7ed426d70b65',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -60,7 +58,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: '2b0881e8-767b-4428-ae25-b6ac1a97293a',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -84,7 +81,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: '42b66721-a65c-41bf-a1d7-971ff732be12',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -108,7 +104,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
task: getFlatFieldMetadataMock({
|
||||
id: 'c906885c-315a-4783-942e-6caafecf2031',
|
||||
standardId: '20202020-e881-457a-8758-74aaef4ae78a',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'task',
|
||||
|
|
@ -136,7 +131,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
person: getFlatFieldMetadataMock({
|
||||
id: '64225f87-96c4-4846-9462-e7aa3ad9e182',
|
||||
standardId: '20202020-c8a0-4e85-a016-87e2349cfbec',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'person',
|
||||
|
|
@ -164,7 +158,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: 'ec11b025-1476-4e84-81c5-cf5b5c776edc',
|
||||
standardId: '20202020-4703-4a4e-948c-487b0c60a92c',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -192,7 +185,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
opportunity: getFlatFieldMetadataMock({
|
||||
id: '49afc8d8-dde3-4d19-aa6b-bd16a751b114',
|
||||
standardId: '20202020-6cb2-4c01-a9a5-aca3dbc11d41',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'opportunity',
|
||||
|
|
@ -220,7 +212,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
rocket: getFlatFieldMetadataMock({
|
||||
id: 'a7e80fd8-76bc-45ed-b843-a2b87ef4d601',
|
||||
standardId: '20202020-b98f-473d-85fb-8cebc40b9a50',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'rocket',
|
||||
|
|
@ -248,7 +239,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pet: getFlatFieldMetadataMock({
|
||||
id: '3955a4b4-1c10-4ce8-a92e-98e727ee7aec',
|
||||
standardId: '20202020-07d9-4d04-8b73-a39ab65943f1',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pet',
|
||||
|
|
@ -276,7 +266,6 @@ export const TASKTARGET_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
surveyResult: getFlatFieldMetadataMock({
|
||||
id: 'caa8b6cf-c668-4fb0-abf9-e49645668020',
|
||||
standardId: '20202020-c376-450d-8a49-a573f23eafd8',
|
||||
objectMetadataId: 'bb2b29b8-7f46-4106-a8ae-3a32df9c9166',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'surveyResult',
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-m
|
|||
export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
||||
happensAt: getFlatFieldMetadataMock({
|
||||
id: 'f8bbe593-cc45-4509-ba5f-aff1b4ae78a9',
|
||||
standardId: '20202020-9526-4993-b339-c4318c4d39f0',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'happensAt',
|
||||
|
|
@ -36,7 +35,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
name: getFlatFieldMetadataMock({
|
||||
id: '8271b048-89c8-4db9-ba49-e20d1e634cea',
|
||||
standardId: '20202020-7207-46e8-9dab-849505ae8497',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'name',
|
||||
|
|
@ -60,7 +58,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
properties: getFlatFieldMetadataMock({
|
||||
id: '5067203a-5fc0-47a7-8fb3-466e8edc8e82',
|
||||
standardId: '20202020-f142-4b04-b91b-6a2b4af3bf11',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RAW_JSON,
|
||||
name: 'properties',
|
||||
|
|
@ -84,7 +81,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
linkedRecordCachedName: getFlatFieldMetadataMock({
|
||||
id: '6192bb0a-dcff-4ce9-9373-6b3efd74def3',
|
||||
standardId: '20202020-cfdb-4bef-bbce-a29f41230934',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.TEXT,
|
||||
name: 'linkedRecordCachedName',
|
||||
|
|
@ -108,7 +104,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
linkedRecordId: getFlatFieldMetadataMock({
|
||||
id: '1a1b9069-0274-4d89-a189-6944ebd8afd5',
|
||||
standardId: '20202020-2e0e-48c0-b445-ee6c1e61687d',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'linkedRecordId',
|
||||
|
|
@ -132,7 +127,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
linkedObjectMetadataId: getFlatFieldMetadataMock({
|
||||
id: 'aa0a6096-ddd6-44b3-a8c1-ec4c1ec70c52',
|
||||
standardId: '20202020-c595-449d-9f89-562758c9ee69',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'linkedObjectMetadataId',
|
||||
|
|
@ -156,7 +150,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
id: getFlatFieldMetadataMock({
|
||||
id: 'e78264fa-48bc-46cd-afc1-c5f2b5eb9472',
|
||||
standardId: '20202020-eda0-4cee-9577-3eb357e3c22b',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.UUID,
|
||||
name: 'id',
|
||||
|
|
@ -180,7 +173,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
createdAt: getFlatFieldMetadataMock({
|
||||
id: 'cb8b2800-2a6e-443c-b671-df51c8a8ccdc',
|
||||
standardId: '20202020-66ac-4502-9975-e4d959c50311',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'createdAt',
|
||||
|
|
@ -204,7 +196,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
updatedAt: getFlatFieldMetadataMock({
|
||||
id: 'cc7b974c-4cb3-4b61-821a-824b4764fc6b',
|
||||
standardId: '20202020-d767-4622-bdcf-d8a084834d86',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'updatedAt',
|
||||
|
|
@ -228,7 +219,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
deletedAt: getFlatFieldMetadataMock({
|
||||
id: '544fdd41-6418-43e4-a46a-086c2c55924d',
|
||||
standardId: '20202020-b9a7-48d8-8387-b9a3090a50ec',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.DATE_TIME,
|
||||
name: 'deletedAt',
|
||||
|
|
@ -252,7 +242,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workspaceMember: getFlatFieldMetadataMock({
|
||||
id: 'c8d9c315-034a-4ffd-a6b3-e6386092d0a8',
|
||||
standardId: '20202020-af23-4479-9a30-868edc474b36',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workspaceMember',
|
||||
|
|
@ -280,7 +269,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
person: getFlatFieldMetadataMock({
|
||||
id: 'dbd02754-4bef-4149-b39d-54759983ab47',
|
||||
standardId: '20202020-c414-45b9-a60a-ac27aa96229f',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'person',
|
||||
|
|
@ -308,7 +296,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
company: getFlatFieldMetadataMock({
|
||||
id: 'fd8cabe5-7dc8-4d6a-8053-43434488b3e4',
|
||||
standardId: '20202020-04ad-4221-a744-7a8278a5ce21',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'company',
|
||||
|
|
@ -336,7 +323,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
opportunity: getFlatFieldMetadataMock({
|
||||
id: '026cbaa7-860c-4ed4-b878-8d78849e6c28',
|
||||
standardId: '20202020-7664-4a35-a3df-580d389fd527',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'opportunity',
|
||||
|
|
@ -364,7 +350,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
note: getFlatFieldMetadataMock({
|
||||
id: '2b9f1c90-9e35-4ccc-8d84-b42de31ef127',
|
||||
standardId: '20202020-ec55-4135-8da5-3a20badc0156',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'note',
|
||||
|
|
@ -392,7 +377,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
task: getFlatFieldMetadataMock({
|
||||
id: '187eaeb8-62c8-4925-815f-946b4768b786',
|
||||
standardId: '20202020-b2f5-415c-9135-a31dfe49501b',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'task',
|
||||
|
|
@ -420,7 +404,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workflow: getFlatFieldMetadataMock({
|
||||
id: '9973da2e-cc65-41b2-8f52-4130cfa31fc6',
|
||||
standardId: '20202020-616c-4ad3-a2e9-c477c341e295',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workflow',
|
||||
|
|
@ -448,7 +431,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workflowVersion: getFlatFieldMetadataMock({
|
||||
id: '7e5b7033-8c4f-4bdc-9156-6954c268fbb8',
|
||||
standardId: '20202020-74f1-4711-a129-e14ca0ecd744',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workflowVersion',
|
||||
|
|
@ -476,7 +458,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
workflowRun: getFlatFieldMetadataMock({
|
||||
id: '1cd2b19c-f5c5-40b4-ad41-cc7aa3e955b2',
|
||||
standardId: '20202020-96f0-401b-9186-a3a0759225ac',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'workflowRun',
|
||||
|
|
@ -504,7 +485,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
rocket: getFlatFieldMetadataMock({
|
||||
id: 'eebb9590-817b-4a51-88f7-9792aa8e0a59',
|
||||
standardId: '20202020-0be6-444e-88f0-12e0c64ac27d',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'rocket',
|
||||
|
|
@ -532,7 +512,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
pet: getFlatFieldMetadataMock({
|
||||
id: '3cb86390-4ee7-42fa-bd1e-bd6326b47610',
|
||||
standardId: '20202020-d88f-4020-8c85-d6c600903762',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'pet',
|
||||
|
|
@ -560,7 +539,6 @@ export const TIMELINEACTIVITY_FLAT_FIELDS_MOCK = {
|
|||
}),
|
||||
surveyResult: getFlatFieldMetadataMock({
|
||||
id: '06010d88-dc3c-4172-92c9-8c73924f950d',
|
||||
standardId: '20202020-d13a-4342-8df0-df48bd783787',
|
||||
objectMetadataId: '3090f830-c4b1-41a1-8e18-815760830bec',
|
||||
type: FieldMetadataType.RELATION,
|
||||
name: 'surveyResult',
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
|
||||
|
||||
exports[`fromCreateFieldInputToFlatFieldMetadatasToCreate MORPH_RELATION test suite Failure cases should fail when morphRelationsCreationPayload has different relation types 1`] = `
|
||||
{
|
||||
|
|
@ -149,7 +149,6 @@ exports[`fromCreateFieldInputToFlatFieldMetadatasToCreate MORPH_RELATION test su
|
|||
"settings": {
|
||||
"relationType": "ONE_TO_MANY",
|
||||
},
|
||||
"standardId": null,
|
||||
"standardOverrides": null,
|
||||
"type": "MORPH_RELATION",
|
||||
"universalIdentifier": Any<String>,
|
||||
|
|
@ -199,7 +198,6 @@ exports[`fromCreateFieldInputToFlatFieldMetadatasToCreate MORPH_RELATION test su
|
|||
"onDelete": "SET_NULL",
|
||||
"relationType": "MANY_TO_ONE",
|
||||
},
|
||||
"standardId": null,
|
||||
"standardOverrides": null,
|
||||
"type": "RELATION",
|
||||
"universalIdentifier": Any<String>,
|
||||
|
|
@ -249,7 +247,6 @@ exports[`fromCreateFieldInputToFlatFieldMetadatasToCreate MORPH_RELATION test su
|
|||
"settings": {
|
||||
"relationType": "ONE_TO_MANY",
|
||||
},
|
||||
"standardId": null,
|
||||
"standardOverrides": null,
|
||||
"type": "MORPH_RELATION",
|
||||
"universalIdentifier": Any<String>,
|
||||
|
|
@ -299,7 +296,6 @@ exports[`fromCreateFieldInputToFlatFieldMetadatasToCreate MORPH_RELATION test su
|
|||
"onDelete": "SET_NULL",
|
||||
"relationType": "MANY_TO_ONE",
|
||||
},
|
||||
"standardId": null,
|
||||
"standardOverrides": null,
|
||||
"type": "RELATION",
|
||||
"universalIdentifier": Any<String>,
|
||||
|
|
|
|||
|
|
@ -49,7 +49,6 @@ export const getDefaultFlatFieldMetadata = ({
|
|||
objectMetadataId: createFieldInput.objectMetadataId,
|
||||
relationTargetFieldMetadataId: null,
|
||||
relationTargetObjectMetadataId: null,
|
||||
standardId: createFieldInput.standardId ?? null,
|
||||
standardOverrides: null,
|
||||
type: createFieldInput.type,
|
||||
universalIdentifier: createFieldInput.universalIdentifier ?? v4(),
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@ export const fromCreateRoleInputToFlatRoleToCreate = ({
|
|||
|
||||
return {
|
||||
id,
|
||||
standardId: null,
|
||||
label,
|
||||
description: description ?? null,
|
||||
icon: icon ?? null,
|
||||
|
|
|
|||
|
|
@ -37,7 +37,6 @@ export const fromRoleEntityToFlatRole = ({
|
|||
|
||||
return {
|
||||
id: roleEntity.id,
|
||||
standardId: roleEntity.standardId,
|
||||
label: roleEntity.label,
|
||||
description: roleEntity.description,
|
||||
icon: roleEntity.icon,
|
||||
|
|
|
|||
|
|
@ -28,7 +28,6 @@ export const fromCreateSkillInputToFlatSkillToCreate = ({
|
|||
|
||||
return {
|
||||
id,
|
||||
standardId: null,
|
||||
name,
|
||||
label,
|
||||
icon: icon ?? null,
|
||||
|
|
|
|||
|
|
@ -3,7 +3,6 @@ import { type SkillDTO } from 'src/engine/metadata-modules/skill/dtos/skill.dto'
|
|||
|
||||
export const fromFlatSkillToSkillDto = (flatSkill: FlatSkill): SkillDTO => ({
|
||||
id: flatSkill.id,
|
||||
standardId: flatSkill.standardId,
|
||||
name: flatSkill.name,
|
||||
label: flatSkill.label,
|
||||
icon: flatSkill.icon ?? undefined,
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@ export const fromSkillEntityToFlatSkill = ({
|
|||
createdAt: skillEntity.createdAt.toISOString(),
|
||||
updatedAt: skillEntity.updatedAt.toISOString(),
|
||||
id: skillEntity.id,
|
||||
standardId: skillEntity.standardId,
|
||||
name: skillEntity.name,
|
||||
label: skillEntity.label,
|
||||
icon: skillEntity.icon,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { Field, HideField, InputType } from '@nestjs/graphql';
|
||||
|
||||
import { Type } from 'class-transformer';
|
||||
import {
|
||||
IsBoolean,
|
||||
IsNotEmpty,
|
||||
|
|
@ -12,7 +13,6 @@ import {
|
|||
type FieldMetadataSettings,
|
||||
type FieldMetadataType,
|
||||
} from 'twenty-shared/types';
|
||||
import { Type } from 'class-transformer';
|
||||
|
||||
import { IsValidMetadataName } from 'src/engine/decorators/metadata/is-valid-metadata-name.decorator';
|
||||
|
||||
|
|
@ -61,9 +61,6 @@ export class CreateObjectInput {
|
|||
@HideField()
|
||||
applicationId?: string;
|
||||
|
||||
@HideField()
|
||||
standardId?: string;
|
||||
|
||||
@HideField()
|
||||
universalIdentifier?: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -8,10 +8,6 @@ import { v4 } from 'uuid';
|
|||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { type FlatObjectMetadata } from 'src/engine/metadata-modules/flat-object-metadata/types/flat-object-metadata.type';
|
||||
import { getTsVectorColumnExpressionFromFields } from 'src/engine/workspace-manager/utils/get-ts-vector-column-expression.util';
|
||||
import {
|
||||
BASE_OBJECT_STANDARD_FIELD_IDS,
|
||||
CUSTOM_OBJECT_STANDARD_FIELD_IDS,
|
||||
} from 'src/engine/workspace-manager/workspace-migration/constant/standard-field-ids';
|
||||
|
||||
type BuildDefaultFlatFieldMetadataForCustomObjectArgs = {
|
||||
workspaceId: string;
|
||||
|
|
@ -55,7 +51,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: idFieldId,
|
||||
workspaceId,
|
||||
standardId: BASE_OBJECT_STANDARD_FIELD_IDS.id,
|
||||
name: 'id',
|
||||
label: 'Id',
|
||||
icon: 'Icon123',
|
||||
|
|
@ -105,7 +100,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: nameFieldId!,
|
||||
workspaceId,
|
||||
standardId: CUSTOM_OBJECT_STANDARD_FIELD_IDS.name,
|
||||
name: 'name',
|
||||
label: 'Name',
|
||||
icon: 'IconAbc',
|
||||
|
|
@ -152,7 +146,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: createdAtFieldId,
|
||||
workspaceId,
|
||||
standardId: BASE_OBJECT_STANDARD_FIELD_IDS.createdAt,
|
||||
name: 'createdAt',
|
||||
label: 'Creation date',
|
||||
icon: 'IconCalendar',
|
||||
|
|
@ -199,7 +192,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: updatedAtFieldId,
|
||||
workspaceId,
|
||||
standardId: BASE_OBJECT_STANDARD_FIELD_IDS.updatedAt,
|
||||
name: 'updatedAt',
|
||||
label: 'Last update',
|
||||
icon: 'IconCalendarClock',
|
||||
|
|
@ -246,7 +238,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: deletedAtFieldId,
|
||||
workspaceId,
|
||||
standardId: BASE_OBJECT_STANDARD_FIELD_IDS.deletedAt,
|
||||
name: 'deletedAt',
|
||||
label: 'Deleted at',
|
||||
icon: 'IconCalendarClock',
|
||||
|
|
@ -293,7 +284,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: createdByFieldId,
|
||||
workspaceId,
|
||||
standardId: CUSTOM_OBJECT_STANDARD_FIELD_IDS.createdBy,
|
||||
name: 'createdBy',
|
||||
label: 'Created by',
|
||||
icon: 'IconCreativeCommonsSa',
|
||||
|
|
@ -339,7 +329,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: updatedByFieldId,
|
||||
workspaceId,
|
||||
standardId: CUSTOM_OBJECT_STANDARD_FIELD_IDS.updatedBy,
|
||||
name: 'updatedBy',
|
||||
label: 'Updated by',
|
||||
icon: 'IconUserCircle',
|
||||
|
|
@ -385,7 +374,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: positionFieldId,
|
||||
workspaceId,
|
||||
standardId: CUSTOM_OBJECT_STANDARD_FIELD_IDS.position,
|
||||
name: 'position',
|
||||
label: 'Position',
|
||||
icon: 'IconHierarchy2',
|
||||
|
|
@ -438,7 +426,6 @@ export const buildDefaultFlatFieldMetadatasForCustomObject = ({
|
|||
objectMetadataId,
|
||||
universalIdentifier: searchVectorFieldId,
|
||||
workspaceId,
|
||||
standardId: CUSTOM_OBJECT_STANDARD_FIELD_IDS.searchVector,
|
||||
name: 'searchVector',
|
||||
label: 'Search vector',
|
||||
icon: 'IconSearch',
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { FieldMetadataType } from 'twenty-shared/types';
|
||||
import { capitalize, isDefined } from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FeatureFlagMap } from 'src/engine/core-modules/feature-flag/interfaces/feature-flag-map.interface';
|
||||
import { RelationType } from 'src/engine/metadata-modules/field-metadata/interfaces/relation-type.interface';
|
||||
|
|
@ -16,13 +17,7 @@ import {
|
|||
ObjectMetadataException,
|
||||
ObjectMetadataExceptionCode,
|
||||
} from 'src/engine/metadata-modules/object-metadata/object-metadata.exception';
|
||||
import {
|
||||
CUSTOM_OBJECT_STANDARD_FIELD_IDS,
|
||||
ATTACHMENT_STANDARD_FIELD_IDS,
|
||||
TIMELINE_ACTIVITY_STANDARD_FIELD_IDS,
|
||||
} from 'src/engine/workspace-manager/workspace-migration/constant/standard-field-ids';
|
||||
import { STANDARD_OBJECT_ICONS } from 'src/engine/workspace-manager/workspace-migration/constant/standard-object-icons';
|
||||
import { type STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
const DEFAULT_RELATIONS_OBJECTS_STANDARD_IDS = [
|
||||
'timelineActivity',
|
||||
|
|
@ -33,9 +28,10 @@ const DEFAULT_RELATIONS_OBJECTS_STANDARD_IDS = [
|
|||
] as const satisfies (keyof typeof STANDARD_OBJECTS)[];
|
||||
|
||||
const morphIdByRelationObjectNameSingular = {
|
||||
timelineActivity: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
timelineActivity:
|
||||
STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
favorite: null,
|
||||
attachment: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
attachment: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
noteTarget: null,
|
||||
taskTarget: null,
|
||||
} satisfies Record<
|
||||
|
|
@ -121,18 +117,6 @@ export const buildDefaultRelationFlatFieldMetadatasForCustomObject = ({
|
|||
flatEntityId: targetFlatObjectMetadataId,
|
||||
});
|
||||
|
||||
const standardId =
|
||||
CUSTOM_OBJECT_STANDARD_FIELD_IDS[
|
||||
targetFlatObjectMetadata.namePlural as keyof typeof CUSTOM_OBJECT_STANDARD_FIELD_IDS
|
||||
];
|
||||
|
||||
if (!isDefined(standardId)) {
|
||||
throw new ObjectMetadataException(
|
||||
`Standard field ID not found for target object ${targetFlatObjectMetadata.namePlural}`,
|
||||
ObjectMetadataExceptionCode.INTERNAL_SERVER_ERROR,
|
||||
);
|
||||
}
|
||||
|
||||
const icon =
|
||||
STANDARD_OBJECT_ICONS[
|
||||
targetFlatObjectMetadata.nameSingular as keyof typeof STANDARD_OBJECT_ICONS
|
||||
|
|
@ -167,7 +151,6 @@ export const buildDefaultRelationFlatFieldMetadatasForCustomObject = ({
|
|||
name: targetFlatObjectMetadata.namePlural,
|
||||
label: capitalize(targetFlatObjectMetadata.labelPlural),
|
||||
objectMetadataId: sourceFlatObjectMetadata.id,
|
||||
standardId,
|
||||
isSystem: true,
|
||||
relationCreationPayload: {
|
||||
type: RelationType.ONE_TO_MANY,
|
||||
|
|
|
|||
|
|
@ -1,34 +0,0 @@
|
|||
import { type FlatRole } from 'src/engine/metadata-modules/flat-role/types/flat-role.type';
|
||||
|
||||
export const ADMIN_ROLE = {
|
||||
standardId: '20202020-0001-0001-0001-000000000001',
|
||||
label: 'Admin',
|
||||
description: 'Admin role',
|
||||
icon: 'IconUserCog',
|
||||
isEditable: false,
|
||||
canUpdateAllSettings: true,
|
||||
canAccessAllTools: true,
|
||||
canReadAllObjectRecords: true,
|
||||
canUpdateAllObjectRecords: true,
|
||||
canSoftDeleteAllObjectRecords: true,
|
||||
canDestroyAllObjectRecords: true,
|
||||
canBeAssignedToUsers: true,
|
||||
canBeAssignedToAgents: false,
|
||||
canBeAssignedToApiKeys: true,
|
||||
} as const satisfies Pick<
|
||||
FlatRole,
|
||||
| 'standardId'
|
||||
| 'label'
|
||||
| 'description'
|
||||
| 'icon'
|
||||
| 'isEditable'
|
||||
| 'canUpdateAllSettings'
|
||||
| 'canAccessAllTools'
|
||||
| 'canReadAllObjectRecords'
|
||||
| 'canUpdateAllObjectRecords'
|
||||
| 'canSoftDeleteAllObjectRecords'
|
||||
| 'canDestroyAllObjectRecords'
|
||||
| 'canBeAssignedToUsers'
|
||||
| 'canBeAssignedToAgents'
|
||||
| 'canBeAssignedToApiKeys'
|
||||
>;
|
||||
|
|
@ -9,8 +9,8 @@ import { FieldPermissionDTO } from 'src/engine/metadata-modules/object-permissio
|
|||
import { ObjectPermissionDTO } from 'src/engine/metadata-modules/object-permission/dtos/object-permission.dto';
|
||||
import { PermissionFlagDTO } from 'src/engine/metadata-modules/permission-flag/dtos/permission-flag.dto';
|
||||
import { type RoleTargetEntity } from 'src/engine/metadata-modules/role-target/role-target.entity';
|
||||
import { RowLevelPermissionPredicateDTO } from 'src/engine/metadata-modules/row-level-permission-predicate/dtos/row-level-permission-predicate.dto';
|
||||
import { RowLevelPermissionPredicateGroupDTO } from 'src/engine/metadata-modules/row-level-permission-predicate/dtos/row-level-permission-predicate-group.dto';
|
||||
import { RowLevelPermissionPredicateDTO } from 'src/engine/metadata-modules/row-level-permission-predicate/dtos/row-level-permission-predicate.dto';
|
||||
|
||||
@ObjectType('ApiKeyForRole')
|
||||
export class ApiKeyForRoleDTO {
|
||||
|
|
@ -32,9 +32,6 @@ export class RoleDTO {
|
|||
@Field(() => UUIDScalarType, { nullable: false })
|
||||
id: string;
|
||||
|
||||
@Field(() => UUIDScalarType, { nullable: true })
|
||||
standardId?: string;
|
||||
|
||||
@Field(() => UUIDScalarType, { nullable: true })
|
||||
universalIdentifier?: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -23,9 +23,6 @@ export class RoleEntity extends SyncableEntity implements Required<RoleEntity> {
|
|||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@Column({ nullable: true, type: 'uuid' })
|
||||
standardId: string | null;
|
||||
|
||||
@Column({ nullable: false })
|
||||
label: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -9,13 +9,13 @@ import {
|
|||
} from 'twenty-shared/types';
|
||||
import { isDefined } from 'twenty-shared/utils';
|
||||
import { Repository } from 'typeorm';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { WorkspaceCacheProvider } from 'src/engine/workspace-cache/interfaces/workspace-cache-provider.service';
|
||||
|
||||
import { ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
import { RoleEntity } from 'src/engine/metadata-modules/role/role.entity';
|
||||
import { WorkspaceCache } from 'src/engine/workspace-cache/decorators/workspace-cache.decorator';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
const WORKFLOW_STANDARD_OBJECT_UNIVERSAL_IDENTIFIERS = [
|
||||
STANDARD_OBJECTS.workflow.universalIdentifier,
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@ export const fromFlatRoleToRoleDto = ({
|
|||
label,
|
||||
description,
|
||||
icon,
|
||||
standardId,
|
||||
universalIdentifier,
|
||||
}: FlatRole): RoleDTO => {
|
||||
return {
|
||||
|
|
@ -34,7 +33,6 @@ export const fromFlatRoleToRoleDto = ({
|
|||
label,
|
||||
description: description ?? undefined,
|
||||
icon: icon ?? undefined,
|
||||
standardId: standardId ?? undefined,
|
||||
universalIdentifier,
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -4,7 +4,6 @@ import { type RoleEntity } from 'src/engine/metadata-modules/role/role.entity';
|
|||
export const fromRoleEntityToRoleDto = (role: RoleEntity): RoleDTO => {
|
||||
return {
|
||||
id: role.id,
|
||||
standardId: role.standardId ?? undefined,
|
||||
label: role.label,
|
||||
canUpdateAllSettings: role.canUpdateAllSettings,
|
||||
canAccessAllTools: role.canAccessAllTools,
|
||||
|
|
|
|||
|
|
@ -17,9 +17,6 @@ export class SkillDTO {
|
|||
@Field(() => UUIDScalarType)
|
||||
id: string;
|
||||
|
||||
@Field(() => UUIDScalarType, { nullable: true })
|
||||
standardId?: string | null;
|
||||
|
||||
@IsString()
|
||||
@Field()
|
||||
name: string;
|
||||
|
|
|
|||
|
|
@ -22,9 +22,6 @@ export class SkillEntity
|
|||
@PrimaryGeneratedColumn('uuid')
|
||||
id: string;
|
||||
|
||||
@Column({ nullable: true, type: 'uuid' })
|
||||
standardId: string | null;
|
||||
|
||||
@Column({ nullable: false })
|
||||
name: string;
|
||||
|
||||
|
|
|
|||
|
|
@ -12,11 +12,11 @@ import {
|
|||
} from 'src/engine/metadata-modules/permissions/permissions.exception';
|
||||
import { RoleTargetEntity } from 'src/engine/metadata-modules/role-target/role-target.entity';
|
||||
import { RoleTargetService } from 'src/engine/metadata-modules/role-target/services/role-target.service';
|
||||
import { ADMIN_ROLE } from 'src/engine/metadata-modules/role/constants/admin-role';
|
||||
import { RoleEntity } from 'src/engine/metadata-modules/role/role.entity';
|
||||
import { GlobalWorkspaceOrmManager } from 'src/engine/twenty-orm/global-workspace-datasource/global-workspace-orm.manager';
|
||||
import { buildSystemAuthContext } from 'src/engine/twenty-orm/utils/build-system-auth-context.util';
|
||||
import { WorkspaceCacheService } from 'src/engine/workspace-cache/services/workspace-cache.service';
|
||||
import { STANDARD_ROLE } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-role.constant';
|
||||
import { WorkspaceMemberWorkspaceEntity } from 'src/modules/workspace-member/standard-objects/workspace-member.workspace-entity';
|
||||
|
||||
export class UserRoleService {
|
||||
|
|
@ -212,7 +212,8 @@ export class UserRoleService {
|
|||
|
||||
if (
|
||||
isDefined(roleOfUserWorkspace) &&
|
||||
roleOfUserWorkspace.standardId === ADMIN_ROLE.standardId
|
||||
roleOfUserWorkspace.universalIdentifier ===
|
||||
STANDARD_ROLE.admin.universalIdentifier
|
||||
) {
|
||||
const adminRole = roleOfUserWorkspace;
|
||||
|
||||
|
|
@ -273,7 +274,8 @@ export class UserRoleService {
|
|||
|
||||
if (
|
||||
isDefined(currentRole) &&
|
||||
currentRole.standardId === ADMIN_ROLE.standardId
|
||||
currentRole.universalIdentifier ===
|
||||
STANDARD_ROLE.admin.universalIdentifier
|
||||
) {
|
||||
adminRoleIdToValidate = currentRole.id;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -155,7 +155,6 @@ describe('WorkspaceEntityManager', () => {
|
|||
isUnique: false,
|
||||
options: null,
|
||||
settings: null,
|
||||
standardId: null,
|
||||
standardOverrides: null,
|
||||
workspaceId: 'test-workspace-id',
|
||||
viewFieldIds: [],
|
||||
|
|
|
|||
|
|
@ -1,11 +0,0 @@
|
|||
import { type FactoryProvider, type ModuleMetadata } from '@nestjs/common';
|
||||
|
||||
export interface TwentyORMOptions {
|
||||
[key: string]: unknown;
|
||||
}
|
||||
|
||||
export type TwentyORMModuleAsyncOptions = {
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
useFactory: (...args: any[]) => TwentyORMOptions | Promise<TwentyORMOptions>;
|
||||
} & Pick<ModuleMetadata, 'imports'> &
|
||||
Pick<FactoryProvider, 'inject'>;
|
||||
|
|
@ -1,94 +0,0 @@
|
|||
import { type ObjectType } from 'typeorm';
|
||||
import { type RelationOnDeleteAction } from 'twenty-shared/types';
|
||||
|
||||
import { type RelationType } from 'src/engine/metadata-modules/field-metadata/interfaces/relation-type.interface';
|
||||
import { type Gate } from 'src/engine/twenty-orm/interfaces/gate.interface';
|
||||
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
|
||||
export type WorkspaceDynamicRelationMetadataArgsFactory = (
|
||||
oppositeObjectMetadata: ObjectMetadataEntity,
|
||||
) => {
|
||||
/**
|
||||
* Standard id.
|
||||
*/
|
||||
readonly standardId: string;
|
||||
|
||||
/**
|
||||
* Relation name.
|
||||
*/
|
||||
readonly name: string;
|
||||
|
||||
/**
|
||||
* Relation label.
|
||||
*/
|
||||
readonly label: string;
|
||||
|
||||
/**
|
||||
* Relation description.
|
||||
*/
|
||||
readonly description?: string;
|
||||
|
||||
/**
|
||||
* Relation icon.
|
||||
*/
|
||||
readonly icon?: string;
|
||||
|
||||
/**
|
||||
* Relation join column.
|
||||
*/
|
||||
readonly joinColumn?: string;
|
||||
};
|
||||
|
||||
export interface WorkspaceDynamicRelationMetadataArgs {
|
||||
/**
|
||||
* Class to which relation is applied.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/**
|
||||
* Factory function
|
||||
*/
|
||||
readonly argsFactory: WorkspaceDynamicRelationMetadataArgsFactory;
|
||||
|
||||
/**
|
||||
* Relation type.
|
||||
*/
|
||||
readonly type: RelationType;
|
||||
|
||||
/**
|
||||
* Relation inverse side target.
|
||||
*/
|
||||
readonly inverseSideTarget: () => ObjectType<object>;
|
||||
|
||||
/**
|
||||
* Relation inverse side field key.
|
||||
*/
|
||||
readonly inverseSideFieldKey?: string;
|
||||
|
||||
/**
|
||||
* Relation on delete action.
|
||||
*/
|
||||
readonly onDelete?: RelationOnDeleteAction;
|
||||
|
||||
/**
|
||||
* Is primary field.
|
||||
*/
|
||||
readonly isPrimary: boolean;
|
||||
|
||||
/**
|
||||
* Is system field.
|
||||
*/
|
||||
readonly isSystem: boolean;
|
||||
|
||||
/**
|
||||
* Is nullable field.
|
||||
*/
|
||||
readonly isNullable: boolean;
|
||||
|
||||
/**
|
||||
* Field gate.
|
||||
*/
|
||||
readonly gate?: Gate;
|
||||
}
|
||||
|
|
@ -1,85 +0,0 @@
|
|||
import { type Gate } from 'src/engine/twenty-orm/interfaces/gate.interface';
|
||||
|
||||
import { type WorkspaceEntityDuplicateCriteria } from 'src/engine/api/graphql/workspace-query-builder/types/workspace-entity-duplicate-criteria.type';
|
||||
|
||||
export interface WorkspaceEntityMetadataArgs {
|
||||
/**
|
||||
* Standard id.
|
||||
*/
|
||||
readonly standardId: string;
|
||||
|
||||
/**
|
||||
* Class to which table is applied.
|
||||
* Function target is a table defined in the class.
|
||||
* String target is a table defined in a json schema.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/**
|
||||
* Entity name.
|
||||
*/
|
||||
readonly nameSingular: string;
|
||||
readonly namePlural: string;
|
||||
|
||||
/**
|
||||
* Entity label.
|
||||
*/
|
||||
readonly labelSingular: string;
|
||||
readonly labelPlural: string;
|
||||
|
||||
/**
|
||||
* Entity description.
|
||||
*/
|
||||
readonly description?: string;
|
||||
|
||||
/**
|
||||
* Entity icon.
|
||||
*/
|
||||
readonly icon?: string;
|
||||
|
||||
/**
|
||||
* Entity shortcut.
|
||||
*/
|
||||
readonly shortcut?: string;
|
||||
|
||||
/**
|
||||
* Is audit logged.
|
||||
*/
|
||||
readonly isAuditLogged: boolean;
|
||||
|
||||
/**
|
||||
* Is system object.
|
||||
*/
|
||||
readonly isSystem: boolean;
|
||||
|
||||
/**
|
||||
* Is UI read-only object.
|
||||
*/
|
||||
readonly isUIReadOnly: boolean;
|
||||
|
||||
/**
|
||||
* Entity gate.
|
||||
*/
|
||||
readonly gate?: Gate;
|
||||
|
||||
/**
|
||||
* Label identifier.
|
||||
*/
|
||||
readonly labelIdentifierStandardId: string | null;
|
||||
|
||||
/**
|
||||
* Image identifier.
|
||||
*/
|
||||
readonly imageIdentifierStandardId: string | null;
|
||||
|
||||
/**
|
||||
* Duplicate criteria.
|
||||
*/
|
||||
readonly duplicateCriteria?: WorkspaceEntityDuplicateCriteria[];
|
||||
|
||||
/**
|
||||
* Is searchable object.
|
||||
*/
|
||||
readonly isSearchable: boolean;
|
||||
}
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
import { type Gate } from 'src/engine/twenty-orm/interfaces/gate.interface';
|
||||
|
||||
export interface WorkspaceExtendedEntityMetadataArgs {
|
||||
/**
|
||||
* Class to which table is applied.
|
||||
* Function target is a table defined in the class.
|
||||
* String target is a table defined in a json schema.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/**
|
||||
* Entity gate.
|
||||
*/
|
||||
readonly gate?: Gate;
|
||||
}
|
||||
|
|
@ -1,117 +0,0 @@
|
|||
import {
|
||||
type FieldMetadataOptions,
|
||||
type FieldMetadataSettings,
|
||||
type FieldMetadataType,
|
||||
type FieldMetadataDefaultValue,
|
||||
} from 'twenty-shared/types';
|
||||
|
||||
import { type Gate } from 'src/engine/twenty-orm/interfaces/gate.interface';
|
||||
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
|
||||
export interface WorkspaceFieldMetadataArgs {
|
||||
/**
|
||||
* Standard id.
|
||||
*/
|
||||
readonly standardId: string;
|
||||
|
||||
/**
|
||||
* Class to which field is applied.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/**
|
||||
* Field name.
|
||||
*/
|
||||
readonly name: string;
|
||||
|
||||
/**
|
||||
* Field label.
|
||||
*/
|
||||
readonly label: string | ((objectMetadata: ObjectMetadataEntity) => string);
|
||||
|
||||
/**
|
||||
* Field type.
|
||||
*/
|
||||
readonly type: FieldMetadataType;
|
||||
|
||||
/**
|
||||
* Field description.
|
||||
*/
|
||||
readonly description?:
|
||||
| string
|
||||
| ((objectMetadata: ObjectMetadataEntity) => string);
|
||||
|
||||
/**
|
||||
* Field icon.
|
||||
*/
|
||||
readonly icon?: string;
|
||||
|
||||
/**
|
||||
* Field default value.
|
||||
*/
|
||||
readonly defaultValue?: FieldMetadataDefaultValue;
|
||||
|
||||
/**
|
||||
* Field options.
|
||||
*/
|
||||
readonly options?: FieldMetadataOptions;
|
||||
|
||||
/**
|
||||
* Field settings.
|
||||
*/
|
||||
readonly settings?: FieldMetadataSettings;
|
||||
|
||||
/**
|
||||
* Is primary field.
|
||||
*/
|
||||
readonly isPrimary: boolean;
|
||||
|
||||
/**
|
||||
* Is system field.
|
||||
*/
|
||||
readonly isSystem: boolean;
|
||||
|
||||
/**
|
||||
* Is UI read-only field.
|
||||
*/
|
||||
readonly isUIReadOnly: boolean;
|
||||
|
||||
/**
|
||||
* Is nullable field.
|
||||
*/
|
||||
readonly isNullable: boolean;
|
||||
|
||||
/**
|
||||
* Is unique field.
|
||||
*/
|
||||
readonly isUnique: boolean;
|
||||
|
||||
/**
|
||||
* Field gate.
|
||||
*/
|
||||
readonly gate?: Gate;
|
||||
|
||||
/**
|
||||
* Is deprecated field.
|
||||
*/
|
||||
readonly isDeprecated?: boolean;
|
||||
|
||||
/**
|
||||
* Is active field.
|
||||
*/
|
||||
readonly isActive?: boolean;
|
||||
|
||||
/**
|
||||
* Is active field.
|
||||
*/
|
||||
readonly generatedType?: 'STORED' | 'VIRTUAL';
|
||||
|
||||
/**
|
||||
* Is active field.
|
||||
*/
|
||||
readonly asExpression?: string;
|
||||
|
||||
readonly isLabelSyncedWithName: boolean;
|
||||
}
|
||||
|
|
@ -1,41 +0,0 @@
|
|||
import { type Gate } from 'src/engine/twenty-orm/interfaces/gate.interface';
|
||||
|
||||
import { type IndexType } from 'src/engine/metadata-modules/index-metadata/types/indexType.types';
|
||||
|
||||
export interface WorkspaceIndexMetadataArgs {
|
||||
/**
|
||||
* Class to which index is applied.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/*
|
||||
* Index name.
|
||||
*/
|
||||
name: string;
|
||||
|
||||
/*
|
||||
* Index columns.
|
||||
*/
|
||||
columns: string[];
|
||||
|
||||
/**
|
||||
* Is index unique.
|
||||
*/
|
||||
isUnique: boolean;
|
||||
|
||||
/*
|
||||
* Index type. Defaults to Btree.
|
||||
*/
|
||||
type?: IndexType;
|
||||
|
||||
/**
|
||||
* Index where clause.
|
||||
*/
|
||||
whereClause: string | null;
|
||||
|
||||
/**
|
||||
* Field gate.
|
||||
*/
|
||||
readonly gate?: Gate;
|
||||
}
|
||||
|
|
@ -1,17 +0,0 @@
|
|||
export interface WorkspaceJoinColumnsMetadataArgs {
|
||||
/**
|
||||
* Class to which relation is applied.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/**
|
||||
* Relation name.
|
||||
*/
|
||||
readonly relationName: string;
|
||||
|
||||
/**
|
||||
* Relation label.
|
||||
*/
|
||||
readonly joinColumn: string;
|
||||
}
|
||||
|
|
@ -1,104 +0,0 @@
|
|||
import { type ObjectType } from 'typeorm';
|
||||
import { type RelationOnDeleteAction } from 'twenty-shared/types';
|
||||
|
||||
import { type RelationType } from 'src/engine/metadata-modules/field-metadata/interfaces/relation-type.interface';
|
||||
import { type Gate } from 'src/engine/twenty-orm/interfaces/gate.interface';
|
||||
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
|
||||
export interface WorkspaceRelationMetadataArgs {
|
||||
/**
|
||||
* Standard id.
|
||||
*/
|
||||
readonly standardId: string;
|
||||
|
||||
/**
|
||||
* Class to which relation is applied.
|
||||
*/
|
||||
|
||||
readonly target: Function;
|
||||
|
||||
/**
|
||||
* Relation name.
|
||||
*/
|
||||
readonly name: string;
|
||||
|
||||
/**
|
||||
* Relation label.
|
||||
*/
|
||||
readonly label: string | ((objectMetadata: ObjectMetadataEntity) => string);
|
||||
|
||||
/**
|
||||
* Relation type.
|
||||
*/
|
||||
readonly type: RelationType;
|
||||
|
||||
/**
|
||||
* Relation description.
|
||||
*/
|
||||
readonly description?:
|
||||
| string
|
||||
| ((objectMetadata: ObjectMetadataEntity) => string);
|
||||
|
||||
/**
|
||||
* Relation icon.
|
||||
*/
|
||||
readonly icon?: string;
|
||||
|
||||
/**
|
||||
* Relation inverse side target.
|
||||
*/
|
||||
readonly inverseSideTarget: () => ObjectType<object>;
|
||||
|
||||
/**
|
||||
* Relation inverse side field key.
|
||||
*/
|
||||
readonly inverseSideFieldKey?: string;
|
||||
|
||||
/**
|
||||
* Relation on delete action.
|
||||
*/
|
||||
readonly onDelete?: RelationOnDeleteAction;
|
||||
|
||||
/**
|
||||
* Is primary field.
|
||||
*/
|
||||
readonly isPrimary: boolean;
|
||||
|
||||
/**
|
||||
* Is system field.
|
||||
*/
|
||||
readonly isSystem: boolean;
|
||||
|
||||
/**
|
||||
* Is UI read-only field.
|
||||
*/
|
||||
readonly isUIReadOnly: boolean;
|
||||
|
||||
/**
|
||||
* Is nullable field.
|
||||
*/
|
||||
readonly isNullable: boolean;
|
||||
|
||||
/**
|
||||
* Field gate.
|
||||
*/
|
||||
readonly gate?: Gate;
|
||||
|
||||
/**
|
||||
* Is active field.
|
||||
*/
|
||||
readonly isActive?: boolean;
|
||||
|
||||
readonly isLabelSyncedWithName: boolean;
|
||||
|
||||
/**
|
||||
* Is morph relation.
|
||||
*/
|
||||
readonly isMorphRelation: boolean;
|
||||
|
||||
/**
|
||||
* Morph id.
|
||||
*/
|
||||
readonly morphId?: string;
|
||||
}
|
||||
|
|
@ -87,7 +87,6 @@ describe('WorkspaceRepository', () => {
|
|||
options: null,
|
||||
settings: null,
|
||||
morphId: null,
|
||||
standardId: null,
|
||||
standardOverrides: null,
|
||||
applicationId: 'application-id',
|
||||
relationTargetFieldMetadataId: null,
|
||||
|
|
|
|||
|
|
@ -1,175 +0,0 @@
|
|||
import { type WorkspaceDynamicRelationMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-dynamic-relation-metadata-args.interface';
|
||||
import { type WorkspaceEntityMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-entity-metadata-args.interface';
|
||||
import { type WorkspaceExtendedEntityMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-extended-entity-metadata-args.interface';
|
||||
import { type WorkspaceFieldMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-field-metadata-args.interface';
|
||||
import { type WorkspaceIndexMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-index-metadata-args.interface';
|
||||
import { type WorkspaceJoinColumnsMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-join-columns-metadata-args.interface';
|
||||
import { type WorkspaceRelationMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-relation-metadata-args.interface';
|
||||
|
||||
export class MetadataArgsStorage {
|
||||
private readonly entities: WorkspaceEntityMetadataArgs[] = [];
|
||||
private readonly extendedEntities: WorkspaceExtendedEntityMetadataArgs[] = [];
|
||||
private readonly fields: WorkspaceFieldMetadataArgs[] = [];
|
||||
private readonly relations: WorkspaceRelationMetadataArgs[] = [];
|
||||
private readonly dynamicRelations: WorkspaceDynamicRelationMetadataArgs[] =
|
||||
[];
|
||||
private readonly indexes: WorkspaceIndexMetadataArgs[] = [];
|
||||
private readonly joinColumns: WorkspaceJoinColumnsMetadataArgs[] = [];
|
||||
|
||||
addEntities(...entities: WorkspaceEntityMetadataArgs[]): void {
|
||||
this.entities.push(...entities);
|
||||
}
|
||||
|
||||
addExtendedEntities(
|
||||
...extendedEntities: WorkspaceExtendedEntityMetadataArgs[]
|
||||
): void {
|
||||
this.extendedEntities.push(...extendedEntities);
|
||||
}
|
||||
|
||||
addFields(...fields: WorkspaceFieldMetadataArgs[]): void {
|
||||
this.fields.push(...fields);
|
||||
}
|
||||
|
||||
addRelations(...relations: WorkspaceRelationMetadataArgs[]): void {
|
||||
this.relations.push(...relations);
|
||||
}
|
||||
|
||||
addIndexes(...indexes: WorkspaceIndexMetadataArgs[]): void {
|
||||
this.indexes.push(...indexes);
|
||||
}
|
||||
|
||||
addDynamicRelations(
|
||||
...dynamicRelations: WorkspaceDynamicRelationMetadataArgs[]
|
||||
): void {
|
||||
this.dynamicRelations.push(...dynamicRelations);
|
||||
}
|
||||
|
||||
addJoinColumns(...joinColumns: WorkspaceJoinColumnsMetadataArgs[]): void {
|
||||
this.joinColumns.push(...joinColumns);
|
||||
}
|
||||
|
||||
filterEntities(
|
||||
target: Function | string,
|
||||
): WorkspaceEntityMetadataArgs | undefined;
|
||||
|
||||
filterEntities(target: (Function | string)[]): WorkspaceEntityMetadataArgs[];
|
||||
|
||||
filterEntities(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): WorkspaceEntityMetadataArgs | undefined | WorkspaceEntityMetadataArgs[] {
|
||||
const objects = this.filterByTarget(this.entities, target);
|
||||
|
||||
return Array.isArray(objects) ? objects[0] : objects;
|
||||
}
|
||||
|
||||
filterExtendedEntities(
|
||||
target: Function | string,
|
||||
): WorkspaceExtendedEntityMetadataArgs | undefined;
|
||||
|
||||
filterExtendedEntities(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
):
|
||||
| WorkspaceExtendedEntityMetadataArgs
|
||||
| undefined
|
||||
| WorkspaceExtendedEntityMetadataArgs[] {
|
||||
const objects = this.filterByTarget(this.extendedEntities, target);
|
||||
|
||||
return Array.isArray(objects) ? objects[0] : objects;
|
||||
}
|
||||
|
||||
filterFields(target: Function | string): WorkspaceFieldMetadataArgs[];
|
||||
|
||||
filterFields(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): WorkspaceFieldMetadataArgs[] {
|
||||
return this.filterByTarget(this.fields, target);
|
||||
}
|
||||
|
||||
filterRelations(target: Function | string): WorkspaceRelationMetadataArgs[];
|
||||
|
||||
filterRelations(
|
||||
target: (Function | string)[],
|
||||
): WorkspaceRelationMetadataArgs[];
|
||||
|
||||
filterRelations(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): WorkspaceRelationMetadataArgs[] {
|
||||
return this.filterByTarget(this.relations, target);
|
||||
}
|
||||
|
||||
filterIndexes(target: Function | string): WorkspaceIndexMetadataArgs[];
|
||||
|
||||
filterIndexes(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): WorkspaceIndexMetadataArgs[] {
|
||||
return this.filterByTarget(this.indexes, target);
|
||||
}
|
||||
|
||||
filterDynamicRelations(
|
||||
target: Function | string,
|
||||
): WorkspaceDynamicRelationMetadataArgs[];
|
||||
|
||||
filterDynamicRelations(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): WorkspaceDynamicRelationMetadataArgs[] {
|
||||
return this.filterByTarget(this.dynamicRelations, target);
|
||||
}
|
||||
|
||||
filterJoinColumns(
|
||||
target: Function | string,
|
||||
): WorkspaceJoinColumnsMetadataArgs[];
|
||||
|
||||
filterJoinColumns(
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): WorkspaceJoinColumnsMetadataArgs[] {
|
||||
return this.filterByTarget(this.joinColumns, target);
|
||||
}
|
||||
|
||||
protected filterByTarget<T extends { target: Function | string }>(
|
||||
array: T[],
|
||||
target: (Function | string) | (Function | string)[],
|
||||
): T[] {
|
||||
if (Array.isArray(target)) {
|
||||
return target.flatMap((targetItem) => {
|
||||
if (typeof targetItem === 'function') {
|
||||
return this.collectFromClass(array, targetItem);
|
||||
}
|
||||
|
||||
return this.collectFromString(array, targetItem);
|
||||
});
|
||||
} else {
|
||||
return typeof target === 'function'
|
||||
? this.collectFromClass(array, target)
|
||||
: this.collectFromString(array, target);
|
||||
}
|
||||
}
|
||||
|
||||
// Private helper to collect metadata from class prototypes
|
||||
private collectFromClass<T extends { target: Function | string }>(
|
||||
array: T[],
|
||||
cls: Function,
|
||||
): T[] {
|
||||
const collectedMetadata: T[] = [];
|
||||
let currentTarget = cls;
|
||||
|
||||
// Collect metadata from the current class and all its parent classes
|
||||
while (currentTarget !== Function.prototype) {
|
||||
collectedMetadata.push(
|
||||
...array.filter((item) => item.target === currentTarget),
|
||||
);
|
||||
currentTarget = Object.getPrototypeOf(currentTarget);
|
||||
}
|
||||
|
||||
return collectedMetadata;
|
||||
}
|
||||
|
||||
// Private helper to collect metadata directly by string comparison
|
||||
private collectFromString<T extends { target: Function | string }>(
|
||||
array: T[],
|
||||
targetString: string,
|
||||
): T[] {
|
||||
return array.filter((item) => item.target === targetString);
|
||||
}
|
||||
}
|
||||
|
||||
export const metadataArgsStorage = new MetadataArgsStorage();
|
||||
|
|
@ -233,7 +233,6 @@ describe('computeRelationConnectQueryConfigs', () => {
|
|||
description: null,
|
||||
standardOverrides: null,
|
||||
isUIReadOnly: false,
|
||||
standardId: null,
|
||||
labelIdentifierFieldMetadataId: null,
|
||||
imageIdentifierFieldMetadataId: null,
|
||||
duplicateCriteria: null,
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ import {
|
|||
isDefined,
|
||||
isNonEmptyArray,
|
||||
} from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import type { ObjectLiteral } from 'typeorm';
|
||||
|
||||
|
|
@ -26,7 +27,6 @@ import {
|
|||
TwentyORMExceptionCode,
|
||||
} from 'src/engine/twenty-orm/exceptions/twenty-orm.exception';
|
||||
import { type DatabaseBatchEventInput } from 'src/engine/workspace-event-emitter/workspace-event-emitter';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
export const formatTwentyOrmEventToDatabaseBatchEvent = <
|
||||
T extends ObjectLiteral,
|
||||
|
|
|
|||
|
|
@ -1,61 +0,0 @@
|
|||
import { RelationType } from 'src/engine/metadata-modules/field-metadata/interfaces/relation-type.interface';
|
||||
import { type WorkspaceJoinColumnsMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-join-columns-metadata-args.interface';
|
||||
import { type WorkspaceRelationMetadataArgs } from 'src/engine/twenty-orm/interfaces/workspace-relation-metadata-args.interface';
|
||||
|
||||
import {
|
||||
RelationException,
|
||||
RelationExceptionCode,
|
||||
} from 'src/engine/twenty-orm/exceptions/relation.exception';
|
||||
import { metadataArgsStorage } from 'src/engine/twenty-orm/storage/metadata-args.storage';
|
||||
|
||||
export const getJoinColumn = (
|
||||
joinColumnsMetadataArgsCollection: WorkspaceJoinColumnsMetadataArgs[],
|
||||
relationMetadataArgs: WorkspaceRelationMetadataArgs,
|
||||
): string | null => {
|
||||
if (relationMetadataArgs.type === RelationType.ONE_TO_MANY) {
|
||||
return null;
|
||||
}
|
||||
|
||||
const inverseSideTarget = relationMetadataArgs.inverseSideTarget();
|
||||
const inverseSideJoinColumnsMetadataArgsCollection =
|
||||
metadataArgsStorage.filterJoinColumns(inverseSideTarget);
|
||||
const filteredJoinColumnsMetadataArgsCollection =
|
||||
joinColumnsMetadataArgsCollection.filter(
|
||||
(joinColumnsMetadataArgs) =>
|
||||
joinColumnsMetadataArgs.relationName === relationMetadataArgs.name,
|
||||
);
|
||||
const oppositeFilteredJoinColumnsMetadataArgsCollection =
|
||||
inverseSideJoinColumnsMetadataArgsCollection.filter(
|
||||
(joinColumnsMetadataArgs) =>
|
||||
joinColumnsMetadataArgs.relationName === relationMetadataArgs.name,
|
||||
);
|
||||
|
||||
if (
|
||||
filteredJoinColumnsMetadataArgsCollection.length > 0 &&
|
||||
oppositeFilteredJoinColumnsMetadataArgsCollection.length > 0
|
||||
) {
|
||||
throw new RelationException(
|
||||
`Join column for ${relationMetadataArgs.name} relation is present on both sides`,
|
||||
RelationExceptionCode.RELATION_JOIN_COLUMN_ON_BOTH_SIDES,
|
||||
);
|
||||
}
|
||||
|
||||
// Check if there are multiple join columns for the relation
|
||||
if (filteredJoinColumnsMetadataArgsCollection.length > 1) {
|
||||
throw new RelationException(
|
||||
`Multiple join columns found for relation ${relationMetadataArgs.name}`,
|
||||
RelationExceptionCode.MULTIPLE_JOIN_COLUMNS_FOUND,
|
||||
);
|
||||
}
|
||||
|
||||
const joinColumnsMetadataArgs = filteredJoinColumnsMetadataArgsCollection[0];
|
||||
|
||||
if (!joinColumnsMetadataArgs) {
|
||||
throw new RelationException(
|
||||
`Join column is missing for relation ${relationMetadataArgs.name}`,
|
||||
RelationExceptionCode.MISSING_RELATION_JOIN_COLUMN,
|
||||
);
|
||||
}
|
||||
|
||||
return joinColumnsMetadataArgs.joinColumn;
|
||||
};
|
||||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
export const shouldSeedWorkspaceFavorite = (
|
||||
objectMetadataId: string,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { CalendarStartDay } from 'twenty-shared/constants';
|
||||
import { isDefined } from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { AggregateOperations } from 'src/engine/api/graphql/graphql-query-runner/constants/aggregate-operations.constant';
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
|
|
@ -11,7 +12,6 @@ import { PAGE_LAYOUT_TAB_SEEDS } from 'src/engine/workspace-manager/dev-seeder/c
|
|||
import { PAGE_LAYOUT_WIDGET_SEEDS } from 'src/engine/workspace-manager/dev-seeder/core/constants/page-layout-widget-seeds.constant';
|
||||
import { type SeederFlatPageLayoutWidget } from 'src/engine/workspace-manager/dev-seeder/core/types/seeder-flat-page-layout-widget.type';
|
||||
import { generateSeedId } from 'src/engine/workspace-manager/dev-seeder/core/utils/generate-seed-id.util';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
const getFieldId = (
|
||||
object: ObjectMetadataEntity | undefined,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { CalendarStartDay } from 'twenty-shared/constants';
|
||||
import { isDefined } from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { AggregateOperations } from 'src/engine/api/graphql/graphql-query-runner/constants/aggregate-operations.constant';
|
||||
import { type ObjectMetadataEntity } from 'src/engine/metadata-modules/object-metadata/object-metadata.entity';
|
||||
|
|
@ -14,7 +15,6 @@ import { PAGE_LAYOUT_WIDGET_SEEDS } from 'src/engine/workspace-manager/dev-seede
|
|||
import { type SeederFlatPageLayoutWidget } from 'src/engine/workspace-manager/dev-seeder/core/types/seeder-flat-page-layout-widget.type';
|
||||
import { generateSeedId } from 'src/engine/workspace-manager/dev-seeder/core/utils/generate-seed-id.util';
|
||||
import { getPageLayoutWidgetDataSeedsV2 } from 'src/engine/workspace-manager/dev-seeder/core/utils/get-page-layout-widget-data-seeds-v2.util';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
|
||||
const getFieldId = (
|
||||
object: ObjectMetadataEntity | undefined,
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
import { HELPER_AGENT } from 'src/engine/workspace-manager/workspace-migration/constant/standard-agent-ids';
|
||||
|
||||
export const STANDARD_AGENT = {
|
||||
helper: {
|
||||
universalIdentifier: HELPER_AGENT.standardId,
|
||||
universalIdentifier: '20202020-0002-0001-0001-000000000004',
|
||||
},
|
||||
} as const satisfies Record<
|
||||
string,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import { STANDARD_OBJECTS } from './standard-object.constant';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
export const STANDARD_NAVIGATION_MENU_ITEMS = {
|
||||
allCompanies: {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
import { ADMIN_ROLE } from 'src/engine/metadata-modules/role/constants/admin-role';
|
||||
|
||||
export const STANDARD_ROLE = {
|
||||
admin: { universalIdentifier: ADMIN_ROLE.standardId },
|
||||
admin: { universalIdentifier: '20202020-0001-0001-0001-000000000001' },
|
||||
} as const satisfies Record<string, { universalIdentifier: string }>;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import { Injectable } from '@nestjs/common';
|
||||
|
||||
import { isDefined } from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { ApplicationService } from 'src/engine/core-modules/application/services/application.service';
|
||||
import { TwentyConfigService } from 'src/engine/core-modules/twenty-config/twenty-config.service';
|
||||
|
|
@ -14,7 +15,6 @@ import { FlatView } from 'src/engine/metadata-modules/flat-view/types/flat-view.
|
|||
import { GlobalWorkspaceOrmManager } from 'src/engine/twenty-orm/global-workspace-datasource/global-workspace-orm.manager';
|
||||
import { buildSystemAuthContext } from 'src/engine/twenty-orm/utils/build-system-auth-context.util';
|
||||
import { WorkspaceCacheService } from 'src/engine/workspace-cache/services/workspace-cache.service';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { TWENTY_STANDARD_ALL_METADATA_NAME } from 'src/engine/workspace-manager/twenty-standard-application/constants/twenty-standard-all-metadata-name.constant';
|
||||
import { computeTwentyStandardApplicationAllFlatEntityMaps } from 'src/engine/workspace-manager/twenty-standard-application/utils/twenty-standard-application-all-flat-entity-maps.constant';
|
||||
import { WorkspaceMigrationBuilderException } from 'src/engine/workspace-manager/workspace-migration/exceptions/workspace-migration-builder-exception';
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
import { type STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
|
||||
export type AllStandardObjectFieldName<T extends AllStandardObjectName> =
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
import { type STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
|
||||
export type AllStandardObjectIndexName<T extends AllStandardObjectName> =
|
||||
|
|
|
|||
|
|
@ -1,3 +1,3 @@
|
|||
import { type STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
export type AllStandardObjectName = keyof typeof STANDARD_OBJECTS;
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
import { type STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
|
||||
export type AllStandardObjectView<T extends AllStandardObjectName> =
|
||||
|
|
|
|||
|
|
@ -49,7 +49,6 @@ export const createStandardAgentFlatMetadata = ({
|
|||
return {
|
||||
id: v4(),
|
||||
universalIdentifier,
|
||||
standardId: universalIdentifier,
|
||||
name,
|
||||
label,
|
||||
icon,
|
||||
|
|
|
|||
|
|
@ -4,9 +4,9 @@ import {
|
|||
RelationOnDeleteAction,
|
||||
RelationType,
|
||||
} from 'twenty-shared/types';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { ATTACHMENT_STANDARD_FIELD_IDS } from 'src/engine/workspace-manager/workspace-migration/constant/standard-field-ids';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
import {
|
||||
type CreateStandardFieldArgs,
|
||||
|
|
@ -237,7 +237,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetTask',
|
||||
label: 'Task',
|
||||
description: 'Attachment task',
|
||||
|
|
@ -262,7 +262,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetNote',
|
||||
label: 'Note',
|
||||
description: 'Attachment note',
|
||||
|
|
@ -287,7 +287,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetPerson',
|
||||
label: 'Person',
|
||||
description: 'Attachment person',
|
||||
|
|
@ -312,7 +312,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetCompany',
|
||||
label: 'Company',
|
||||
description: 'Attachment company',
|
||||
|
|
@ -337,7 +337,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetOpportunity',
|
||||
label: 'Opportunity',
|
||||
description: 'Attachment opportunity',
|
||||
|
|
@ -362,7 +362,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetDashboard',
|
||||
label: 'Dashboard',
|
||||
description: 'Attachment dashboard',
|
||||
|
|
@ -387,7 +387,7 @@ export const buildAttachmentStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: ATTACHMENT_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.attachment.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetWorkflow',
|
||||
label: 'Workflow',
|
||||
description: 'Attachment workflow',
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import {
|
|||
RelationOnDeleteAction,
|
||||
RelationType,
|
||||
} from 'twenty-shared/types';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
|
|
@ -12,7 +13,6 @@ import {
|
|||
type CreateStandardFieldArgs,
|
||||
} from 'src/engine/workspace-manager/twenty-standard-application/utils/field-metadata/create-standard-field-flat-metadata.util';
|
||||
import { createStandardRelationFieldFlatMetadata } from 'src/engine/workspace-manager/twenty-standard-application/utils/field-metadata/create-standard-relation-field-flat-metadata.util';
|
||||
import { TIMELINE_ACTIVITY_STANDARD_FIELD_IDS } from 'src/engine/workspace-manager/workspace-migration/constant/standard-field-ids';
|
||||
|
||||
export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
||||
now,
|
||||
|
|
@ -241,7 +241,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetPerson',
|
||||
label: 'Person',
|
||||
description: 'Event person',
|
||||
|
|
@ -266,7 +266,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetCompany',
|
||||
label: 'Company',
|
||||
description: 'Event company',
|
||||
|
|
@ -291,7 +291,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetOpportunity',
|
||||
label: 'Opportunity',
|
||||
description: 'Event opportunity',
|
||||
|
|
@ -316,7 +316,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetNote',
|
||||
label: 'Note',
|
||||
description: 'Event note',
|
||||
|
|
@ -341,7 +341,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetTask',
|
||||
label: 'Task',
|
||||
description: 'Event task',
|
||||
|
|
@ -366,7 +366,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetWorkflow',
|
||||
label: 'Workflow',
|
||||
description: 'Event workflow',
|
||||
|
|
@ -391,7 +391,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetWorkflowVersion',
|
||||
label: 'WorkflowVersion',
|
||||
description: 'Event workflow version',
|
||||
|
|
@ -416,7 +416,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetWorkflowRun',
|
||||
label: 'Workflow Run',
|
||||
description: 'Event workflow run',
|
||||
|
|
@ -441,7 +441,7 @@ export const buildTimelineActivityStandardFlatFieldMetadatas = ({
|
|||
workspaceId,
|
||||
context: {
|
||||
type: FieldMetadataType.MORPH_RELATION,
|
||||
morphId: TIMELINE_ACTIVITY_STANDARD_FIELD_IDS.targetMorphId,
|
||||
morphId: STANDARD_OBJECTS.timelineActivity.morphIds.targetMorphId.morphId,
|
||||
fieldName: 'targetDashboard',
|
||||
label: 'Dashboard',
|
||||
description: 'Event dashboard',
|
||||
|
|
|
|||
|
|
@ -6,9 +6,9 @@ import {
|
|||
type FieldMetadataType,
|
||||
} from 'twenty-shared/types';
|
||||
import { v4 } from 'uuid';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
import { type StandardBuilderArgs } from 'src/engine/workspace-manager/twenty-standard-application/types/metadata-standard-buillder-args.type';
|
||||
|
|
@ -70,7 +70,6 @@ export const createStandardFieldFlatMetadata = <
|
|||
return {
|
||||
id: fieldIds[fieldName].id,
|
||||
universalIdentifier: fieldDefinition.universalIdentifier,
|
||||
standardId: fieldDefinition.universalIdentifier,
|
||||
applicationId: twentyStandardApplicationId,
|
||||
workspaceId,
|
||||
objectMetadataId: standardObjectMetadataRelatedEntityIds[objectName].id,
|
||||
|
|
|
|||
|
|
@ -5,9 +5,9 @@ import {
|
|||
type FieldMetadataSettings,
|
||||
type FieldMetadataType,
|
||||
} from 'twenty-shared/types';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatFieldMetadata } from 'src/engine/metadata-modules/flat-field-metadata/types/flat-field-metadata.type';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
import { type StandardBuilderArgs } from 'src/engine/workspace-manager/twenty-standard-application/types/metadata-standard-buillder-args.type';
|
||||
|
|
@ -90,7 +90,6 @@ export const createStandardRelationFieldFlatMetadata = <
|
|||
return {
|
||||
id: fieldIds[fieldName as keyof typeof fieldIds].id,
|
||||
universalIdentifier: fieldDefinition.universalIdentifier,
|
||||
standardId: fieldDefinition.universalIdentifier,
|
||||
applicationId: twentyStandardApplicationId,
|
||||
workspaceId,
|
||||
objectMetadataId: standardObjectMetadataRelatedEntityIds[objectName].id,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { v4 } from 'uuid';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
import { type AllStandardObjectViewFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-view-field-name.type';
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { isDefined } from 'twenty-shared/utils';
|
||||
import { v4 } from 'uuid';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { findFlatEntityByIdInFlatEntityMapsOrThrow } from 'src/engine/metadata-modules/flat-entity/utils/find-flat-entity-by-id-in-flat-entity-maps-or-throw.util';
|
||||
import { findManyFlatEntityByIdInFlatEntityMapsOrThrow } from 'src/engine/metadata-modules/flat-entity/utils/find-many-flat-entity-by-id-in-flat-entity-maps-or-throw.util';
|
||||
|
|
@ -9,7 +10,6 @@ import {
|
|||
} from 'src/engine/metadata-modules/flat-index-metadata/types/flat-index-metadata.type';
|
||||
import { IndexType } from 'src/engine/metadata-modules/index-metadata/types/indexType.types';
|
||||
import { generateFlatIndexMetadataWithNameOrThrow } from 'src/engine/metadata-modules/index-metadata/utils/generate-flat-index.util';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
import { type AllStandardObjectIndexName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-index-name.type';
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatObjectMetadata } from 'src/engine/metadata-modules/flat-object-metadata/types/flat-object-metadata.type';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
import {
|
||||
type CreateStandardObjectArgs,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatObjectMetadata } from 'src/engine/metadata-modules/flat-object-metadata/types/flat-object-metadata.type';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { type AllStandardObjectFieldName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-field-name.type';
|
||||
import { type AllStandardObjectName } from 'src/engine/workspace-manager/twenty-standard-application/types/all-standard-object-name.type';
|
||||
import { type StandardBuilderArgs } from 'src/engine/workspace-manager/twenty-standard-application/types/metadata-standard-buillder-args.type';
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import {
|
||||
TAB_PROPS,
|
||||
WIDGET_PROPS,
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
import { isDefined } from 'twenty-shared/utils';
|
||||
import { STANDARD_OBJECTS } from 'twenty-shared/metadata';
|
||||
|
||||
import { type FlatPageLayout } from 'src/engine/metadata-modules/flat-page-layout/types/flat-page-layout.type';
|
||||
import { type PageLayoutType } from 'src/engine/metadata-modules/page-layout/enums/page-layout-type.enum';
|
||||
import { STANDARD_OBJECTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-object.constant';
|
||||
import { STANDARD_PAGE_LAYOUTS } from 'src/engine/workspace-manager/twenty-standard-application/constants/standard-page-layout.constant';
|
||||
import { type StandardObjectMetadataRelatedEntityIds } from 'src/engine/workspace-manager/twenty-standard-application/utils/get-standard-object-metadata-related-entity-ids.util';
|
||||
import { type StandardPageLayoutMetadataRelatedEntityIds } from 'src/engine/workspace-manager/twenty-standard-application/utils/get-standard-page-layout-metadata-related-entity-ids.util';
|
||||
|
|
|
|||
|
|
@ -52,7 +52,6 @@ export const createStandardRoleFlatMetadata = ({
|
|||
return {
|
||||
id: v4(),
|
||||
universalIdentifier,
|
||||
standardId: universalIdentifier,
|
||||
label,
|
||||
description,
|
||||
icon,
|
||||
|
|
|
|||
|
|
@ -30,7 +30,6 @@ export const createStandardSkillFlatMetadata = ({
|
|||
return {
|
||||
id: v4(),
|
||||
universalIdentifier,
|
||||
standardId: universalIdentifier,
|
||||
name,
|
||||
label,
|
||||
icon,
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue