fix: standardize GraphQL schema UUID field types (#13550)
Closes [#1264](https://github.com/twentyhq/core-team-issues/issues/1264)
This commit is contained in:
+4
-3
@@ -1,8 +1,9 @@
|
||||
import { ObjectType, Field, HideField, ID } from '@nestjs/graphql';
|
||||
import { Field, HideField, ObjectType } from '@nestjs/graphql';
|
||||
|
||||
import { IsOptional } from 'class-validator';
|
||||
import GraphQLJSON from 'graphql-type-json';
|
||||
|
||||
import { UUIDScalarType } from 'src/engine/api/graphql/workspace-schema-builder/graphql-types/scalars';
|
||||
import { UserMappingOptionsDTO } from 'src/engine/metadata-modules/remote-server/dtos/user-mapping-dto';
|
||||
import {
|
||||
ForeignDataWrapperOptions,
|
||||
@@ -11,10 +12,10 @@ import {
|
||||
|
||||
@ObjectType('RemoteServer')
|
||||
export class RemoteServerDTO<T extends RemoteServerType> {
|
||||
@Field(() => ID)
|
||||
@Field(() => UUIDScalarType)
|
||||
id: string;
|
||||
|
||||
@Field(() => ID)
|
||||
@Field(() => UUIDScalarType)
|
||||
foreignDataWrapperId: string;
|
||||
|
||||
@Field(() => String)
|
||||
|
||||
+2
-1
@@ -3,6 +3,7 @@ import { Field, InputType } from '@nestjs/graphql';
|
||||
import { IsOptional } from 'class-validator';
|
||||
import GraphQLJSON from 'graphql-type-json';
|
||||
|
||||
import { UUIDScalarType } from 'src/engine/api/graphql/workspace-schema-builder/graphql-types/scalars';
|
||||
import {
|
||||
ForeignDataWrapperOptions,
|
||||
RemoteServerType,
|
||||
@@ -14,7 +15,7 @@ import {
|
||||
|
||||
@InputType()
|
||||
export class UpdateRemoteServerInput<T extends RemoteServerType> {
|
||||
@Field(() => String)
|
||||
@Field(() => UUIDScalarType)
|
||||
id: string;
|
||||
|
||||
@IsOptional()
|
||||
|
||||
+4
-2
@@ -1,8 +1,10 @@
|
||||
import { InputType, Field, ID } from '@nestjs/graphql';
|
||||
import { Field, InputType } from '@nestjs/graphql';
|
||||
|
||||
import { UUIDScalarType } from 'src/engine/api/graphql/workspace-schema-builder/graphql-types/scalars';
|
||||
|
||||
@InputType()
|
||||
export class RemoteTableInput {
|
||||
@Field(() => ID)
|
||||
@Field(() => UUIDScalarType)
|
||||
remoteServerId: string;
|
||||
|
||||
@Field(() => String)
|
||||
|
||||
Reference in New Issue
Block a user