The open alternative to Salesforce, designed for AI.
TypeScript crmcrm-systemcustomergood-first-issuegraphqlhacktoberfestjavascriptmarketingmonoreponestjsopen-sourcepostgresqlreactreactjssalestypescriptweb
import { Field, ObjectType } from '@nestjs/graphql';
import { IsIn, IsNotEmpty, IsOptional, IsUUID } from 'class-validator';
import {
type FrontComponentConfiguration,
type SerializedRelation,
} from 'twenty-shared/types';
import { UUIDScalarType } from 'src/engine/api/graphql/workspace-schema-builder/graphql-types/scalars';
import { WidgetConfigurationType } from 'src/engine/metadata-modules/page-layout-widget/enums/widget-configuration-type.type';
@ObjectType('FrontComponentConfiguration')
export class FrontComponentConfigurationDTO implements FrontComponentConfiguration {
@Field(() => WidgetConfigurationType)
@IsIn([WidgetConfigurationType.FRONT_COMPONENT])
@IsNotEmpty()
configurationType: WidgetConfigurationType.FRONT_COMPONENT;
@Field(() => UUIDScalarType)
@IsNotEmpty()
@IsUUID()
frontComponentId: SerializedRelation;
@Field(() => [UUIDScalarType], { nullable: true })
@IsOptional()
@IsUUID(undefined, { each: true })
headerCommandMenuItemUniversalIdentifiers?: string[];
}