F4: remove survey planning DTOs
This commit is contained in:
@@ -1,53 +0,0 @@
|
|||||||
import { Transform } from 'class-transformer';
|
|
||||||
import {
|
|
||||||
IsISO8601,
|
|
||||||
IsOptional,
|
|
||||||
IsString,
|
|
||||||
IsUUID,
|
|
||||||
Matches,
|
|
||||||
MaxLength,
|
|
||||||
MinLength,
|
|
||||||
} from 'class-validator';
|
|
||||||
|
|
||||||
export class UpdateSurveyCampaignDto {
|
|
||||||
@IsOptional()
|
|
||||||
@Transform(({ value }) =>
|
|
||||||
typeof value === 'string' ? value.trim().toUpperCase() : value,
|
|
||||||
)
|
|
||||||
@IsString()
|
|
||||||
@MinLength(1)
|
|
||||||
@MaxLength(80)
|
|
||||||
@Matches(/^[A-Z0-9][A-Z0-9._/-]*$/)
|
|
||||||
code?: string;
|
|
||||||
|
|
||||||
@IsOptional()
|
|
||||||
@Transform(({ value }) => (typeof value === 'string' ? value.trim() : value))
|
|
||||||
@IsString()
|
|
||||||
@MinLength(1)
|
|
||||||
@MaxLength(200)
|
|
||||||
name?: string;
|
|
||||||
|
|
||||||
@IsOptional()
|
|
||||||
@Transform(({ value }) =>
|
|
||||||
typeof value === 'string' && value.trim() ? value.trim() : null,
|
|
||||||
)
|
|
||||||
@IsString()
|
|
||||||
@MaxLength(4000)
|
|
||||||
description?: string | null;
|
|
||||||
|
|
||||||
@IsOptional()
|
|
||||||
@IsISO8601({ strict: true })
|
|
||||||
plannedStartAt?: string | null;
|
|
||||||
|
|
||||||
@IsOptional()
|
|
||||||
@IsISO8601({ strict: true })
|
|
||||||
plannedEndAt?: string | null;
|
|
||||||
|
|
||||||
@IsOptional()
|
|
||||||
@IsUUID('4')
|
|
||||||
scopeAssetId?: string | null;
|
|
||||||
|
|
||||||
@IsOptional()
|
|
||||||
@IsUUID('4')
|
|
||||||
coordinatorUserId?: string | null;
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user