Add default fields on object manifest (#17977)

as title

<img width="830" height="227" alt="image"
src="https://github.com/user-attachments/assets/8cbf4a14-5d1d-496f-a146-f31079e6e602"
/>
This commit is contained in:
martmull
2026-02-16 16:50:46 +01:00
committed by GitHub
parent 2b7b05de2e
commit c3d565f266
11 changed files with 745 additions and 8 deletions
@@ -1,6 +1,7 @@
import { FieldType } from '@/sdk';
import type { Manifest } from 'twenty-shared/application';
import { PermissionFlagType } from 'twenty-shared/constants';
import { FieldMetadataType } from 'twenty-shared/types';
export const EXPECTED_MANIFEST: Manifest = {
publicAssets: [
@@ -121,6 +122,82 @@ export const EXPECTED_MANIFEST: Manifest = {
type: FieldType.TEXT,
universalIdentifier: 'b0b1b2b3-b4b5-4000-8000-000000000003',
},
{
defaultValue: 'uuid',
description: 'Id',
icon: 'Icon123',
isNullable: false,
label: 'Id',
name: 'id',
type: FieldMetadataType.UUID,
universalIdentifier: 'b5830f92-1abe-5ae7-b689-7821dda00b15',
},
{
defaultValue: null,
description: 'Name',
icon: 'IconAbc',
isNullable: true,
label: 'Name',
name: 'name',
type: FieldMetadataType.TEXT,
universalIdentifier: 'ae2b2e5a-6c8b-5324-b639-8f17e3bc0420',
},
{
defaultValue: 'now',
description: 'Creation date',
icon: 'IconCalendar',
isNullable: false,
label: 'Creation date',
name: 'createdAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '7c84a501-41a6-531e-bc5e-8062843f6cba',
},
{
defaultValue: 'now',
description: 'Last time the record was changed',
icon: 'IconCalendarClock',
isNullable: false,
label: 'Last update',
name: 'updatedAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '72c2903a-91c9-5f36-8668-b53b083ae4cf',
},
{
defaultValue: null,
description: 'Deletion date',
icon: 'IconCalendarClock',
isNullable: true,
label: 'Deleted at',
name: 'deletedAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '007f5d8e-d376-519e-bd07-aea41a53f7d9',
},
{
defaultValue: {
name: "''",
source: "'MANUAL'",
},
description: 'The creator of the record',
icon: 'IconCreativeCommonsSa',
isNullable: false,
label: 'Created by',
name: 'createdBy',
type: FieldMetadataType.ACTOR,
universalIdentifier: '44053354-0d8b-5d66-bfa8-7e7d221de3db',
},
{
defaultValue: {
name: "''",
source: "'MANUAL'",
},
description: 'The workspace member who last updated the record',
icon: 'IconUserCircle',
isNullable: false,
label: 'Updated by',
name: 'updatedBy',
type: FieldMetadataType.ACTOR,
universalIdentifier: '38e2c671-cbf5-5773-a04a-e5a2d6c323c8',
},
],
icon: 'IconNote',
labelIdentifierFieldMetadataUniversalIdentifier:
@@ -199,6 +276,82 @@ export const EXPECTED_MANIFEST: Manifest = {
type: FieldType.DATE_TIME,
universalIdentifier: 'e06abe72-5b44-4e7f-93be-afc185a3c433',
},
{
defaultValue: 'uuid',
description: 'Id',
icon: 'Icon123',
isNullable: false,
label: 'Id',
name: 'id',
type: FieldMetadataType.UUID,
universalIdentifier: '56e652a3-fac2-54fd-a379-f01b72758268',
},
{
defaultValue: null,
description: 'Name',
icon: 'IconAbc',
isNullable: true,
label: 'Name',
name: 'name',
type: FieldMetadataType.TEXT,
universalIdentifier: 'c59a149f-5861-51a3-a924-2bd2fa31daaa',
},
{
defaultValue: 'now',
description: 'Creation date',
icon: 'IconCalendar',
isNullable: false,
label: 'Creation date',
name: 'createdAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '236e2ec5-3636-5b97-b19d-f7799cb88d99',
},
{
defaultValue: 'now',
description: 'Last time the record was changed',
icon: 'IconCalendarClock',
isNullable: false,
label: 'Last update',
name: 'updatedAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '2cf640eb-09a7-52f2-820b-419071c5ec24',
},
{
defaultValue: null,
description: 'Deletion date',
icon: 'IconCalendarClock',
isNullable: true,
label: 'Deleted at',
name: 'deletedAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '2eb62b4a-6888-58ab-9887-a879321fff31',
},
{
defaultValue: {
name: "''",
source: "'MANUAL'",
},
description: 'The creator of the record',
icon: 'IconCreativeCommonsSa',
isNullable: false,
label: 'Created by',
name: 'createdBy',
type: FieldMetadataType.ACTOR,
universalIdentifier: '36e95d21-9c86-5b6f-8133-a66d09fc8952',
},
{
defaultValue: {
name: "''",
source: "'MANUAL'",
},
description: 'The workspace member who last updated the record',
icon: 'IconUserCircle',
isNullable: false,
label: 'Updated by',
name: 'updatedBy',
type: FieldMetadataType.ACTOR,
universalIdentifier: 'dc5231a4-e128-57b0-ac9d-723678d9b239',
},
],
icon: 'IconMail',
labelIdentifierFieldMetadataUniversalIdentifier:
@@ -1,5 +1,6 @@
import { FieldType } from '@/sdk';
import type { Manifest } from 'twenty-shared/application';
import { FieldMetadataType } from 'twenty-shared/types';
export const EXPECTED_MANIFEST: Manifest = {
application: {
@@ -31,6 +32,82 @@ export const EXPECTED_MANIFEST: Manifest = {
label: 'Title',
name: 'title',
},
{
defaultValue: 'uuid',
description: 'Id',
icon: 'Icon123',
isNullable: false,
label: 'Id',
name: 'id',
type: FieldMetadataType.UUID,
universalIdentifier: '5bdb4f57-a349-56d0-b421-845fd55b3026',
},
{
defaultValue: null,
description: 'Name',
icon: 'IconAbc',
isNullable: true,
label: 'Name',
name: 'name',
type: FieldMetadataType.TEXT,
universalIdentifier: '86cc7b06-26de-5b7b-bf4a-31fa246dfd90',
},
{
defaultValue: 'now',
description: 'Creation date',
icon: 'IconCalendar',
isNullable: false,
label: 'Creation date',
name: 'createdAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: 'abe3bc69-1a51-5814-a722-74f5a025e92a',
},
{
defaultValue: 'now',
description: 'Last time the record was changed',
icon: 'IconCalendarClock',
isNullable: false,
label: 'Last update',
name: 'updatedAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: 'c296d408-9720-5a86-8586-3490fbf04b86',
},
{
defaultValue: null,
description: 'Deletion date',
icon: 'IconCalendarClock',
isNullable: true,
label: 'Deleted at',
name: 'deletedAt',
type: FieldMetadataType.DATE_TIME,
universalIdentifier: '488333a2-f4ff-5790-88ef-21f07f8f1985',
},
{
defaultValue: {
name: "''",
source: "'MANUAL'",
},
description: 'The creator of the record',
icon: 'IconCreativeCommonsSa',
isNullable: false,
label: 'Created by',
name: 'createdBy',
type: FieldMetadataType.ACTOR,
universalIdentifier: 'fba6e01b-6579-554e-ad64-a676003c8e68',
},
{
defaultValue: {
name: "''",
source: "'MANUAL'",
},
description: 'The workspace member who last updated the record',
icon: 'IconUserCircle',
isNullable: false,
label: 'Updated by',
name: 'updatedBy',
type: FieldMetadataType.ACTOR,
universalIdentifier: 'fa60f87d-15c8-5ff7-9da0-191fa14a922f',
},
],
},
],