RED-8339: Fixes
This commit is contained in:
parent
be4769497d
commit
9c93cd32c1
@ -125,11 +125,13 @@ public class ComponentLogService {
|
||||
if (optionalComponentLogEntry.isPresent()) {
|
||||
ComponentLogEntry componentToUpdate = optionalComponentLogEntry.get();
|
||||
componentToUpdate.setOverridden(true);
|
||||
componentToUpdate.setComponentValues(componentOverride.getComponentValues());
|
||||
System.out.println("AAAA1: " + componentToUpdate);
|
||||
componentToUpdate.getComponentValues().addAll(componentOverride.getComponentValues());
|
||||
saveOverride(dossierId, fileId, componentToUpdate);
|
||||
auditOverride(dossierId, fileId, componentToUpdate);
|
||||
} else {
|
||||
componentOverride.setOverridden(true);
|
||||
System.out.println("AAAA2: " + componentOverride);
|
||||
insertOverride(dossierId, fileId, componentOverride);
|
||||
auditOverride(dossierId, fileId, componentOverride);
|
||||
}
|
||||
|
||||
@ -16,7 +16,6 @@ import com.iqser.red.service.peristence.v1.server.integration.client.DossierTemp
|
||||
import com.iqser.red.service.peristence.v1.server.integration.service.DossierTesterAndProvider;
|
||||
import com.iqser.red.service.peristence.v1.server.integration.service.FileTesterAndProvider;
|
||||
import com.iqser.red.service.peristence.v1.server.integration.utils.AbstractPersistenceServerServiceTest;
|
||||
import com.iqser.red.service.persistence.service.v1.api.shared.model.analysislog.componentlog.ComponentLog;
|
||||
import com.iqser.red.service.persistence.service.v1.api.shared.model.dossiertemplate.dossier.file.FileType;
|
||||
import com.iqser.red.service.persistence.service.v2.api.external.model.Component;
|
||||
import com.iqser.red.service.persistence.service.v2.api.external.model.ComponentValue;
|
||||
@ -68,10 +67,7 @@ public class ComponentOverrideTest extends AbstractPersistenceServerServiceTest
|
||||
|
||||
var componentLogJson = new ClassPathResource("files/componentlog/exampleComponentLog.json");
|
||||
|
||||
// ComponentLog componentLog = objectMapper.readValue(componentLogJson.getInputStream(), ComponentLog.class);
|
||||
|
||||
fileManagementStorageService.storeObject(dossier.getId(), file.getId(), FileType.COMPONENT_LOG, componentLogJson.getInputStream());
|
||||
ComponentLog componentLog = fileManagementStorageService.getComponentLog(dossier.getId(), file.getId());
|
||||
|
||||
componentClient.addOverride(dossierTemplate.getId(), dossier.getId(), file.getId(), componentOverrideModel);
|
||||
|
||||
@ -83,10 +79,6 @@ public class ComponentOverrideTest extends AbstractPersistenceServerServiceTest
|
||||
|
||||
assertFalse(overrides.getComponentOverrideModels().isEmpty());
|
||||
|
||||
var sth = componentClient.getComponents(dossierTemplate.getId(), dossier.getId(), file.getId(), true);
|
||||
|
||||
System.out.println(sth);
|
||||
System.out.println("See ya");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -105,6 +105,7 @@ public class ComponentLogMongoService {
|
||||
.map(componentLogEntry -> mapper.toComponentDocument(componentLogId, componentLogEntry))
|
||||
.toList();
|
||||
|
||||
System.out.println("BBBB: " + componentDocuments);
|
||||
componentDocumentRepository.insert(componentDocuments);
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user