From ee4f96c8cde64c60a3a882289db98266dbb8deac Mon Sep 17 00:00:00 2001 From: Camelia Dumitru <62257307+Camelia-Orcid@users.noreply.github.com> Date: Wed, 30 Oct 2024 14:09:08 +0000 Subject: [PATCH] Added the missing v2 attributes when creating orgs for ROR type (#7116) Co-authored-by: Angel Montenegro --- .../orcid/scheduler/loader/source/ror/RorOrgLoadSource.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/orcid-scheduler-web/src/main/java/org/orcid/scheduler/loader/source/ror/RorOrgLoadSource.java b/orcid-scheduler-web/src/main/java/org/orcid/scheduler/loader/source/ror/RorOrgLoadSource.java index 28da2f9a727..d815dc672c8 100644 --- a/orcid-scheduler-web/src/main/java/org/orcid/scheduler/loader/source/ror/RorOrgLoadSource.java +++ b/orcid-scheduler-web/src/main/java/org/orcid/scheduler/loader/source/ror/RorOrgLoadSource.java @@ -281,7 +281,7 @@ private OrgDisambiguatedEntity processInstitute(String sourceId, String name, Is } // Create a new disambiguated org - OrgDisambiguatedEntity newOrg = createDisambiguatedOrg(sourceId, name, orgType, country, city, region, url); + OrgDisambiguatedEntity newOrg = createDisambiguatedOrg(sourceId, name, orgType, country, city, region, url, locationsJson, namesJson); try { // mark group for indexing new OrgGrouping(newOrg, orgDisambiguatedManager).markGroupForIndexing(orgDisambiguatedDao); @@ -394,7 +394,7 @@ private boolean entityChanged(OrgDisambiguatedEntity entity, String name, String /** * Creates a disambiguated ORG in the org_disambiguated table */ - private OrgDisambiguatedEntity createDisambiguatedOrg(String sourceId, String name, String orgType, Iso3166Country country, String city, String region, String url) { + private OrgDisambiguatedEntity createDisambiguatedOrg(String sourceId, String name, String orgType, Iso3166Country country, String city, String region, String url,String locationsJson, String namesJson) { LOGGER.info("Creating disambiguated org {}", name); OrgDisambiguatedEntity orgDisambiguatedEntity = new OrgDisambiguatedEntity(); orgDisambiguatedEntity.setName(name); @@ -405,6 +405,8 @@ private OrgDisambiguatedEntity createDisambiguatedOrg(String sourceId, String na orgDisambiguatedEntity.setOrgType(orgType); orgDisambiguatedEntity.setSourceId(sourceId); orgDisambiguatedEntity.setSourceType(OrgDisambiguatedSourceType.ROR.name()); + orgDisambiguatedEntity.setLocationsJson(locationsJson); + orgDisambiguatedEntity.setNamesJson(namesJson); orgDisambiguatedManager.createOrgDisambiguated(orgDisambiguatedEntity); return orgDisambiguatedEntity; }