Commit 45e9d3f3 authored by delanoe's avatar delanoe

[FIX] Parsers: journal -> source.

parent b9dc43e1
...@@ -24,7 +24,7 @@ class CernParser(Parser): ...@@ -24,7 +24,7 @@ class CernParser(Parser):
"773":{ "773":{
"c": "pages", "c": "pages",
"n": "issue", "n": "issue",
"p": "journal", "p": "source",
"v": "volume", "v": "volume",
"y": "publication_year" "y": "publication_year"
}, },
......
...@@ -159,11 +159,11 @@ class EuropresseParser(Parser): ...@@ -159,11 +159,11 @@ class EuropresseParser(Parser):
try: try:
pub_name = html_article.xpath(name_xpath)[0].text pub_name = html_article.xpath(name_xpath)[0].text
name = pub_name.split(', ') name = pub_name.split(', ')
hyperdata['journal'] = name[0] hyperdata['source'] = name[0]
hyperdata['number'] = name[1] hyperdata['number'] = name[1]
except: except:
try: try:
hyperdata['journal'] = pub_name.strip() hyperdata['source'] = pub_name.strip()
except: except:
pass pass
......
...@@ -10,7 +10,7 @@ class ISIParser(RISParser): ...@@ -10,7 +10,7 @@ class ISIParser(RISParser):
"TI": {"type": "hyperdata", "key": "title", "separator": " "}, "TI": {"type": "hyperdata", "key": "title", "separator": " "},
"AU": {"type": "hyperdata", "key": "authors", "separator": ", "}, "AU": {"type": "hyperdata", "key": "authors", "separator": ", "},
"DI": {"type": "hyperdata", "key": "doi"}, "DI": {"type": "hyperdata", "key": "doi"},
"SO": {"type": "hyperdata", "key": "journal"}, "SO": {"type": "hyperdata", "key": "source"},
"PY": {"type": "hyperdata", "key": "publication_year"}, "PY": {"type": "hyperdata", "key": "publication_year"},
"PD": {"type": "hyperdata", "key": "publication_month"}, "PD": {"type": "hyperdata", "key": "publication_month"},
"LA": {"type": "hyperdata", "key": "language_fullname"}, "LA": {"type": "hyperdata", "key": "language_fullname"},
......
...@@ -64,7 +64,7 @@ class ISTexParser(Parser): ...@@ -64,7 +64,7 @@ class ISTexParser(Parser):
hyperdata["publication_date"].append( hyperdata["host"]["pubdate"] ) hyperdata["publication_date"].append( hyperdata["host"]["pubdate"] )
if "title" in hyperdata["host"]: if "title" in hyperdata["host"]:
hyperdata["journal"] = hyperdata["host"]["title"] hyperdata["source"] = hyperdata["host"]["title"]
authors=False authors=False
if "authorsRAW" in hyperdata: if "authorsRAW" in hyperdata:
......
...@@ -7,7 +7,7 @@ from io import BytesIO ...@@ -7,7 +7,7 @@ from io import BytesIO
class PubmedParser(Parser): class PubmedParser(Parser):
hyperdata_path = { hyperdata_path = {
"journal" : 'MedlineCitation/Article/Journal/Title', "source" : 'MedlineCitation/Article/Journal/Title',
"title" : 'MedlineCitation/Article/ArticleTitle', "title" : 'MedlineCitation/Article/ArticleTitle',
"abstract" : 'MedlineCitation/Article/Abstract/AbstractText', "abstract" : 'MedlineCitation/Article/Abstract/AbstractText',
"title2" : 'MedlineCitation/Article/VernacularTitle', "title2" : 'MedlineCitation/Article/VernacularTitle',
......
...@@ -19,7 +19,7 @@ class RepecParser(Parser): ...@@ -19,7 +19,7 @@ class RepecParser(Parser):
b"T1": {"type": "hyperdata", "key": "title", "separator": " "}, b"T1": {"type": "hyperdata", "key": "title", "separator": " "},
b"ST": {"type": "hyperdata", "key": "subtitle", "separator": " "}, b"ST": {"type": "hyperdata", "key": "subtitle", "separator": " "},
b"A1": {"type": "hyperdata", "key": "authors", "separator": "\n"}, b"A1": {"type": "hyperdata", "key": "authors", "separator": "\n"},
b"JO": {"type": "hyperdata", "key": "journal"}, b"JO": {"type": "hyperdata", "key": "source"},
b"UR": {"type": "hyperdata", "key": "doi"}, b"UR": {"type": "hyperdata", "key": "doi"},
b"Y1": {"type": "hyperdata", "key": "publication_year"}, b"Y1": {"type": "hyperdata", "key": "publication_year"},
b"PD": {"type": "hyperdata", "key": "publication_month"}, b"PD": {"type": "hyperdata", "key": "publication_month"},
......
...@@ -15,8 +15,8 @@ class RISParser(Parser): ...@@ -15,8 +15,8 @@ class RISParser(Parser):
"ST": {"type": "hyperdata", "key": "subtitle", "separator": " "}, "ST": {"type": "hyperdata", "key": "subtitle", "separator": " "},
"AU": {"type": "hyperdata", "key": "authors", "separator": "\n"}, "AU": {"type": "hyperdata", "key": "authors", "separator": "\n"},
"JO": {"type": "hyperdata", "key": "journal"}, "JO": {"type": "hyperdata", "key": "source"},
"T2": {"type": "hyperdata", "key": "journal"}, "T2": {"type": "hyperdata", "key": "source"},
# "T2": variant of JO (if together only last will be kept) # "T2": variant of JO (if together only last will be kept)
"UR": {"type": "hyperdata", "key": "doi"}, "UR": {"type": "hyperdata", "key": "doi"},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment