diff --git a/dhp-workflows/dhp-graph-mapper/src/main/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplication.java b/dhp-workflows/dhp-graph-mapper/src/main/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplication.java index e453f7918..1f8c23ac3 100644 --- a/dhp-workflows/dhp-graph-mapper/src/main/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplication.java +++ b/dhp-workflows/dhp-graph-mapper/src/main/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplication.java @@ -309,6 +309,9 @@ public class MigrateDbEntitiesApplication extends AbstractMigrationApplication i ds.setThematic(rs.getBoolean("thematic")); ds.setKnowledgegraph(rs.getBoolean("knowledgegraph")); ds.setContentpolicies(prepareListOfQualifiers(rs.getArray("contentpolicies"))); + ds.setConsenttermsofuse(rs.getBoolean("consenttermsofuse")); + ds.setFulltextdownload(rs.getBoolean("fulltextdownload")); + ds.setConsenttermsofusedate(rs.getDate("consenttermsofusedate").toString()); return Arrays.asList(ds); } catch (final Exception e) { diff --git a/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/sql/queryDatasources.sql b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/sql/queryDatasources.sql index 98092e882..2623c65c4 100644 --- a/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/sql/queryDatasources.sql +++ b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/sql/queryDatasources.sql @@ -89,6 +89,9 @@ SELECT d.issn AS issnPrinted, d.eissn AS issnOnline, d.lissn AS issnLinking, + d.consenttermsofuse AS consenttermsofuse, + d.fulltextdownload AS fulltextdownload, + d.consenttermsofusedate AS consenttermsofusedate, de.jurisdiction||'@@@eosc:jurisdictions' AS jurisdiction, de.thematic AS thematic, de.knowledge_graph AS knowledgegraph, diff --git a/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplicationTest.java b/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplicationTest.java index b65bd9fd8..05ae5be74 100644 --- a/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplicationTest.java +++ b/dhp-workflows/dhp-graph-mapper/src/test/java/eu/dnetlib/dhp/oa/graph/raw/MigrateDbEntitiesApplicationTest.java @@ -100,6 +100,9 @@ public class MigrateDbEntitiesApplicationTest { assertEquals("Journal article", ds.getContentpolicies().get(0).getClassid()); assertEquals("eosc:contentpolicies", ds.getContentpolicies().get(0).getSchemeid()); + assertEquals(true, ds.getConsenttermsofuse()); + assertEquals(true, ds.getFulltextdownload()); + assertEquals("2022-03-11", ds.getConsenttermsofusedate()); } @Test diff --git a/dhp-workflows/dhp-graph-mapper/src/test/resources/eu/dnetlib/dhp/oa/graph/raw/datasources_resultset_entry.json b/dhp-workflows/dhp-graph-mapper/src/test/resources/eu/dnetlib/dhp/oa/graph/raw/datasources_resultset_entry.json index 42b140306..11b884cde 100644 --- a/dhp-workflows/dhp-graph-mapper/src/test/resources/eu/dnetlib/dhp/oa/graph/raw/datasources_resultset_entry.json +++ b/dhp-workflows/dhp-graph-mapper/src/test/resources/eu/dnetlib/dhp/oa/graph/raw/datasources_resultset_entry.json @@ -268,5 +268,20 @@ "value": [ "Journal article@@@eosc:contentpolicies" ] + }, + { + "field": "consenttermsofuse", + "type": "boolean", + "value": true + }, + { + "field": "fulltextdownload", + "type": "boolean", + "value": true + }, + { + "field": "consenttermsofusedate", + "type": "date", + "value": "2022-03-11" } ] diff --git a/pom.xml b/pom.xml index 603a4cf1e..7a20a1652 100644 --- a/pom.xml +++ b/pom.xml @@ -797,7 +797,7 @@ 3.3.3 3.4.2 [2.12,3.0) - [2.10.29] + [2.10.30-SNAPSHOT] [4.0.3] [6.0.5] [3.1.6]