forked from Yara724/api
update the resend request and user side
This commit is contained in:
@@ -6,6 +6,7 @@ import {
|
||||
IsBoolean,
|
||||
IsOptional,
|
||||
ValidateNested,
|
||||
IsEnum,
|
||||
} from 'class-validator';
|
||||
import { Type } from 'class-transformer';
|
||||
import { ClaimRequiredDocumentType } from 'src/Types&Enums/claim-request-management/required-document-type.enum';
|
||||
@@ -72,12 +73,28 @@ export class SubmitExpertReplyV2Dto {
|
||||
}
|
||||
|
||||
export class ClaimSubmitResendV2Dto {
|
||||
@ApiProperty({ required: true })
|
||||
resendDescription: string;
|
||||
@ApiPropertyOptional({
|
||||
description:
|
||||
"Instructions for the owner. At least one of description, resendDocuments, or resendCarParts must be non-empty.",
|
||||
})
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
resendDescription?: string;
|
||||
|
||||
@ApiProperty({ required: true, examples: ClaimRequiredDocumentType })
|
||||
resendDocuments: ClaimRequiredDocumentType[];
|
||||
@ApiPropertyOptional({
|
||||
type: [String],
|
||||
enum: ClaimRequiredDocumentType,
|
||||
description: "Extra document keys to upload (may include types not in the initial claim form).",
|
||||
})
|
||||
@IsOptional()
|
||||
@IsArray()
|
||||
@IsEnum(ClaimRequiredDocumentType, { each: true })
|
||||
resendDocuments?: ClaimRequiredDocumentType[];
|
||||
|
||||
@ApiProperty({ required: true, type: [DamagedPartItem] })
|
||||
resendCarParts: DamagedPartItem[];
|
||||
@ApiPropertyOptional({ type: [DamagedPartItem] })
|
||||
@IsOptional()
|
||||
@IsArray()
|
||||
@ValidateNested({ each: true })
|
||||
@Type(() => DamagedPartItem)
|
||||
resendCarParts?: DamagedPartItem[];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user