Files
brief-20/backend/src/modules/persons/dto/create-person.dto.ts
Mathis HERRIOT 9620fd689d feat(dto): update group and person DTOs with streamlined properties
- Added `description` field to create and update group DTOs.
- Simplified person DTOs by consolidating fields into `name`, replacing various attributes.
- Added `skills` field to create and update person DTOs for array-based skill representation.
2025-05-16 23:51:50 +02:00

30 lines
400 B
TypeScript

import {
IsString,
IsNotEmpty,
IsOptional,
IsObject,
IsUUID,
IsArray
} from 'class-validator';
/**
* DTO for creating a new person
*/
export class CreatePersonDto {
@IsString()
@IsNotEmpty()
name: string;
@IsUUID()
@IsNotEmpty()
projectId: string;
@IsArray()
@IsOptional()
skills?: string[];
@IsObject()
@IsOptional()
metadata?: Record<string, any>;
}