diff --git a/src/expert-claim/dto/claim-detail-v2.dto.ts b/src/expert-claim/dto/claim-detail-v2.dto.ts index 83e8cf2..817edf9 100644 --- a/src/expert-claim/dto/claim-detail-v2.dto.ts +++ b/src/expert-claim/dto/claim-detail-v2.dto.ts @@ -138,6 +138,25 @@ export class ClaimDetailV2ResponseDto { }) requiresFileMakerApproval?: boolean; + @ApiPropertyOptional({ + description: + "V5 only. Number of times the FileMaker has rejected this claim (0–2). When 2, the next action must be approval.", + example: 1, + }) + fileMakerRejectionCount?: number; + + @ApiPropertyOptional({ + description: "V5 only. Reason text from the most recent FileMaker rejection.", + example: "قیمت نامعقول", + }) + fileMakerRejectionReason?: string; + + @ApiPropertyOptional({ + description: "V5 only. ObjectId of the FileMaker who must approve (or has approved) this claim.", + example: "6a43a2689faee3d20bf24030", + }) + fileMakerApprovalActorId?: string; + @ApiPropertyOptional({ description: "Slice of `claim.evaluation` exposed to the damage expert. " + diff --git a/src/expert-claim/expert-claim.service.ts b/src/expert-claim/expert-claim.service.ts index 83810d6..e27b3ca 100644 --- a/src/expert-claim/expert-claim.service.ts +++ b/src/expert-claim/expert-claim.service.ts @@ -5105,6 +5105,11 @@ export class ExpertClaimService { damagedParts, awaitingFactorValidation: isFactorValidationPending, requiresFileMakerApproval: !!(claim as any).requiresFileMakerApproval, + fileMakerRejectionCount: (claim as any).fileMakerRejectionCount ?? 0, + fileMakerRejectionReason: (claim as any).fileMakerRejectionReason ?? undefined, + fileMakerApprovalActorId: (claim as any).fileMakerApprovalActorId + ? String((claim as any).fileMakerApprovalActorId) + : undefined, evaluation: (evaluationForApi as | ClaimDetailV2ResponseDto["evaluation"]