forked from Yara724/api
Fixed v4/v5 flow
This commit is contained in:
@@ -4835,6 +4835,9 @@ export class RequestManagementService {
|
||||
? FilledBy.EXPERT
|
||||
: FilledBy.CUSTOMER,
|
||||
...(isFileMakerRole ? { isMadeByFileMaker: true } : {}),
|
||||
// V5 only: flag that causes the resulting claim to require FileMaker
|
||||
// approval before fanavaran submission. V4 files never set this.
|
||||
...(dto.requiresFileMakerApproval ? { requiresFileMakerApproval: true } : {}),
|
||||
});
|
||||
|
||||
const requestId = String((created as any)._id);
|
||||
@@ -8876,9 +8879,10 @@ export class RequestManagementService {
|
||||
},
|
||||
}
|
||||
: {}),
|
||||
// V5 (isMadeByFileMaker): mark approval gate at claim creation so the flag
|
||||
// is always present regardless of whether upload-video is called.
|
||||
...((req as any).isMadeByFileMaker
|
||||
// V5 only: propagate the approval gate from the blame record to the claim.
|
||||
// isMadeByFileMaker is true for both V4 and V5; only V5 blame records also
|
||||
// carry requiresFileMakerApproval=true (set at create time by the V5 controller).
|
||||
...((req as any).requiresFileMakerApproval
|
||||
? {
|
||||
requiresFileMakerApproval: true,
|
||||
fileMakerApprovalActorId: new Types.ObjectId(actor.sub),
|
||||
|
||||
Reference in New Issue
Block a user