Add [from/to]Description to CreateRelationInput (#2613)

This commit is contained in:
Weiko
2023-11-21 11:38:27 +01:00
committed by GitHub
parent 09533e286b
commit 6f4a952381
2 changed files with 13 additions and 3 deletions

View File

@ -62,9 +62,19 @@ export class CreateRelationInput {
@IsString()
@IsOptional()
@Field({ nullable: true })
@Field({ nullable: true, deprecationReason: 'Use fromDescription instead' })
description?: string;
@IsString()
@IsOptional()
@Field({ nullable: true })
fromDescription?: string;
@IsString()
@IsOptional()
@Field({ nullable: true })
toDescription?: string;
@HideField()
workspaceId: string;
}

View File

@ -122,7 +122,7 @@ export class RelationMetadataService extends TypeOrmQueryService<RelationMetadat
{
name: record.fromName,
label: record.fromLabel,
description: record.description,
description: record.fromDescription,
icon: record.fromIcon,
isCustom: true,
targetColumnMap: {},
@ -135,7 +135,7 @@ export class RelationMetadataService extends TypeOrmQueryService<RelationMetadat
{
name: record.toName,
label: record.toLabel,
description: undefined,
description: record.toDescription,
icon: record.toIcon,
isCustom: true,
targetColumnMap: {},