creted and modified by and
This commit is contained in:
parent
02f7f674ce
commit
f6feef1942
|
@ -345,6 +345,8 @@ public class DatabaseUtils {
|
|||
@Transactional
|
||||
public String fixConflict(final List<String> similarIds, final String user) {
|
||||
|
||||
final OffsetDateTime now = OffsetDateTime.now();
|
||||
|
||||
final List<OrganizationView> views =
|
||||
similarIds.stream().map(organizationViewRepository::findById).filter(Optional::isPresent).map(Optional::get).collect(Collectors.toList());
|
||||
|
||||
|
@ -385,8 +387,10 @@ public class DatabaseUtils {
|
|||
.collect(Collectors.toList());
|
||||
|
||||
openaireDuplicateRepository.saveAll(newDuplicates);
|
||||
|
||||
final OffsetDateTime now = OffsetDateTime.now();
|
||||
newDuplicates.forEach(d -> {
|
||||
openaireDuplicateRepository.updateCreatedByIfMissing(d.getLocalId(), d.getOaOriginalId(), user);
|
||||
openaireDuplicateRepository.updateModificationDate(d.getLocalId(), d.getOaOriginalId(), user, now);
|
||||
});
|
||||
|
||||
for (final String similarId : similarIds) {
|
||||
openaireConflictRepository.updateMultipleStatusAndResetGroup(similarId, SimilarityType.is_different.toString(), user, now);
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
|
||||
|
||||
public class SimpleTest {
|
||||
|
||||
}
|
Loading…
Reference in New Issue