Implement role-complete inquiry participants

This commit is contained in:
SepehrYahyaee
2026-09-13 10:59:00 +03:30
parent 401ad6a143
commit c64f23091a
12 changed files with 2179 additions and 690 deletions

View File

@@ -1,36 +1,53 @@
import { ApiProperty } from "@nestjs/swagger";
import { ApiProperty, ApiPropertyOptional } from "@nestjs/swagger";
import { PlatesDto } from "src/plates/dto/plate.dto";
import { Plates } from "src/Types&Enums/plate.interface";
import { InquiryParticipantFieldsDto } from "src/request-management/dto/inquiry-participants.dto";
export class AddPlateDto {
export class AddPlateDto extends InquiryParticipantFieldsDto {
plateId: string;
@ApiProperty({ type: String, required: true })
@ApiPropertyOptional({
type: String,
description: "Legacy third-party policyholder national code",
})
nationalCodeOfInsurer: string;
@ApiProperty({ type: String, required: true })
@ApiPropertyOptional({
type: String,
description: "Legacy driver national code",
})
nationalCodeOfDriver: string;
@ApiProperty({ type: String, required: true })
@ApiPropertyOptional({ type: String })
insurerLicense: string;
@ApiProperty({ type: String, required: true })
@ApiPropertyOptional({ type: String })
driverLicense: string;
@ApiProperty({ type: PlatesDto, required: true })
@ApiPropertyOptional({
type: PlatesDto,
description:
"Legacy/current plate; may be supplied as vehicle.currentPlate",
})
plate: Plates;
@ApiProperty({ type: Boolean, required: true })
@ApiPropertyOptional({
type: Boolean,
description: "Legacy role relationship",
})
driverIsInsurer: boolean;
@ApiProperty({ type: Boolean, required: true, default: false })
isNewCar: boolean;
@ApiProperty({ type: Boolean, required: true })
@ApiPropertyOptional({
type: Boolean,
description: "Legacy; use driver.hasDrivingLicense",
})
userNoCertificate: boolean;
@ApiProperty({
@ApiPropertyOptional({
type: Number,
required: true,
description: "Legacy third-party policyholder birthday",
})
insurerBirthday: number;
@ApiProperty({