DM-357 - no longer save all manualRedactionLogEntries here -> they will be...

This commit is contained in:
Andrei Isvoran 2023-08-08 17:16:46 +02:00 committed by Timo Bejan
parent 6eb522d524
commit 973816f0f7

View File

@ -1,6 +1,5 @@
package com.iqser.red.service.persistence.management.v1.processor.service.redactionlog;
import java.awt.Color;
import java.time.OffsetDateTime;
import java.util.ArrayList;
import java.util.Collections;
@ -66,12 +65,8 @@ public class RedactionLogMergeService {
throw new NotFoundException("RedactionLog not present");
}
var sectionGrid = fileManagementStorageService.getSectionGrid(redactionRequest.getDossierId(), redactionRequest.getFileId());
log.debug("Loaded redaction log with computationalVersion: {}", redactionLog.getAnalysisVersion());
var merged = mergeRedactionLogData(redactionLog,
sectionGrid,
redactionRequest.getManualRedactions(),
redactionRequest.getExcludedPages(),
redactionRequest.getTypes(),
@ -84,7 +79,6 @@ public class RedactionLogMergeService {
private RedactionLog mergeRedactionLogData(RedactionLog redactionLog,
SectionGrid sectionGrid,
ManualRedactions manualRedactions,
Set<Integer> excludedPages,
List<Type> types,
@ -94,15 +88,6 @@ public class RedactionLogMergeService {
log.info("Merging Redaction log with manual redactions");
if (manualRedactions != null) {
var manualRedactionLogEntries = addManualAddEntries(sectionGrid,
manualRedactions.getEntriesToAdd(),
manualRedactions.getComments(),
colors,
types,
redactionLog.getAnalysisNumber());
redactionLog.getRedactionLogEntry().addAll(manualRedactionLogEntries);
var manualRedactionWrappers = createManualRedactionWrappers(manualRedactions);
for (RedactionLogEntry entry : redactionLog.getRedactionLogEntry()) {