From 7940b4b02492eb8052c33252a7c77188181867e6 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Mon, 11 Jan 2021 20:30:39 -0800 Subject: elasticsearch: simple new dblp and doaj fields --- python/fatcat_tools/transforms/elasticsearch.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'python') diff --git a/python/fatcat_tools/transforms/elasticsearch.py b/python/fatcat_tools/transforms/elasticsearch.py index db860a09..f37aadba 100644 --- a/python/fatcat_tools/transforms/elasticsearch.py +++ b/python/fatcat_tools/transforms/elasticsearch.py @@ -72,6 +72,8 @@ def release_to_elasticsearch(entity: ReleaseEntity, force_bool: bool = True) -> jstor_id = release.ext_ids.jstor, ark_id = release.ext_ids.ark, mag_id = release.ext_ids.mag, + dblp_id = release.ext_ids.dblp, + doaj_id = release.ext_ids.doaj, ) t.update(dict( @@ -84,6 +86,7 @@ def release_to_elasticsearch(entity: ReleaseEntity, force_bool: bool = True) -> in_ia_sim = False, in_kbart = None, in_jstor = False, + in_doaj= bool(release.ext_ids.doaj), in_shadows = False, )) @@ -280,6 +283,7 @@ def _rte_container_helper(container: ContainerEntity, release_year: Optional[int if c_extra.get('doaj'): if c_extra['doaj'].get('as_of'): t['is_oa'] = True + t['in_doaj'] = True if c_extra.get('road'): if c_extra['road'].get('as_of'): t['is_oa'] = True -- cgit v1.2.3