diff --git a/dhp-workflows/dhp-aggregation/src/main/scala/eu/dnetlib/dhp/bioschema/BioschemaToOAFTransformation.scala b/dhp-workflows/dhp-aggregation/src/main/scala/eu/dnetlib/dhp/bioschema/BioschemaToOAFTransformation.scala index 9f1b150f5..c6545635d 100644 --- a/dhp-workflows/dhp-aggregation/src/main/scala/eu/dnetlib/dhp/bioschema/BioschemaToOAFTransformation.scala +++ b/dhp-workflows/dhp-aggregation/src/main/scala/eu/dnetlib/dhp/bioschema/BioschemaToOAFTransformation.scala @@ -195,6 +195,8 @@ object BioschemaToOAFTransformation { throw new RuntimeException("Url not found") } instance.setCollectedfrom(collectedFromMap(datasourceKey)) + instance.setHostedby(collectedFromMap(datasourceKey)) + instance.setPid(result.getPid) result.setId(IdentifierFactory.createIdentifier(result)) @@ -240,6 +242,15 @@ object BioschemaToOAFTransformation { finalAlternativeIdentifiers = List(alternativeIdentifiers) ::: List(defaultAlternatedIdentifer) instance.setAlternateIdentifier(finalAlternativeIdentifiers.asJava) + val access_rights_qualifier = + OafMapperUtils.accessRight( + ModelConstants.UNKNOWN, + ModelConstants.NOT_AVAILABLE, + ModelConstants.DNET_ACCESS_MODES, + ModelConstants.DNET_ACCESS_MODES + ) + instance.setAccessright(access_rights_qualifier) + if (exportLinks) { val rels: List[RelatedIdentifierType] = for { JObject(relIdentifier) <- json \\ "relatedIdentifiers"