Merge pull request #228 from SyncrowIOT/bugfix/create-subspace

fix create subspace
This commit is contained in:
hannathkadher
2025-01-27 15:22:30 +04:00
committed by GitHub
2 changed files with 9 additions and 2 deletions

View File

@ -1,5 +1,11 @@
import { ApiProperty } from '@nestjs/swagger';
import { IsArray, IsNotEmpty, IsString, ValidateNested } from 'class-validator';
import {
IsArray,
IsNotEmpty,
IsOptional,
IsString,
ValidateNested,
} from 'class-validator';
import { CreateTagDto } from '../tag';
import { Type } from 'class-transformer';
@ -19,5 +25,6 @@ export class AddSubspaceDto {
@IsArray()
@ValidateNested({ each: true })
@Type(() => CreateTagDto)
@IsOptional()
tags?: CreateTagDto[];
}

View File

@ -146,7 +146,7 @@ export class SubSpaceService {
): Promise<BaseResponseDto> {
const space =
await this.validationService.validateSpaceWithinCommunityAndProject(
params.projectUuid,
params.communityUuid,
params.projectUuid,
params.spaceUuid,
);