Production release May 2024 [EXPLORE] #40

Merged
konstantina.galouni merged 81 commits from develop into master 2024-05-23 18:26:50 +02:00
1 changed files with 7 additions and 9 deletions
Showing only changes of commit 95097beaae - Show all commits

View File

@ -58,22 +58,20 @@ export class SearchDataciteService {
entity.result.journal = null; entity.result.journal = null;
entity.result.DOI = item.attributes.doi; entity.result.DOI = item.attributes.doi;
entity.id = item.attributes.doi; entity.id = item.attributes.doi;
entity.title = item.attributes.title; entity.title = Array.isArray(item.attributes.titles) && item.attributes.titles[0].title?item.attributes.titles[0].title:null;
entity.result.url = properties.doiURL + item.attributes.doi; entity.result.url = properties.doiURL + item.attributes.doi;
entity.result.source = 'datacite'; entity.result.source = 'datacite';
entity.type = 'dataset'; entity.type = 'dataset';
entity.result.date = item.attributes.published; entity.result.date = item.attributes.publicationYear;
entity.result.accessRights = "OPEN"; entity.result.accessRights = "OPEN";
entity.result.publisher = item.attributes['container-title']; entity.result.publisher = item.attributes['publisher'];
entity.result.journal = null; entity.result.journal = null;
entity.result.record = item; entity.result.record = item;
if (item.attributes.author) { if (item.attributes.creators) {
entity.result.authors = []; entity.result.authors = [];
for (let j = 0; j < item.attributes.author.length; j++) { for (let j = 0; j < item.attributes.creators.length; j++) {
const author = item.attributes.author[j]; const author = item.attributes.creators[j].name;
if(author.family || author.literal) { entity.result.authors.push(author);
entity.result.authors.push((author.family) ? author.family + (author.given ? ', ' + author.given : '') : author.literal);
}
} }
} }
results.push(entity); results.push(entity);