Merge Angular 16 Irish Monitor to develop #33
|
@ -25,7 +25,7 @@ export class SearchOrcidService {
|
||||||
.pipe(map(res => res['person']))
|
.pipe(map(res => res['person']))
|
||||||
.pipe(map(res => [res['name']['given-names'],
|
.pipe(map(res => [res['name']['given-names'],
|
||||||
res['name']['family-name'],
|
res['name']['family-name'],
|
||||||
res['name']]))
|
res['name'], res['name']['institution-name']]))
|
||||||
|
|
||||||
.pipe(map(res => SearchOrcidService.parseOrcidAuthor(res, authorIds, authors, addId)));
|
.pipe(map(res => SearchOrcidService.parseOrcidAuthor(res, authorIds, authors, addId)));
|
||||||
}
|
}
|
||||||
|
@ -42,7 +42,7 @@ export class SearchOrcidService {
|
||||||
.pipe(map(res => res['person']))
|
.pipe(map(res => res['person']))
|
||||||
.pipe(map(res => [res['name']['given-names'],
|
.pipe(map(res => [res['name']['given-names'],
|
||||||
res['name']['family-name'],
|
res['name']['family-name'],
|
||||||
res['name']]))
|
res['name'], res['name']['institution-name']]))
|
||||||
|
|
||||||
.pipe(map(res => {
|
.pipe(map(res => {
|
||||||
let authors = []
|
let authors = []
|
||||||
|
@ -86,6 +86,7 @@ export class SearchOrcidService {
|
||||||
author['id'] = auth_result['orcid-id'];
|
author['id'] = auth_result['orcid-id'];
|
||||||
author['authorGivenName'] = auth_result['given-names'];
|
author['authorGivenName'] = auth_result['given-names'];
|
||||||
author['authorFamilyName'] = auth_result['family-names'];
|
author['authorFamilyName'] = auth_result['family-names'];
|
||||||
|
author['institutions'] = auth_result['institution-name'];
|
||||||
authors.push(author);
|
authors.push(author);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -104,6 +105,7 @@ export class SearchOrcidService {
|
||||||
|
|
||||||
|
|
||||||
static parseOrcidAuthor(data: any, authorIds: string[], authors, addId): any {
|
static parseOrcidAuthor(data: any, authorIds: string[], authors, addId): any {
|
||||||
|
console.log(data)
|
||||||
if (data[2] != null) {
|
if (data[2] != null) {
|
||||||
if (addId) {
|
if (addId) {
|
||||||
authorIds.push(data[2].path);
|
authorIds.push(data[2].path);
|
||||||
|
@ -120,7 +122,12 @@ export class SearchOrcidService {
|
||||||
} else {
|
} else {
|
||||||
author['authorFamilyName'] = "";
|
author['authorFamilyName'] = "";
|
||||||
}
|
}
|
||||||
|
if (data[3] != null) {
|
||||||
|
author['institution'] = data[3];
|
||||||
|
}
|
||||||
|
console.log(author['institution'])
|
||||||
authors.push(author);
|
authors.push(author);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Reference in New Issue