87eff6a37f
Co-authored-by: Copilot <copilot@github.com>
29 lines
484 B
TypeScript
29 lines
484 B
TypeScript
import { IsNotEmpty, IsNumber, IsOptional, IsString, MaxLength } from 'class-validator';
|
|
|
|
export class UpdateProductDto {
|
|
@IsOptional()
|
|
@IsString()
|
|
@IsNotEmpty()
|
|
@MaxLength(191)
|
|
name?: string;
|
|
|
|
@IsOptional()
|
|
@IsString()
|
|
@MaxLength(191)
|
|
canonicalName?: string;
|
|
|
|
@IsOptional()
|
|
@IsString()
|
|
@MaxLength(191)
|
|
category?: string;
|
|
|
|
@IsOptional()
|
|
@IsString()
|
|
@MaxLength(191)
|
|
subcategory?: string;
|
|
|
|
@IsOptional()
|
|
@IsNumber()
|
|
categoryId?: number | null;
|
|
}
|