Updating entity, component, service of publication landing page: make the entity's structures more clear | update what is shown in Download from - Published in - journal(add issn, lissn) - identifiers(may exist more than one doi | show only doi and pmc) || Updating entity, component, service of project landing page: add existence checksand update component's structure || Commiting entities, components, services of dataset and person landing pages || Committing common components for publication and dataset landing pages
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-portal/trunk@43486 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
a3f50f82de
commit
6dc2747cd4
|
@ -10,6 +10,8 @@ import {LinkingHomeComponent} from './claimPages/linking/linkingHome.component';
|
||||||
import {MyClaimsComponent} from './claimPages/myClaims/myClaims.component';
|
import {MyClaimsComponent} from './claimPages/myClaims/myClaims.component';
|
||||||
import {ProjectComponent} from './landingPages/project/project.component';
|
import {ProjectComponent} from './landingPages/project/project.component';
|
||||||
import {PublicationComponent} from './landingPages/publication/publication.component';
|
import {PublicationComponent} from './landingPages/publication/publication.component';
|
||||||
|
import {DatasetComponent} from './landingPages/dataset/dataset.component';
|
||||||
|
import {PersonComponent} from './landingPages/person/person.component';
|
||||||
import {MyClaimsDemoComponent} from './claimPages/myClaimsDemo.component';
|
import {MyClaimsDemoComponent} from './claimPages/myClaimsDemo.component';
|
||||||
import {SearchPublicationsComponent} from './searchPages/searchPublications.component';
|
import {SearchPublicationsComponent} from './searchPages/searchPublications.component';
|
||||||
import 'rxjs/Rx';
|
import 'rxjs/Rx';
|
||||||
|
@ -75,6 +77,8 @@ import 'rxjs/Rx';
|
||||||
{ path: '/demo', component: MyClaimsDemoComponent, name: 'MyClaimsDemo' },
|
{ path: '/demo', component: MyClaimsDemoComponent, name: 'MyClaimsDemo' },
|
||||||
{ path: '/project', component: ProjectComponent, name: 'Project' },
|
{ path: '/project', component: ProjectComponent, name: 'Project' },
|
||||||
{ path: '/publication', component: PublicationComponent, name: 'Publication' },
|
{ path: '/publication', component: PublicationComponent, name: 'Publication' },
|
||||||
|
{ path: '/dataset', component: DatasetComponent, name: 'Dataset' },
|
||||||
|
{ path: '/person', component: PersonComponent, name: 'Person' },
|
||||||
{ path: '/search-publications', component: SearchPublicationsComponent, name: 'SearchPublications' }
|
{ path: '/search-publications', component: SearchPublicationsComponent, name: 'SearchPublications' }
|
||||||
|
|
||||||
])
|
])
|
||||||
|
|
|
@ -9,7 +9,11 @@ export class ProjectInfo {
|
||||||
endDate: string;
|
endDate: string;
|
||||||
openAccessMandate: string;
|
openAccessMandate: string;
|
||||||
specialClause39: string;
|
specialClause39: string;
|
||||||
organizations: string[];
|
organizations: Map<string, string>;
|
||||||
url: string;
|
url: string;
|
||||||
urlInfo: string;
|
urlInfo: string;
|
||||||
|
|
||||||
|
publications: any;
|
||||||
|
researchData: any;
|
||||||
|
statistics: any;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,22 +1,30 @@
|
||||||
export class PublicationInfo {
|
export class PublicationInfo {
|
||||||
title: string;
|
title: { "name": string, "url": string, "accessMode": string};
|
||||||
authors: { [key: string]: string }[];
|
authors: { "name": string, "url": string}[];
|
||||||
date: string;
|
date: string;
|
||||||
|
embargoEndDate: string;
|
||||||
types: string[];
|
types: string[];
|
||||||
downloadFrom: Map<string, string[]>;
|
downloadFrom: Map<string, {"url": string[], "accessMode": string[]}>; //key is name
|
||||||
bioentities: Map<string, Map<string, string>>;
|
publishedIn: Map<string, {"url": string[], "accessMode": string[]}>; //key is name
|
||||||
identifiers: Map<string, string>;
|
bioentities: Map<string, Map<string, string>>; //<site name, <>>
|
||||||
|
identifiers: Map<string, string[]>; //key is the classname
|
||||||
publisher: string;
|
publisher: string;
|
||||||
journal: string;
|
journal: {"journal": string, "issn": string, "lissn": string};
|
||||||
languages: string[];
|
languages: string[];
|
||||||
subjects: string[];
|
subjects: string[];
|
||||||
classifiedSubjects: Map<string, string[]>;
|
classifiedSubjects: Map<string, string[]>; //<class of subject, subjects>
|
||||||
description: string;
|
description: string;
|
||||||
bestlicense: string;
|
bestlicense: string;
|
||||||
collectedFrom: Map<string, string>;
|
collectedFrom: { "name": string, "url": string}[];
|
||||||
fundedByProjects: Map<string, string[]>;
|
fundedByProjects: { "url": string, "acronym": string, "title": string,
|
||||||
relatedResearchData: Map<string, string[]>;//{ [key: string]: string }[];
|
"funderShortname": string, "funderName": string,
|
||||||
similarPublications: Map<string, string[]>;//{ [key: string]: string }[];
|
"funding": string, "new": boolean}[];
|
||||||
references: { [key: string]: string }[];
|
//relatedPublications: { "name": string, "url": string, "date": string, "trust": string}[];
|
||||||
contexts: { [key: string]: string }[];
|
//relatedResearchData: { "name": string, "url": string, "date": string, "trust": string}[];
|
||||||
|
//similarPublications: {"name": string, "url": string, "date": string, "trust": string}[];
|
||||||
|
//similarDatasets: {"name": string, "url": string, "date": string, "trust": string}[];
|
||||||
|
relatedResearchResults: { "name": string, "url": string, "date": string, "trust": string, "class": string}[];
|
||||||
|
similarResearchResults: {"name": string, "url": string, "date": string, "trust": string, "class": string}[];
|
||||||
|
references: { "name": string, "url": string}[];
|
||||||
|
contexts: { "labelContext": string, "labelCategory": string, "labelConcept": string}[];
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,117 +8,56 @@ import {ProjectInfo} from '../../entities/projectInfo';
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'project',
|
selector: 'project',
|
||||||
template: `
|
template: `
|
||||||
|
<div>
|
||||||
<div class="container" *ngIf="projectInfo != null">
|
<div class="container person">
|
||||||
<div class="row row-offcanvas row-offcanvas-right">
|
<div class="container-header" >
|
||||||
<div class="col-xs-6 col-sm-8">
|
<div *ngIf="projectInfo != null">
|
||||||
<div class="projectIcon">
|
|
||||||
<h3 class="sc39" title="Special Clause 39">{{projectInfo.acronym}}</h3>
|
<h3 class="sc39" title="Special Clause 39">{{projectInfo.acronym}}</h3>
|
||||||
</div>
|
</div>
|
||||||
<!--div class="row">
|
<div *ngIf="warningMessage.length > 0" class="alert alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div class="col-md-3">
|
<div *ngIf="errorMessage.length > 0" class="alert alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
Title
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
|
||||||
{{projectInfo.title}}
|
<div class="row row-offcanvas row-offcanvas-right" >
|
||||||
</div>
|
|
||||||
</div>
|
<div class="col-xs-6 col-sm-9 sidebar-offcanvas" *ngIf="projectInfo != null">
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Funding
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.funding}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Call
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.callIdentifier}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Contract (GA) number
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.contractNum}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Start Date
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.startDate}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
End Date
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.endDate}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Open Access mandate
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.openAccessMandate}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Special Clause 39
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
{{projectInfo.specialClause39}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
Organizations
|
|
||||||
</div>
|
|
||||||
<div class="col-md-offset-3">
|
|
||||||
{{projectInfo.organizations}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-md-3">
|
|
||||||
More information
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<a target="_blank" href="{{projectInfo.url}}">
|
|
||||||
{{projectInfo.urlInfo}}
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</div-->
|
|
||||||
|
|
||||||
<dl class="dl-horizontal">
|
<dl class="dl-horizontal">
|
||||||
<dt>Title: </dt>
|
<dt *ngIf="projectInfo.title != undefined && projectInfo.title != ''">Title: </dt>
|
||||||
<dd>{{projectInfo.title}}</dd>
|
<dd *ngIf="projectInfo.title != undefined && projectInfo.title != ''">{{projectInfo.title}}</dd>
|
||||||
<dt>Funding: </dt>
|
<dt *ngIf="projectInfo.funding != undefined && projectInfo.funding != ''">Funding: </dt>
|
||||||
<dd>{{projectInfo.funding}}</dd>
|
<dd *ngIf="projectInfo.funding != undefined && projectInfo.funding != ''">{{projectInfo.funding}}</dd>
|
||||||
<dt>Call: </dt>
|
<dt *ngIf="projectInfo.callIdentifier != undefined && projectInfo.callIdentifier != ''">Call: </dt>
|
||||||
<dd>{{projectInfo.callIdentifier}}</dd>
|
<dd *ngIf="projectInfo.callIdentifier != undefined && projectInfo.callIdentifier != ''">{{projectInfo.callIdentifier}}</dd>
|
||||||
<dt>Contract (GA) number: </dt>
|
<dt *ngIf="projectInfo.contractNum != undefined && projectInfo.contractNum != ''">Contract (GA) number: </dt>
|
||||||
<dd>{{projectInfo.contractNum}}</dd>
|
<dd *ngIf="projectInfo.contractNum != undefined && projectInfo.contractNum != ''">{{projectInfo.contractNum}}</dd>
|
||||||
<dt>Start Date: </dt>
|
<dt *ngIf="projectInfo.startDate != undefined && projectInfo.startDate != ''">Start Date: </dt>
|
||||||
<dd>{{projectInfo.startDate}}</dd>
|
<dd *ngIf="projectInfo.startDate != undefined && projectInfo.startDate != ''">{{projectInfo.startDate}}</dd>
|
||||||
<dt>End Date: </dt>
|
<dt *ngIf="projectInfo.endDate != undefined && projectInfo.endDate != ''">End Date: </dt>
|
||||||
<dd>{{projectInfo.endDate}}</dd>
|
<dd *ngIf="projectInfo.endDate != undefined && projectInfo.endDate != ''">{{projectInfo.endDate}}</dd>
|
||||||
<dt>Open Access mandate: </dt>
|
<dt *ngIf="projectInfo.openAccessMandate != undefined && projectInfo.openAccessMandate != ''">Open Access mandate: </dt>
|
||||||
<dd>{{projectInfo.openAccessMandate}}</dd>
|
<dd *ngIf="projectInfo.openAccessMandate != undefined && projectInfo.openAccessMandate != ''">{{projectInfo.openAccessMandate}}</dd>
|
||||||
<dt>Special Clause 39: </dt>
|
<dt *ngIf="projectInfo.specialClause39 != undefined && projectInfo.specialClause39 != ''">Special Clause 39: </dt>
|
||||||
<dd>{{projectInfo.specialClause39}}</dd>
|
<dd *ngIf="projectInfo.specialClause39 != undefined && projectInfo.specialClause39 != ''">{{projectInfo.specialClause39}}</dd>
|
||||||
<dt>Organizations: </dt>
|
<dt *ngIf="projectInfo.organizations != undefined">Organizations: </dt>
|
||||||
<dd>{{projectInfo.organizations}}</dd>
|
<dd *ngIf="projectInfo.organizations != undefined">
|
||||||
<dt>More information:</dt>
|
<ul class="list-inline">
|
||||||
<dd>
|
<li *ngFor="let key of projectInfo.organizations.keys()">
|
||||||
|
<a *ngIf="projectInfo.organizations.get(key) != null &&
|
||||||
|
projectInfo.organizations.get(key) != ''"
|
||||||
|
href="{{projectInfo.organizations.get(key)}}" target="_blank">
|
||||||
|
{{key}}
|
||||||
|
</a>
|
||||||
|
<span *ngIf="projectInfo.organizations.get(key) == null ||
|
||||||
|
projectInfo.organizations.get(key) == ''">
|
||||||
|
{{key}}
|
||||||
|
</span>
|
||||||
|
<span>;</span>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</dd>
|
||||||
|
<dt *ngIf="projectInfo.urlInfo != undefined && projectInfo.urlInfo != ''">More information:</dt>
|
||||||
|
<dd *ngIf="projectInfo.urlInfo != undefined && projectInfo.urlInfo != ''">
|
||||||
<a target="_blank" href="{{projectInfo.url}}">
|
<a target="_blank" href="{{projectInfo.url}}">
|
||||||
{{projectInfo.urlInfo}}
|
{{projectInfo.urlInfo}}
|
||||||
</a>
|
</a>
|
||||||
|
@ -126,54 +65,77 @@ import {ProjectInfo} from '../../entities/projectInfo';
|
||||||
</dl>
|
</dl>
|
||||||
|
|
||||||
<ul class="nav nav-tabs">
|
<ul class="nav nav-tabs">
|
||||||
<li class="active"><a data-toggle="tab" href="#publicationsTab">Publications</a></li>
|
<li class="active">
|
||||||
<li><a data-toggle="tab" href="#dataTab">Research Data</a></li>
|
<a data-toggle="tab" href="#publicationsTab">
|
||||||
<li><a data-toggle="tab" href="#StatisticsTab">Statistics</a></li>
|
Publications
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a data-toggle="tab" href="#researchDataTab">
|
||||||
|
Research Data
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a data-toggle="tab" href="#statisticsTab">
|
||||||
|
Statistics
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<div class="tab-content">
|
||||||
|
<div id="publicationsTab" class="tab-pane fade in active panel-body">
|
||||||
|
|
||||||
|
<div *ngIf="projectInfo.publications == undefined" class = "alert alert-info " >
|
||||||
|
There are no publications
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-xs-6 col-sm-4" id="sidebar">
|
<div *ngIf="projectInfo.publications != undefined">
|
||||||
<h5>SHARE - BOOKMARK</h5>
|
<p>
|
||||||
<div class="panel panel-default">
|
The results below are discovered through our pilot algorithms.
|
||||||
<div class="panel-heading">
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
<h4 class="text-center">APP BOX</h4>
|
</p>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="panel-body">
|
|
||||||
|
|
||||||
<!--ul class="list-group">
|
<div id="researchDataTab" class="tab-pane fade panel-body">
|
||||||
<li class="list-group-item">
|
<div *ngIf="projectInfo.researchData == undefined" class = "alert alert-info ">
|
||||||
<a href="">
|
There are no research data
|
||||||
Publication details
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
<li class="list-group-item">
|
|
||||||
<a href="">
|
|
||||||
Dynamically incorporate publications in your site (HTML)
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
<li class="list-group-item">
|
|
||||||
<a href="">
|
|
||||||
View EC progress report (HTML)
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
<li class="list-group-item">
|
|
||||||
<a href="">
|
|
||||||
Download EC progress report (CSV)
|
|
||||||
</a>
|
|
||||||
</li>
|
|
||||||
<li class="list-group-item">
|
|
||||||
<div class="text-center">
|
|
||||||
<a class="btn btn-danger btn-block" href="">
|
|
||||||
Link Research Results
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="text-center">
|
<div *ngIf="projectInfo.researchData != undefined">
|
||||||
<a class="btn btn-danger btn-block" href="">
|
<p>
|
||||||
Deposit Publications
|
The results below are discovered through our pilot algorithms.
|
||||||
</a>
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="statisticsTab" class="tab-pane fade panel-body">
|
||||||
|
<div *ngIf="projectInfo.statistics == undefined" class = "alert alert-info ">
|
||||||
|
There are no statistics
|
||||||
|
</div>
|
||||||
|
<div *ngIf="projectInfo.statistics != undefined">
|
||||||
|
<p>
|
||||||
|
The results below are discovered through our pilot algorithms.
|
||||||
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="col-xs-12 col-sm-3" *ngIf="projectInfo != null">
|
||||||
|
<ul class="list-group mainFunctionsBlock">
|
||||||
|
<li class="list-group-item">
|
||||||
|
<dl class="functionsSection">
|
||||||
|
<dt >Share - Bookmark</dt>
|
||||||
|
<dd>
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
</li>
|
</li>
|
||||||
</ul-->
|
|
||||||
|
<li class="list-group-item">
|
||||||
|
<dl class="functionsSection">
|
||||||
|
<dt>
|
||||||
|
|
||||||
<table class="table table-striped">
|
<table class="table table-striped">
|
||||||
<tr><td>
|
<tr><td>
|
||||||
|
@ -213,7 +175,12 @@ import {ProjectInfo} from '../../entities/projectInfo';
|
||||||
</div>
|
</div>
|
||||||
</td></tr>
|
</td></tr>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</dt>
|
||||||
|
<dd>
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -228,6 +195,7 @@ export class ProjectComponent {
|
||||||
console.info('project constructor');
|
console.info('project constructor');
|
||||||
this.params = _routeParams;
|
this.params = _routeParams;
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
console.info('project init');
|
console.info('project init');
|
||||||
this.getProjectInfo();
|
this.getProjectInfo();
|
||||||
|
@ -240,15 +208,31 @@ export class ProjectComponent {
|
||||||
projectInfo: ProjectInfo;
|
projectInfo: ProjectInfo;
|
||||||
params: RouteParams;
|
params: RouteParams;
|
||||||
|
|
||||||
|
public warningMessage = "";
|
||||||
|
public errorMessage = "";
|
||||||
|
|
||||||
getProjectInfo () {
|
getProjectInfo () {
|
||||||
console.info("inside getProjectInfo of component");
|
console.info("inside getProjectInfo of component");
|
||||||
|
|
||||||
|
this.warningMessage = '';
|
||||||
|
this.errorMessage=""
|
||||||
|
if(this.params.get("projectId")==null || this.params.get("projectId")==''){
|
||||||
|
this.warningMessage="No valid project id";
|
||||||
|
console.info("novalid");
|
||||||
|
} else {
|
||||||
|
console.info("do request");
|
||||||
|
|
||||||
this._projectService.getProjectInfo(this.params.get('projectId')).subscribe(
|
this._projectService.getProjectInfo(this.params.get('projectId')).subscribe(
|
||||||
data => {
|
data => {
|
||||||
this.projectInfo = data;
|
this.projectInfo = data;
|
||||||
},
|
},
|
||||||
err => console.error(err)
|
err => {
|
||||||
|
console.error(err)
|
||||||
|
console.info("error");
|
||||||
|
|
||||||
|
this.errorMessage = 'No project found';
|
||||||
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,140 +6,63 @@ import {PublicationInfo} from '../../entities/publicationInfo';
|
||||||
import { RouteParams} from '@angular/router-deprecated';
|
import { RouteParams} from '@angular/router-deprecated';
|
||||||
import { InlineClaimContextComponent} from '../../claimPages/inlineClaimContext/inlineClaimContext.component';
|
import { InlineClaimContextComponent} from '../../claimPages/inlineClaimContext/inlineClaimContext.component';
|
||||||
import { InlineClaimProjectComponent} from '../../claimPages/inlineClaimProject/inlineClaimProject.component';
|
import { InlineClaimProjectComponent} from '../../claimPages/inlineClaimProject/inlineClaimProject.component';
|
||||||
//import {NgSwitch, ngSwitchCase, NgSwitchDefault} from '@angular/common';
|
|
||||||
|
import {TabPagingComponent} from '../tabPaging.component.ts';
|
||||||
|
import {TabTableComponent} from '../tabTable.component.ts';
|
||||||
|
import {ShowTitleComponent} from '../showTitle.component.ts';
|
||||||
|
import {ShowAuthorsComponent} from '../showAuthors.component.ts';
|
||||||
|
import {ShowIdentifiersComponent} from '../showIdentifiers.component.ts';
|
||||||
|
import {ShowSubjectsComponent} from '../showSubjects.component.ts';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'publication',
|
selector: 'publication',
|
||||||
template: `
|
template: `
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
|
|
||||||
<div class="container publication">
|
<div class="container publication">
|
||||||
<div class="container-header" >
|
<div class="container-header" >
|
||||||
<h2 *ngIf="publicationInfo != null" >{{publicationInfo.title}}</h2 >
|
<div *ngIf="publicationInfo != null">
|
||||||
|
<showTitle [title]="publicationInfo.title"></showTitle>
|
||||||
|
</div>
|
||||||
<div *ngIf="warningMessage.length > 0" class="alert alert-warning" role="alert">{{warningMessage}}</div>
|
<div *ngIf="warningMessage.length > 0" class="alert alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div *ngIf="errorMessage.length > 0" class="alert alert-danger" role="alert">{{errorMessage}}</div>
|
<div *ngIf="errorMessage.length > 0" class="alert alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row row-offcanvas row-offcanvas-right" >
|
<div class="row row-offcanvas row-offcanvas-right" >
|
||||||
|
|
||||||
<div class="col-xs-6 col-sm-9 sidebar-offcanvas" *ngIf="publicationInfo != null">
|
<div class="col-xs-6 col-sm-9 sidebar-offcanvas" *ngIf="publicationInfo != null">
|
||||||
<div>
|
<div>
|
||||||
<div *ngIf="publicationInfo.authors != undefined">
|
<showAuthors [authors]="publicationInfo.authors"></showAuthors>
|
||||||
<div *ngIf="showAllAuthors">
|
|
||||||
<a class="text-muted" (click)="showAllAuthors = !showAllAuthors;">View less authors</a>
|
|
||||||
</div>
|
|
||||||
<span *ngFor="let item of publicationInfo.authors.slice(0,30)">
|
|
||||||
<a class="custom-external" href="{{item['url']}}" target="_blank">
|
|
||||||
{{item['name']}};
|
|
||||||
</a>
|
|
||||||
</span>
|
|
||||||
<span *ngIf="!showAllAuthors && publicationInfo.authors.length > 30"> ... </span>
|
|
||||||
<span *ngIf="showAllAuthors">
|
|
||||||
<span *ngFor="let item of publicationInfo.authors.slice(30)">
|
|
||||||
<a class="custom-external" href="{{item['url']}}" target="_blank">
|
|
||||||
{{item['name']}};
|
|
||||||
</a>
|
|
||||||
</span>
|
|
||||||
</span>
|
|
||||||
<span *ngIf="!showAllAuthors && publicationInfo.authors.length > 30">
|
|
||||||
<a class="text-muted" (click)="showAllAuthors = !showAllAuthors;">
|
|
||||||
view all {{publicationInfo.authors.length}} authors
|
|
||||||
</a>
|
|
||||||
</span>
|
|
||||||
<span *ngIf="showAllAuthors">
|
|
||||||
<a class="text-muted" (click)="showAllAuthors = !showAllAuthors;">View less authors</a>
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<span *ngIf="publicationInfo.date != ''">({{publicationInfo.date}})</span>
|
<span *ngIf="publicationInfo.date != ''">({{publicationInfo.date}})</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<dl class="dl-horizontal">
|
<dl class="dl-horizontal">
|
||||||
<dt *ngIf="publicationInfo.publisher != undefined && publicationInfo.publisher != ''">Publisher: </dt>
|
<dt *ngIf="publicationInfo.publisher != undefined && publicationInfo.publisher != ''">Publisher: </dt>
|
||||||
<dd *ngIf="publicationInfo.publisher != undefined && publicationInfo.publisher != ''">{{publicationInfo.publisher}}</dd>
|
<dd *ngIf="publicationInfo.publisher != undefined && publicationInfo.publisher != ''">{{publicationInfo.publisher}}</dd>
|
||||||
<dt *ngIf="publicationInfo.journal != undefined && publicationInfo.journal != ''">Journal: </dt>
|
<dt *ngIf="publicationInfo.journal != undefined && publicationInfo.journal['journal'] != ''">Journal: </dt>
|
||||||
<dd *ngIf="publicationInfo.journal != undefined && publicationInfo.journal != ''">{{publicationInfo.journal}}</dd>
|
<dd *ngIf="publicationInfo.journal != undefined && publicationInfo.journal != ''">
|
||||||
|
{{publicationInfo.journal['journal']}}
|
||||||
|
<span *ngIf="publicationInfo.journal['issn'] != ''">
|
||||||
|
<mark>issn:</mark> {{publicationInfo.journal['issn']}}
|
||||||
|
</span>
|
||||||
|
<span *ngIf="publicationInfo.journal['lissn'] != ''">
|
||||||
|
<mark>lissn:</mark> {{publicationInfo.journal['lissn']}}
|
||||||
|
</span>
|
||||||
|
</dd>
|
||||||
<dt *ngIf="publicationInfo.languages != undefined && publicationInfo.languages != 'Undetermined' && publicationInfo.languages != ''"> Languages: </dt>
|
<dt *ngIf="publicationInfo.languages != undefined && publicationInfo.languages != 'Undetermined' && publicationInfo.languages != ''"> Languages: </dt>
|
||||||
<dd *ngIf="publicationInfo.languages != undefined && publicationInfo.languages != 'Undetermined' && publicationInfo.languages != ''">{{publicationInfo.languages}}</dd>
|
<dd *ngIf="publicationInfo.languages != undefined && publicationInfo.languages != 'Undetermined' && publicationInfo.languages != ''">{{publicationInfo.languages}}</dd>
|
||||||
<dt *ngIf="publicationInfo.types != undefined && publicationInfo.types.length > 0"> Types: </dt>
|
<dt *ngIf="publicationInfo.types != undefined && publicationInfo.types.length > 0"> Types: </dt>
|
||||||
<dd *ngIf="publicationInfo.types != undefined && publicationInfo.types.length > 0">{{publicationInfo.types}}</dd>
|
<dd *ngIf="publicationInfo.types != undefined && publicationInfo.types.length > 0">{{publicationInfo.types}}</dd>
|
||||||
|
<dt *ngIf="publicationInfo.embargoEndDate != undefined && publicationInfo.embargoEndDate != ''">Embargo end date: </dt>
|
||||||
|
<dd *ngIf="publicationInfo.embargoEndDate != undefined && publicationInfo.embargoEndDate != ''">{{publicationInfo.embargoEndDate}}</dd>
|
||||||
|
|
||||||
|
<showIdentifiers [identifiers]="publicationInfo.identifiers"></showIdentifiers>
|
||||||
<div *ngIf="publicationInfo.identifiers != undefined && publicationInfo.identifiers.size > 0">
|
<showSubjects [subjects]="publicationInfo.subjects" [classifiedSubjects]="publicationInfo.classifiedSubjects"></showSubjects>
|
||||||
<dt>Identifiers:</dt>
|
|
||||||
<dd>
|
|
||||||
<ul class="list-inline">
|
|
||||||
<li *ngFor="let key of publicationInfo.identifiers.keys()">
|
|
||||||
<!--a *ngIf="key == 'doi'" class="custom-external" href="http://dx.doi.org/{{key}}" target="_blank">
|
|
||||||
{{key}}: {{publicationInfo.identifiers.get(key)}}
|
|
||||||
</a>
|
|
||||||
<a *ngIf="key == 'pmc'" class="custom-external" href="http://europepmc.org/articles/{{key}}" target="_blank">
|
|
||||||
{{key}}: {{publicationInfo.identifiers.get(key)}}
|
|
||||||
</a>
|
|
||||||
<a *ngIf="key != 'pmc' && key != 'doi'" class="custom-external" href="http://europepmc.org/articles/{{key}}" target="_blank">
|
|
||||||
{{key}}: {{publicationInfo.identifiers.get(key)}}
|
|
||||||
</a-->
|
|
||||||
|
|
||||||
<div [ngSwitch]="key">
|
|
||||||
<template [ngSwitchWhen]="'doi'">
|
|
||||||
<a class="custom-external" href="http://dx.doi.org/{{publicationInfo.identifiers.get(key)}}" target="_blank">
|
|
||||||
{{key}}: {{publicationInfo.identifiers.get(key)}}
|
|
||||||
</a>
|
|
||||||
</template>
|
|
||||||
<template [ngSwitchWhen]="'pmc'">
|
|
||||||
<a class="custom-external" href="http://europepmc.org/articles/{{publicationInfo.identifiers.get(key)}}" target="_blank">
|
|
||||||
{{key}}: {{publicationInfo.identifiers.get(key)}}
|
|
||||||
</a>
|
|
||||||
</template>
|
|
||||||
<template ngSwitchDefault>{{key}}: {{publicationInfo.identifiers.get(key)}}</template>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</dd>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div *ngIf="publicationInfo.subjects != undefined">
|
|
||||||
<dt *ngIf="publicationInfo.subjects.length > 0 || publicationInfo.classifiedSubjects.size > 0">
|
|
||||||
Subjects:
|
|
||||||
</dt>
|
|
||||||
<dd>
|
|
||||||
<div *ngIf="publicationInfo.subjects.length > 0"> {{publicationInfo.subjects}} </div>
|
|
||||||
<div *ngIf="publicationInfo.subjects.length == 0 && publicationInfo.classifiedSubjects.size > 0"> - </div>
|
|
||||||
</dd>
|
|
||||||
|
|
||||||
<dd class="col-md-offset-1" *ngIf="publicationInfo.classifiedSubjects.size > 0">
|
|
||||||
<a (click)="showClassifiedSbj = !showClassifiedSbj;">
|
|
||||||
<div *ngIf="!showClassifiedSbj">
|
|
||||||
Show additional classifications
|
|
||||||
<span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
|
|
||||||
</div>
|
|
||||||
<div *ngIf="showClassifiedSbj">
|
|
||||||
Hide additional classifications
|
|
||||||
<span class="glyphicon glyphicon-minus" aria-hidden="true"></span>
|
|
||||||
</div>
|
|
||||||
</a>
|
|
||||||
|
|
||||||
<div class="well" *ngIf="showClassifiedSbj">
|
|
||||||
<div *ngFor="let key of publicationInfo.classifiedSubjects.keys()">
|
|
||||||
Classified by OpenAIRE into
|
|
||||||
<div>
|
|
||||||
{{key}}: {{publicationInfo.classifiedSubjects.get(key)}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</dd>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
|
|
||||||
</dl>
|
</dl>
|
||||||
|
|
||||||
<blockquote *ngIf="publicationInfo.description != ''">
|
<blockquote *ngIf="publicationInfo.description != ''">
|
||||||
{{publicationInfo.description}}
|
<div class="text-justify" [innerHTML]="publicationInfo.description"></div>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<ul class="nav nav-tabs">
|
<ul class="nav nav-tabs">
|
||||||
<li class="active">
|
<li class="active">
|
||||||
<a data-toggle="tab" href="#citationsTab">
|
<a data-toggle="tab" href="#citationsTab">
|
||||||
|
@ -148,25 +71,34 @@ import { InlineClaimProjectComponent} from '../../claimPages/inlineClaimProject/
|
||||||
<span *ngIf="publicationInfo.references != undefined" class="badge">
|
<span *ngIf="publicationInfo.references != undefined" class="badge">
|
||||||
{{publicationInfo.references.length}}
|
{{publicationInfo.references.length}}
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<!--span [ngSwitch]="publicationInfo.references || undefined" class="badge">
|
|
||||||
<template [ngSwitchWhen]="undefined">0</template>
|
|
||||||
<template ngSwitchDefault>{{publicationInfo.references.length}}</template>
|
|
||||||
</span-->
|
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li role="presentation">
|
<li role="presentation">
|
||||||
<a data-toggle="tab" href="#dataTab">
|
<a data-toggle="tab" href="#relatedTab">
|
||||||
Related Research Data
|
Related Research Results
|
||||||
<span *ngIf="publicationInfo.relatedResearchData == undefined" class="badge">0</span>
|
<span *ngIf="publicationInfo.relatedResearchResults == undefined" class="badge">0</span>
|
||||||
<span *ngIf="publicationInfo.relatedResearchData != undefined" class="badge">{{publicationInfo.relatedResearchData.size}}</span>
|
<span *ngIf="publicationInfo.relatedResearchResults != undefined" class="badge">
|
||||||
|
{{publicationInfo.relatedResearchResults.length}}
|
||||||
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li role="presentation">
|
<li role="presentation">
|
||||||
<a data-toggle="tab" href="#similarTab">
|
<a data-toggle="tab" href="#similarTab">
|
||||||
Similar Publications
|
Similar Research Results
|
||||||
<span *ngIf="publicationInfo.similarPublications == undefined" class="badge">0</span>
|
<span *ngIf="publicationInfo.similarResearchResults == undefined" class="badge">0</span>
|
||||||
<span *ngIf="publicationInfo.similarPublications != undefined" class="badge">{{publicationInfo.similarPublications.size}}</span>
|
<span *ngIf="publicationInfo.similarResearchResults != undefined" class="badge">
|
||||||
|
{{publicationInfo.similarResearchResults.length}}
|
||||||
|
</span>
|
||||||
|
<!--span *ngIf="publicationInfo.similarPublications == undefined && publicationInfo.similarDatasets == undefined" class="badge">0</span>
|
||||||
|
<span *ngIf="publicationInfo.similarPublications != undefined && publicationInfo.similarDatasets != undefined" class="badge">
|
||||||
|
{{publicationInfo.similarPublications.length + publicationInfo.similarDatasets.length}}
|
||||||
|
</span>
|
||||||
|
<span *ngIf="publicationInfo.similarPublications != undefined && publicationInfo.similarDatasets == undefined" class="badge">
|
||||||
|
{{publicationInfo.similarPublications.length}}
|
||||||
|
</span>
|
||||||
|
<span *ngIf="publicationInfo.similarPublications == undefined && publicationInfo.similarDatasets != undefined" class="badge">
|
||||||
|
{{publicationInfo.similarDatasets.length}}
|
||||||
|
</span-->
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li role="presentation" *ngIf="publicationInfo.bioentities != undefined">
|
<li role="presentation" *ngIf="publicationInfo.bioentities != undefined">
|
||||||
|
@ -178,199 +110,205 @@ import { InlineClaimProjectComponent} from '../../claimPages/inlineClaimProject/
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<div class="tab-content">
|
<div class="tab-content">
|
||||||
|
|
||||||
<div id="citationsTab" class="tab-pane fade in active panel-body">
|
<div id="citationsTab" class="tab-pane fade in active panel-body">
|
||||||
|
|
||||||
<div *ngIf="publicationInfo.references == undefined" class = "alert alert-info " >
|
<div *ngIf="publicationInfo.references == undefined" class = "alert alert-info " >
|
||||||
There are no references
|
There are no references
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div *ngIf="publicationInfo.references != undefined">
|
<div *ngIf="publicationInfo.references != undefined">
|
||||||
|
<tabPaging [showAll]="showAllReferences" [length]="publicationInfo.references.length" (changeShowAll)="showChange($event)"></tabPaging>
|
||||||
|
|
||||||
<div class="panel panel-default" *ngIf="!showAllReferences && publicationInfo.references.length > 10">
|
<p>
|
||||||
<div class="panel-heading">
|
The results below are discovered through our pilot algorithms.
|
||||||
<a (click)="showAllReferences = true;">
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
<div class="text-right">view all {{publicationInfo.references.length}}</div>
|
</p>
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div *ngIf="!showAllReferences">
|
|
||||||
<div *ngFor="let item of publicationInfo.references.slice(0,10)">
|
<div *ngFor="let item of publicationInfo.references.slice(0,10)">
|
||||||
<p *ngIf=" item != undefined && item['url'] != undefined">
|
<p *ngIf=" item != undefined && item['url'] != undefined">
|
||||||
<a class="custom-external" href="{{item['url']}}" target="_blank">
|
<a href="{{item['url']}}" target="_blank">
|
||||||
{{item['text']}}
|
{{item['name']}}
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
<p *ngIf="item['url'] == undefined">
|
<p *ngIf="item['url'] == undefined">
|
||||||
{{item['text']}}
|
{{item['name']}}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div *ngIf="showAllReferences">
|
<div *ngIf="showAllReferences">
|
||||||
<div *ngFor="let item of publicationInfo.references.slice(10)">
|
<div *ngFor="let item of publicationInfo.references.slice(10)">
|
||||||
<p *ngIf=" item != undefined && item['url'] != undefined">
|
<p *ngIf=" item != undefined && item['url'] != undefined">
|
||||||
<a class="custom-external" href="{{item['url']}}" target="_blank">
|
<a href="{{item['url']}}" target="_blank">
|
||||||
{{item['text']}}
|
{{item['name']}}
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
<p *ngIf="item['url'] == undefined">
|
<p *ngIf="item['url'] == undefined">
|
||||||
{{item['text']}}
|
{{item['name']}}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="panel panel-default" *ngIf="!showAllReferences && publicationInfo.references.length > 10">
|
<tabPaging [showAll]="showAllReferences" [length]="publicationInfo.references.length" (changeShowAll)="showChange($event)"></tabPaging>
|
||||||
<div class="text-right" class="panel-heading">
|
|
||||||
<a (click)="showAllReferences = true;">
|
|
||||||
<div class="text-right" >view all {{publicationInfo.references.length}}</div>
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="dataTab" class="tab-pane fade panel-body">
|
<div id="relatedTab" class="tab-pane fade panel-body">
|
||||||
<div *ngIf="publicationInfo.relatedResearchData == undefined" class = "alert alert-info " >
|
<div *ngIf="publicationInfo.relatedResearchResults == undefined" class = "alert alert-info ">
|
||||||
There are no related research data
|
There are no related research results
|
||||||
</div>
|
</div>
|
||||||
<table *ngIf="publicationInfo.relatedResearchData != undefined" id="inferredTable" class="table table-striped">
|
<div *ngIf="publicationInfo.relatedResearchResults != undefined">
|
||||||
<thead>
|
<p>
|
||||||
<tr role="row">
|
The results below are discovered through our pilot algorithms.
|
||||||
<th>Title</th>
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
<th>Trust</th>
|
</p>
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
<tr *ngFor="let key of publicationInfo.relatedResearchData.keys()">
|
|
||||||
<td *ngIf="key != undefined">
|
|
||||||
<a class="custom-external" href="{{key}}" target="_blank">
|
|
||||||
{{publicationInfo.relatedResearchData.get(key)[0]}}
|
|
||||||
</a>
|
|
||||||
<span *ngIf="publicationInfo.relatedResearchData.get(key)[1] != ''">
|
|
||||||
({{publicationInfo.relatedResearchData.get(key)[1]}})
|
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<div class="progress">
|
|
||||||
<div class="progress-bar progress-bar-warning" role="progressbar" aria-valuenow="29" aria-valuemin="0" aria-valuemax="100" [style.width] = "publicationInfo.relatedResearchData.get(key)[2]">
|
|
||||||
{{publicationInfo.relatedResearchData.get(key)[2]}}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
</tbody>
|
<tabTable [info]="publicationInfo.relatedResearchResults"></tabTable>
|
||||||
</table>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="similarTab" class="tab-pane fade panel-body">
|
<div id="similarTab" class="tab-pane fade panel-body">
|
||||||
<div *ngIf="publicationInfo.similarPublications == undefined" class = "alert alert-info " >
|
<div *ngIf="publicationInfo.similarResearchResults == undefined" class = "alert alert-info ">
|
||||||
There are no similar publications
|
There are no similar research results
|
||||||
</div>
|
</div>
|
||||||
<table *ngIf="publicationInfo.similarPublications != undefined" id="similarTable" class="table table-striped">
|
<div *ngIf="publicationInfo.similarResearchResults != undefined">
|
||||||
<thead>
|
<p>
|
||||||
<tr>
|
The results below are discovered through our pilot algorithms.
|
||||||
<th>Title</th>
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
<th>Trust</th>
|
</p>
|
||||||
</tr>
|
|
||||||
</thead>
|
<tabTable [info]="publicationInfo.similarResearchResults"></tabTable>
|
||||||
<tbody >
|
|
||||||
<tr *ngFor="let key of publicationInfo.similarPublications.keys()">
|
|
||||||
<td *ngIf="key != undefined">
|
|
||||||
<a class="custom-external" href="{{key}}" target="_blank">
|
|
||||||
{{publicationInfo.similarPublications.get(key)[0]}}
|
|
||||||
</a>
|
|
||||||
<span *ngIf="publicationInfo.similarPublications.get(key)[1] != ''">
|
|
||||||
({{publicationInfo.similarPublications.get(key)[1]}})
|
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<div class="progress">
|
|
||||||
<div class="progress-bar progress-bar-warning" role="progressbar" aria-valuenow="29" aria-valuemin="0" aria-valuemax="100" [style.width] = "publicationInfo.similarPublications.get(key)[2]">
|
|
||||||
{{publicationInfo.similarPublications.get(key)[2]}}</div>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
|
<!--div *ngIf="publicationInfo.similarPublications == undefined && publicationInfo.similarDatasets == undefined" class = "alert alert-info " >
|
||||||
|
There are no similar research data
|
||||||
|
</div>
|
||||||
|
<div *ngIf="publicationInfo.similarPublications != undefined || publicationInfo.similarDatasets != undefined">
|
||||||
|
<p>
|
||||||
|
The results below are discovered through our pilot algorithms.
|
||||||
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
|
</p>
|
||||||
|
|
||||||
</tbody>
|
<div *ngIf="publicationInfo.similarPublications != undefined">
|
||||||
</table>
|
<tabTable [info]="publicationInfo.similarPublications"></tabTable>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div *ngIf="publicationInfo.similarDatasets != undefined">
|
||||||
|
<tabTable [info]="publicationInfo.similarDatasets"></tabTable>
|
||||||
|
</div>
|
||||||
|
</div-->
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="publicationInfo.bioentities != undefined" id="bioentitiesTab" class="tab-pane fade panel-body">
|
<div *ngIf="publicationInfo.bioentities != undefined" id="bioentitiesTab" class="tab-pane fade panel-body">
|
||||||
|
<p>
|
||||||
|
The results below are discovered through our pilot algorithms.
|
||||||
|
<a href="mailto:">Let us know how we are doing!</a>
|
||||||
|
</p>
|
||||||
<table id="bioentitiesTable" class="table table-striped">
|
<table id="bioentitiesTable" class="table table-striped">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Bio Entity</th>
|
<th class="text-center">Bio Entity</th>
|
||||||
<th>Site Name</th>
|
<th class="text-center">Site Name</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<div *ngIf="publicationInfo.bioentities != undefined">
|
|
||||||
<tbody *ngFor="let key of publicationInfo.bioentities.keys()">
|
<tbody *ngFor="let key of publicationInfo.bioentities.keys()">
|
||||||
<div *ngIf="publicationInfo.bioentities.get(key) != undefined">
|
|
||||||
<tr *ngFor="let keyIn of publicationInfo.bioentities.get(key).keys()">
|
<tr *ngFor="let keyIn of publicationInfo.bioentities.get(key).keys()">
|
||||||
<td *ngIf="keyIn != undefined">
|
<td class="text-center" *ngIf="keyIn != undefined">
|
||||||
<a href="{{publicationInfo.bioentities.get(key).get(keyIn)}}" target="_blank">
|
<a href="{{publicationInfo.bioentities.get(key).get(keyIn)}}" target="_blank">
|
||||||
{{keyIn}}
|
{{keyIn}}
|
||||||
</a>
|
</a>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td class="text-center">
|
||||||
{{key}}
|
{{key}}
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</div>
|
|
||||||
</tbody>
|
</tbody>
|
||||||
|
|
||||||
</div>
|
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-xs-12 col-sm-3" *ngIf="publicationInfo != null">
|
<div class="col-xs-12 col-sm-3" *ngIf="publicationInfo != null">
|
||||||
|
|
||||||
<ul class="list-group mainFunctionsBlock">
|
<ul class="list-group mainFunctionsBlock">
|
||||||
<li class="list-group-item">
|
<li class="list-group-item">
|
||||||
<dl class="functionsSection" *ngIf="publicationInfo.collectedFrom != undefined">
|
<dl class="functionsSection">
|
||||||
|
<dt >Share - Bookmark</dt>
|
||||||
|
<dd>
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
|
</li>
|
||||||
|
<li class="list-group-item" *ngIf="publicationInfo.collectedFrom != undefined">
|
||||||
|
<dl class="functionsSection">
|
||||||
<dt >Collected from</dt>
|
<dt >Collected from</dt>
|
||||||
<dd *ngFor="let key of publicationInfo.collectedFrom.keys()">
|
<dd *ngFor="let item of publicationInfo.collectedFrom">
|
||||||
<a href="{{publicationInfo.collectedFrom.get(key)}}">
|
<a href="{{item['url']}}">
|
||||||
|
{{item['name']}}
|
||||||
|
</a>
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
|
</li>
|
||||||
|
<li class="list-group-item" *ngIf="publicationInfo.downloadFrom != undefined && publicationInfo.downloadFrom.size > 0">
|
||||||
|
<dl class="functionsSection">
|
||||||
|
<dt class="title">Download from</dt>
|
||||||
|
<dd class="line" *ngFor="let key of publicationInfo.downloadFrom.keys()">
|
||||||
|
<div *ngIf="publicationInfo.downloadFrom.get(key)['url'].length > 1">
|
||||||
|
{{key}}
|
||||||
|
<span *ngFor="let url of publicationInfo.downloadFrom.get(key)['url']; let i=index;">
|
||||||
|
<a href="{{url}}">
|
||||||
|
[{{i+1}}]
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<a *ngIf="publicationInfo.downloadFrom.get(key)['url'].length == 1" href="{{publicationInfo.downloadFrom.get(key)['url']}}">
|
||||||
{{key}}
|
{{key}}
|
||||||
</a>
|
</a>
|
||||||
</dd>
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
</li>
|
</li>
|
||||||
<li class="list-group-item">
|
<li class="list-group-item" *ngIf="publicationInfo.publishedIn != undefined && publicationInfo.publishedIn.length > 0">
|
||||||
<dl class="functionsSection" *ngIf="publicationInfo.downloadFrom != undefined && publicationInfo.downloadFrom.size > 0">
|
<dl class="functionsSection">
|
||||||
<dt class="title">Download from</dt>
|
<dt class="title">Published in</dt>
|
||||||
<dd class="line" *ngFor="let key of publicationInfo.downloadFrom.keys()">
|
<dd class="line" *ngFor="let key of publicationInfo.publishedIn.keys()">
|
||||||
<a href="{{key}}">
|
<div *ngIf="publicationInfo.publishedIn.get(key)['url'].length > 1">
|
||||||
{{publicationInfo.downloadFrom.get(key)[1]}}
|
{{key}}
|
||||||
|
<span *ngFor="let url of publicationInfo.publishedIn.get(key)['url']; let i=index">
|
||||||
|
<a href="{{url}}">
|
||||||
|
[{{i+1}}]
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<a *ngIf="publicationInfo.publishedIn.get(key)['url'].length == 1" href="{{publicationInfo.publishedIn.get(key)['url']}}">
|
||||||
|
{{key}}
|
||||||
</a>
|
</a>
|
||||||
</dd>
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
|
||||||
<li class="list-group-item">
|
<li class="list-group-item">
|
||||||
<dl class="functionsSection" *ngIf="publicationInfo.fundedByProjects != undefined">
|
<dl class="functionsSection" *ngIf="publicationInfo.fundedByProjects != undefined">
|
||||||
<dt class="title">Funded By</dt>
|
<dt class="title">Funded By</dt>
|
||||||
<dd class="line" *ngFor="let key of publicationInfo.fundedByProjects.values()">
|
<dd
|
||||||
<a *ngIf="!key[5]" href="{{publicationInfo.fundedByProjects.get(key)}}">
|
title="{{item['title']}}
|
||||||
{{key[0]?key[0]:key[1]}} | {{ (key[4])?key[4]:key[3]}} </a>
|
| Project Code: {{item['acronym']}}
|
||||||
|
| Funder: {{item['funderName']}} ({{item['funderShortname']}})
|
||||||
<a *ngIf="key[5]" href="{{publicationInfo.fundedByProjects.get(key)}}">
|
| Funding: {{item['funding']}}"
|
||||||
<mark>{{((key[0])?key[0]:key[1])}} | {{ ((key[4])?key[4]:key[3])}} </mark> </a>
|
class="line" *ngFor="let item of publicationInfo.fundedByProjects">
|
||||||
|
<a *ngIf="!item['new']" href="{{item['url']}}">
|
||||||
|
{{item['funderShortname']?item['funderShortname']:item['funderName']}}
|
||||||
|
| {{ item['acronym']?item['acronym']:item['title']}}
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a *ngIf="item['new']" href="{{item['url']}}">
|
||||||
|
<mark>
|
||||||
|
{{item['funderShortname']?item['funderShortname']:item['funderName']}}
|
||||||
|
| {{ item['acronym']?item['acronym']:item['title']}}
|
||||||
|
</mark>
|
||||||
|
</a>
|
||||||
</dd>
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
<dl class="functionsSection" *ngIf="publicationInfo.fundedByProjects == undefined">
|
<!--dl class="functionsSection" *ngIf="publicationInfo.fundedByProjects == undefined">
|
||||||
<dt class="title">Funded By</dt>
|
<dt class="title">Funded By</dt>
|
||||||
</dl>
|
</dl-->
|
||||||
<button (click)="toggleClaimProject()" class = "btn btn-default btn-xs" >Add more Projects</button>
|
<button (click)="toggleClaimProject()" class = "btn btn-default btn-xs" >Add more Projects</button>
|
||||||
<inline-claim-project *ngIf="result " inline="true" inlineType ="publication" [inlineEntity]="result" (projectAdded)="projectAdded($event)" ></inline-claim-project>
|
<inline-claim-project *ngIf="result " inline="true" inlineType ="publication" [inlineEntity]="result" (projectAdded)="projectAdded($event)" ></inline-claim-project>
|
||||||
</li>
|
</li>
|
||||||
|
@ -390,20 +328,16 @@ import { InlineClaimProjectComponent} from '../../claimPages/inlineClaimProject/
|
||||||
<button (click)=" toggleClaimContext()" class = "btn btn-default btn-xs" >Add Contexts</button>
|
<button (click)=" toggleClaimContext()" class = "btn btn-default btn-xs" >Add Contexts</button>
|
||||||
<inline-claim-context inline="true" inlineType ="publication" [inlineEntity]="result" ></inline-claim-context>
|
<inline-claim-context inline="true" inlineType ="publication" [inlineEntity]="result" ></inline-claim-context>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
`,
|
`,
|
||||||
providers:[JSONP_PROVIDERS, PublicationService],
|
providers:[JSONP_PROVIDERS, PublicationService],
|
||||||
directives:[InlineClaimContextComponent, InlineClaimProjectComponent]
|
directives:[InlineClaimContextComponent, InlineClaimProjectComponent,
|
||||||
|
TabPagingComponent, TabTableComponent, ShowTitleComponent,
|
||||||
|
ShowAuthorsComponent, ShowIdentifiersComponent, ShowSubjectsComponent]
|
||||||
})
|
})
|
||||||
|
|
||||||
export class PublicationComponent {
|
export class PublicationComponent {
|
||||||
|
@ -411,6 +345,7 @@ export class PublicationComponent {
|
||||||
console.info('publication constructor');
|
console.info('publication constructor');
|
||||||
this.params = _routeParams;
|
this.params = _routeParams;
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.getPublicationInfo();
|
this.getPublicationInfo();
|
||||||
}
|
}
|
||||||
|
@ -418,12 +353,11 @@ export class PublicationComponent {
|
||||||
private publicationInfo: PublicationInfo;
|
private publicationInfo: PublicationInfo;
|
||||||
private params: RouteParams;
|
private params: RouteParams;
|
||||||
|
|
||||||
private showAllAuthors: boolean = false;
|
|
||||||
private showStyle: boolean = false;
|
|
||||||
private showAllReferences: boolean = false;
|
private showAllReferences: boolean = false;
|
||||||
private showAllRelResData: boolean = false;
|
private showAllRelResData: boolean = false;
|
||||||
private showAllSimilPubl: boolean = false;
|
private showAllSimilPubl: boolean = false;
|
||||||
private showAllBioentities: boolean = false;
|
private showAllBioentities: boolean = false;
|
||||||
|
private showFundingDetails: boolean = false;
|
||||||
|
|
||||||
private bioentitiesNum: number = 0;
|
private bioentitiesNum: number = 0;
|
||||||
|
|
||||||
|
@ -470,9 +404,7 @@ console.info("do request");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/********** Methods for Inline Claim of project / publication ******/
|
||||||
********* Methods for Inline Claim of project / publication *****
|
|
||||||
*/
|
|
||||||
toggleClaimProject(){
|
toggleClaimProject(){
|
||||||
this.inlineClaimProject.toggle();
|
this.inlineClaimProject.toggle();
|
||||||
}
|
}
|
||||||
|
@ -482,15 +414,22 @@ console.info("do request");
|
||||||
for(var i=0; i < projects.length; i++){
|
for(var i=0; i < projects.length; i++){
|
||||||
|
|
||||||
if(this.publicationInfo.fundedByProjects == undefined) {
|
if(this.publicationInfo.fundedByProjects == undefined) {
|
||||||
this.publicationInfo.fundedByProjects = new Map<string, string[]>();
|
this.publicationInfo.fundedByProjects = new Array<
|
||||||
|
{ "url": string, "acronym": string, "title": string,
|
||||||
|
"funderShortname": string, "funderName": string,
|
||||||
|
"funding": string, "new": boolean
|
||||||
|
}>();
|
||||||
}
|
}
|
||||||
var project =projects[i];
|
var project =projects[i];
|
||||||
this.publicationInfo.fundedByProjects.set(project.projectId, new Array<string>());
|
|
||||||
this.publicationInfo.fundedByProjects.get(project.projectId)[0] = project.projectAcronym;
|
let counter = this.publicationInfo.fundedByProjects.length;
|
||||||
this.publicationInfo.fundedByProjects.get(project.projectId)[1] = project.projectName;
|
this.publicationInfo.fundedByProjects[counter]['url'] =
|
||||||
this.publicationInfo.fundedByProjects.get(project.projectId)[2] =project.selectedFunderId;
|
"http://localhost:3000/project?projectId="+project.projectId;
|
||||||
this.publicationInfo.fundedByProjects.get(project.projectId)[3] = project.selectedFunderName;
|
this.publicationInfo.fundedByProjects[counter]['acronym'] = project.projectAcronym;
|
||||||
this.publicationInfo.fundedByProjects.get(project.projectId)[5] = "new";
|
this.publicationInfo.fundedByProjects[counter]['title'] = project.projectName;
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['funderShortname'] = project.selectedFunderId;
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['funderName'] = project.selectedFunderName;
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['new'] = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -501,8 +440,11 @@ console.info("do request");
|
||||||
var contexts =$event.value;
|
var contexts =$event.value;
|
||||||
if(contexts){
|
if(contexts){
|
||||||
for(var i=0; i < contexts.length; i++){
|
for(var i=0; i < contexts.length; i++){
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
showChange($event) {
|
||||||
}
|
this.showAllReferences=$event.value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,13 +14,16 @@ export class ProjectService {
|
||||||
console.info("getProjectInfo in service");
|
console.info("getProjectInfo in service");
|
||||||
|
|
||||||
//let url = 'http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/projects/'+id;
|
//let url = 'http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/projects/'+id;
|
||||||
let url = 'http://scoobydoo.di.uoa.gr:8181/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/projects/'+id;
|
//let url = 'http://scoobydoo.di.uoa.gr:8181/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/projects/'+id;
|
||||||
|
let url = 'http://astero.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/projects/'+id;
|
||||||
|
|
||||||
return this.http.get(url)
|
return this.http.get(url)
|
||||||
.map(res => <any> res.json())
|
.map(res => <any> res.json())
|
||||||
.map(res => [res['result']['metadata']['oaf:entity']['oaf:project'],
|
.map(res => res['result']['metadata']['oaf:entity']['oaf:project'])
|
||||||
res['result']['metadata']['oaf:entity']['oaf:project']['fundingtree'],
|
.do(res => console.info(res))
|
||||||
res['result']['metadata']['oaf:entity']['oaf:project']['rels']['rel']])
|
.map(res => [res,
|
||||||
|
res['fundingtree'],
|
||||||
|
res['rels']['rel']])
|
||||||
.map(res => this.parseProjectInfo(res));
|
.map(res => this.parseProjectInfo(res));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -73,19 +76,34 @@ export class ProjectService {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[2] != null) {
|
if(data[2] != null) {
|
||||||
this.projectInfo.organizations = new Array<string>();
|
this.projectInfo.organizations = new Map<string, string>();
|
||||||
|
|
||||||
|
let name = "";
|
||||||
|
let url = "";
|
||||||
|
|
||||||
|
if(!Array.isArray(data[2])) {
|
||||||
if(data[2].hasOwnProperty("legalshortname")) {
|
if(data[2].hasOwnProperty("legalshortname")) {
|
||||||
this.projectInfo.organizations[0] = data[2].legalshortname;
|
name = data[2].legalshortname;
|
||||||
} else if(data[2].hasOwnProperty("legalname")) {
|
} else if(data[2].hasOwnProperty("legalname")) {
|
||||||
this.projectInfo.organizations[0] = data[2].legalname;
|
name = data[2].legalname;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(data[2].hasOwnProperty("to")) {
|
||||||
|
url = "https://beta.openaire.eu/search/organization?organizationId="+data[2]['to'].content;
|
||||||
|
}
|
||||||
|
this.projectInfo.organizations.set(name, url);
|
||||||
} else {
|
} else {
|
||||||
for(let i=0; i<data[2].length; i++) {
|
for(let i=0; i<data[2].length; i++) {
|
||||||
if(data[2][i].hasOwnProperty("legalshortname")) {
|
if(data[2][i].hasOwnProperty("legalshortname")) {
|
||||||
this.projectInfo.organizations[i] = data[2][i].legalshortname;
|
name = data[2][i].legalshortname;
|
||||||
} else if(data[2][i].hasOwnProperty("legalname")) {
|
} else if(data[2][i].hasOwnProperty("legalname")) {
|
||||||
this.projectInfo.organizations[i] = data[2][i].legalname;
|
name = data[2][i].legalname;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(data[2][i].hasOwnProperty("to")) {
|
||||||
|
url = "https://beta.openaire.eu/search/organization?organizationId="+data[2][i]['to'].content;
|
||||||
|
}
|
||||||
|
this.projectInfo.organizations.set(name, url);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,24 +14,25 @@ export class PublicationService {
|
||||||
console.info("getPublicationInfo in service");
|
console.info("getPublicationInfo in service");
|
||||||
|
|
||||||
//let url = 'http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/publications/'+id;
|
//let url = 'http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/publications/'+id;
|
||||||
let url = 'http://scoobydoo.di.uoa.gr:8181/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/publications/'+id;
|
//let url = 'http://scoobydoo.di.uoa.gr:8181/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/publications/'+id;
|
||||||
|
let url = 'http://astero.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/publications/'+id;
|
||||||
|
|
||||||
return this.http.get(url)
|
return this.http.get(url)
|
||||||
.map(res => <any> res.json())
|
.map(res => <any> res.json())
|
||||||
.do(res => console.info(res['result']['metadata']['oaf:entity']))
|
.do(res => console.info(res['result']['metadata']['oaf:entity']))
|
||||||
.do(res => console.info(res['result']['metadata']['oaf:entity']['oaf:result']['children']['instance']))
|
.map(res => res['result']['metadata']['oaf:entity'])
|
||||||
.map(res => [res['result']['metadata']['oaf:entity']['oaf:result'],
|
.map(res => [res['oaf:result'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['title'],
|
res['oaf:result']['title'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['rels']['rel'],
|
res['oaf:result']['rels']['rel'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['children'],
|
res['oaf:result']['children'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['pid'],
|
res['oaf:result']['pid'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['journal'],
|
res['oaf:result']['journal'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['language'],
|
res['oaf:result']['language'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['subject'],
|
res['oaf:result']['subject'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['bestlicense'],
|
res['oaf:result']['bestlicense'],
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['collectedfrom'],
|
res['oaf:result']['collectedfrom'],
|
||||||
(res['result']['metadata']['oaf:entity']['extraInfo']!= undefined && res['result']['metadata']['oaf:entity']['extraInfo']['citations']!= undefined)? res['result']['metadata']['oaf:entity']['extraInfo']['citations']['citation']:null,
|
(res['extraInfo']!= undefined && res['extraInfo']['citations']!= undefined)? res['extraInfo']['citations']['citation']:null,
|
||||||
res['result']['metadata']['oaf:entity']['oaf:result']['context']
|
res['oaf:result']['context']
|
||||||
])
|
])
|
||||||
.map(res => this.parsePublicationInfo(res));
|
.map(res => this.parsePublicationInfo(res));
|
||||||
|
|
||||||
|
@ -50,16 +51,26 @@ export class PublicationService {
|
||||||
if(data[0] != null) {
|
if(data[0] != null) {
|
||||||
this.publicationInfo.date = data[0].dateofacceptance.substring(0,4);
|
this.publicationInfo.date = data[0].dateofacceptance.substring(0,4);
|
||||||
this.publicationInfo.publisher = data[0].publisher;
|
this.publicationInfo.publisher = data[0].publisher;
|
||||||
|
if(!Array.isArray(data[0].description)) {
|
||||||
this.publicationInfo.description = data[0].description;
|
this.publicationInfo.description = data[0].description;
|
||||||
|
} else {
|
||||||
|
this.publicationInfo.description = data[0].description[0];
|
||||||
|
}
|
||||||
|
this.publicationInfo.embargoEndDate = data[0].embargoenddate;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[1] != null) {
|
if(data[1] != null) {
|
||||||
this.publicationInfo.title = data[1].content;
|
this.publicationInfo.title = {"name": "", "url": "", "accessMode": ""};
|
||||||
|
|
||||||
|
if(Array.isArray(data[1])) {
|
||||||
|
this.publicationInfo.title['name'] = data[1][0].content;
|
||||||
|
} else {
|
||||||
|
this.publicationInfo.title['name'] = data[1].content;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[2] != null) {
|
if(data[2] != null) {
|
||||||
let mydata;
|
let mydata;
|
||||||
let funding;
|
|
||||||
let counter = 0;
|
let counter = 0;
|
||||||
let length = data[2].length!=undefined ? data[2].length : 1;
|
let length = data[2].length!=undefined ? data[2].length : 1;
|
||||||
|
|
||||||
|
@ -68,69 +79,176 @@ export class PublicationService {
|
||||||
if(mydata.hasOwnProperty("to")) {
|
if(mydata.hasOwnProperty("to")) {
|
||||||
if(mydata['to'].class == "hasAuthor") {
|
if(mydata['to'].class == "hasAuthor") {
|
||||||
if(this.publicationInfo.authors == undefined) {
|
if(this.publicationInfo.authors == undefined) {
|
||||||
this.publicationInfo.authors = new Array<{[key: string]: string}>();
|
this.publicationInfo.authors = new Array<{"name": string, "url": string}>();
|
||||||
}
|
}
|
||||||
|
|
||||||
this.publicationInfo.authors[mydata.ranking-1] = {};
|
this.publicationInfo.authors[mydata.ranking-1] = {"name": "", "url": ""};
|
||||||
this.publicationInfo.authors[mydata.ranking-1]['name'] = mydata.fullname;
|
this.publicationInfo.authors[mydata.ranking-1]['name'] = mydata.fullname;
|
||||||
this.publicationInfo.authors[mydata.ranking-1]['url'] = "https://beta.openaire.eu/search/person?personId="+mydata['to'].content;
|
this.publicationInfo.authors[mydata.ranking-1]['url'] = "https://beta.openaire.eu/search/person?personId="+mydata['to'].content;
|
||||||
} else if(mydata['to'].class == "isProducedBy") {
|
} else if(mydata['to'].class == "isProducedBy") {
|
||||||
if(this.publicationInfo.fundedByProjects == undefined) {
|
if(this.publicationInfo.fundedByProjects == undefined) {
|
||||||
this.publicationInfo.fundedByProjects = new Map<string, string[]>();
|
this.publicationInfo.fundedByProjects = new Array<
|
||||||
|
{ "url": string, "acronym": string, "title": string,
|
||||||
|
"funderShortname": string, "funderName": string,
|
||||||
|
"funding": string, "new": boolean
|
||||||
|
}>();
|
||||||
}
|
}
|
||||||
|
|
||||||
// this.publicationInfo.fundedByProjects.set(mydata.code, new Array<string>());
|
counter = this.publicationInfo.fundedByProjects.length;
|
||||||
// this.publicationInfo.fundedByProjects.get(mydata.code)[0] = mydata.acronym;
|
|
||||||
// this.publicationInfo.fundedByProjects.get(mydata.code)[1] = mydata.title;
|
this.publicationInfo.fundedByProjects[counter] = {
|
||||||
this.publicationInfo.fundedByProjects.set(mydata['to'].content, new Array<string>());
|
"url": "", "acronym": "", "title": "",
|
||||||
this.publicationInfo.fundedByProjects.get(mydata['to'].content)[0] = mydata.acronym;
|
"funderShortname": "", "funderName": "",
|
||||||
this.publicationInfo.fundedByProjects.get(mydata['to'].content)[1] = mydata.title;
|
"funding": "", "new": false
|
||||||
if(mydata.hasOwnProperty("funding")) {
|
|
||||||
if(mydata['funding'].hasOwnProperty("funder")) {
|
|
||||||
// this.publicationInfo.fundedByProjects.get(mydata.code)[2] = mydata['funding']['funder'].shortname;
|
|
||||||
// this.publicationInfo.fundedByProjects.get(mydata.code)[3] = mydata['funding']['funder'].name;
|
|
||||||
this.publicationInfo.fundedByProjects.get(mydata['to'].content)[2] = mydata['funding']['funder'].shortname;
|
|
||||||
this.publicationInfo.fundedByProjects.get(mydata['to'].content)[3] = mydata['funding']['funder'].name;
|
|
||||||
}
|
}
|
||||||
if(mydata['funding'].hasOwnProperty("funding_level_2")) {
|
|
||||||
funding = mydata['funding']['funding_level_2'].content;
|
this.publicationInfo.fundedByProjects[counter]['url'] =
|
||||||
} else if(mydata['funding'].hasOwnProperty("funding_level_1")) {
|
"http://localhost:3000/project?projectId="+mydata['to'].content;
|
||||||
funding = mydata['funding']['funding_level_1'].content;
|
this.publicationInfo.fundedByProjects[counter]['acronym'] = mydata.acronym;
|
||||||
} else if(mydata['funding'].hasOwnProperty("funding_level_0")) {
|
this.publicationInfo.fundedByProjects[counter]['title'] = mydata.title;
|
||||||
funding = mydata['funding']['funding_level_0'].content;
|
|
||||||
|
if(mydata.hasOwnProperty("funding")) {
|
||||||
|
let length1 = Array.isArray(mydata['funding']) ? mydata['funding'].length : 1;
|
||||||
|
|
||||||
|
for(let j=0; j<length1; j++) {
|
||||||
|
let funding;
|
||||||
|
let mydata1 = length1 > 1 ? mydata['funding'][j] : mydata['funding'];
|
||||||
|
|
||||||
|
if(mydata1.hasOwnProperty("funder")) {
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['funderShortname'] = mydata1['funder'].shortname;
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['funderName'] = mydata1['funder'].name;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(mydata1.hasOwnProperty("funding_level_2")) {
|
||||||
|
funding = mydata1['funding_level_2'].content;
|
||||||
|
} else if(mydata1.hasOwnProperty("funding_level_1")) {
|
||||||
|
funding = mydata1['funding_level_1'].content;
|
||||||
|
} else if(mydata1.hasOwnProperty("funding_level_0")) {
|
||||||
|
funding = mydata1['funding_level_0'].content;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(funding != undefined) {
|
if(funding != undefined) {
|
||||||
funding = funding.split("::");
|
funding = funding.split("::");
|
||||||
// this.publicationInfo.fundedByProjects.get(mydata.code)[4] = funding[1];
|
|
||||||
this.publicationInfo.fundedByProjects.get(mydata['to'].content)[4] = funding[1];
|
if(this.publicationInfo.fundedByProjects[counter]['funding'] != "") {
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['funding'] += ", "+funding[1];
|
||||||
|
} else {
|
||||||
|
this.publicationInfo.fundedByProjects[counter]['funding'] = funding[1];
|
||||||
|
}
|
||||||
for(let i=2; i<funding.length; i++) {
|
for(let i=2; i<funding.length; i++) {
|
||||||
// this.publicationInfo.fundedByProjects.get(mydata.code)[4] += " | " + funding[i];
|
this.publicationInfo.fundedByProjects[counter]['funding'] += " | " + funding[i];
|
||||||
this.publicationInfo.fundedByProjects.get(mydata['to'].content)[4] += " | " + funding[i];
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if(mydata['to'].class == "iscontexts") {
|
}
|
||||||
if(this.publicationInfo.relatedResearchData == undefined) {
|
} else if(mydata['to'].class == "isRelatedTo") {
|
||||||
this.publicationInfo.relatedResearchData = new Map<string, string[]>();//Array<{}>();
|
/* if(mydata['resulttype'].classname == "publication") {
|
||||||
|
if(this.publicationInfo.relatedPublications == undefined) {
|
||||||
|
this.publicationInfo.relatedPublications = new Array<{
|
||||||
|
"name": string, "url": string, "date": string, "trust": string}>();
|
||||||
}
|
}
|
||||||
|
|
||||||
let url = "https://beta.openaire.eu/search/publication?articleId="+mydata['to'].content;
|
let url = "http://localhost:3000/publication?articleId="+mydata['to'].content;
|
||||||
this.publicationInfo.relatedResearchData.set(url, new Array<string>());
|
counter = this.publicationInfo.relatedPublications.length;
|
||||||
this.publicationInfo.relatedResearchData.get(url)[0] = mydata['title'].content;
|
|
||||||
this.publicationInfo.relatedResearchData.get(url)[1] = mydata.dateofacceptance.substring(0,4);
|
this.publicationInfo.relatedPublications[counter] = {"name": "", "url": "", "date": "", "trust": ""}
|
||||||
this.publicationInfo.relatedResearchData.get(url)[2] = Math.round(mydata.trust*100)+"%";
|
|
||||||
|
this.publicationInfo.relatedPublications[counter]['url'] = url;
|
||||||
|
this.publicationInfo.relatedPublications[counter]['name'] = mydata['title'].content;
|
||||||
|
this.publicationInfo.relatedPublications[counter]['date'] = mydata.dateofacceptance.substring(0,4);;
|
||||||
|
this.publicationInfo.relatedPublications[counter]['trust'] = Math.round(mydata.trust*100)+"%";
|
||||||
|
} else {
|
||||||
|
if(this.publicationInfo.relatedResearchData == undefined) {
|
||||||
|
this.publicationInfo.relatedResearchData = new Array<{
|
||||||
|
"name": string, "url": string, "date": string, "trust": string}>();
|
||||||
|
}
|
||||||
|
|
||||||
|
let url = "http://localhost:3000/dataset?datasetId="+mydata['to'].content;
|
||||||
|
counter = this.publicationInfo.relatedResearchData.length;
|
||||||
|
|
||||||
|
this.publicationInfo.relatedResearchData[counter] = {"name": "", "url": "", "date": "", "trust": ""}
|
||||||
|
|
||||||
|
this.publicationInfo.relatedResearchData[counter]['url'] = url;
|
||||||
|
this.publicationInfo.relatedResearchData[counter]['name'] = mydata['title'].content;
|
||||||
|
this.publicationInfo.relatedResearchData[counter]['date'] = mydata.dateofacceptance.substring(0,4);;
|
||||||
|
this.publicationInfo.relatedResearchData[counter]['trust'] = Math.round(mydata.trust*100)+"%";
|
||||||
|
}*/
|
||||||
|
if(this.publicationInfo.relatedResearchResults == undefined) {
|
||||||
|
this.publicationInfo.relatedResearchResults = new Array<{
|
||||||
|
"name": string, "url": string, "date": string,
|
||||||
|
"trust": string, "class": string}>();
|
||||||
|
}
|
||||||
|
|
||||||
|
counter = this.publicationInfo.relatedResearchResults.length;
|
||||||
|
this.publicationInfo.relatedResearchResults[counter] = {"name": "", "url": "", "date": "", "trust": "", "class": ""}
|
||||||
|
|
||||||
|
let url;
|
||||||
|
if(mydata['resulttype'].classname == "publication") {
|
||||||
|
url = "http://localhost:3000/publication?articleId="+mydata['to'].content;
|
||||||
|
this.publicationInfo.relatedResearchResults[counter]['class'] = "publication";
|
||||||
|
} else {
|
||||||
|
url = "http://localhost:3000/dataset?datasetId="+mydata['to'].content;
|
||||||
|
this.publicationInfo.relatedResearchResults[counter]['class'] = "dataset";
|
||||||
|
}
|
||||||
|
|
||||||
|
this.publicationInfo.relatedResearchResults[counter]['url'] = url;
|
||||||
|
this.publicationInfo.relatedResearchResults[counter]['name'] = mydata['title'].content;
|
||||||
|
this.publicationInfo.relatedResearchResults[counter]['date'] = mydata.dateofacceptance.substring(0,4);;
|
||||||
|
this.publicationInfo.relatedResearchResults[counter]['trust'] = Math.round(mydata.trust*100)+"%";
|
||||||
|
|
||||||
} else if(mydata['to'].class == "hasAmongTopNSimilarDocuments") {
|
} else if(mydata['to'].class == "hasAmongTopNSimilarDocuments") {
|
||||||
|
/*if(mydata.hasOwnProperty('resulttype') && mydata['resulttype'].classname == "publication") {
|
||||||
if(this.publicationInfo.similarPublications == undefined) {
|
if(this.publicationInfo.similarPublications == undefined) {
|
||||||
this.publicationInfo.similarPublications = new Map<string, string[]>();
|
this.publicationInfo.similarPublications = new Array<
|
||||||
|
{ "name": string, "url": string, "date": string, "trust": string}>();
|
||||||
}
|
}
|
||||||
|
|
||||||
let url = "https://beta.openaire.eu/search/publication?articleId="+mydata['to'].content;
|
let url = "http://localhost:3000/publication?articleId="+mydata['to'].content;
|
||||||
this.publicationInfo.similarPublications.set(url, new Array<string>());
|
let counter = this.publicationInfo.similarPublications.length;
|
||||||
this.publicationInfo.similarPublications.get(url)[0] = mydata['title'].content;
|
|
||||||
this.publicationInfo.similarPublications.get(url)[1] = mydata.dateofacceptance.substring(0,4);
|
this.publicationInfo.similarPublications[counter] = {"name": "", "url": "", "date": "", "trust": ""};
|
||||||
this.publicationInfo.similarPublications.get(url)[2] = Math.round(mydata.trust*100)+"%";
|
this.publicationInfo.similarPublications[counter]['url'] = url;
|
||||||
|
this.publicationInfo.similarPublications[counter]['name'] = mydata['title'].content;
|
||||||
|
this.publicationInfo.similarPublications[counter]['date'] = mydata.dateofacceptance.substring(0,4);
|
||||||
|
this.publicationInfo.similarPublications[counter]['trust'] = Math.round(mydata.trust*100)+"%";
|
||||||
|
} else if(mydata.hasOwnProperty('resulttype') && mydata['resulttype'].classname == "dataset") {
|
||||||
|
if(this.publicationInfo.similarDatasets == undefined) {
|
||||||
|
this.publicationInfo.similarDatasets = new Array<
|
||||||
|
{ "name": string, "url": string, "date": string, "trust": string}>();
|
||||||
|
}
|
||||||
|
|
||||||
|
let url = "http://localhost:3000/dataset?datasetId="+mydata['to'].content;
|
||||||
|
let counter = this.publicationInfo.similarDatasets.length;
|
||||||
|
|
||||||
|
this.publicationInfo.similarDatasets[counter] = {"name": "", "url": "", "date": "", "trust": ""};
|
||||||
|
this.publicationInfo.similarDatasets[counter]['url'] = url;
|
||||||
|
this.publicationInfo.similarDatasets[counter]['name'] = mydata['title'].content;
|
||||||
|
this.publicationInfo.similarDatasets[counter]['date'] = mydata.dateofacceptance.substring(0,4);
|
||||||
|
this.publicationInfo.similarDatasets[counter]['trust'] = Math.round(mydata.trust*100)+"%";
|
||||||
|
}*/
|
||||||
|
|
||||||
|
if(this.publicationInfo.similarResearchResults == undefined) {
|
||||||
|
this.publicationInfo.similarResearchResults = new Array<{
|
||||||
|
"name": string, "url": string, "date": string,
|
||||||
|
"trust": string, "class": string}>();
|
||||||
|
}
|
||||||
|
|
||||||
|
counter = this.publicationInfo.similarResearchResults.length;
|
||||||
|
this.publicationInfo.similarResearchResults[counter] = {"name": "", "url": "", "date": "", "trust": "", "class": ""}
|
||||||
|
|
||||||
|
let url;
|
||||||
|
if(mydata['resulttype'].classname == "publication") {
|
||||||
|
url = "http://localhost:3000/publication?articleId="+mydata['to'].content;
|
||||||
|
this.publicationInfo.similarResearchResults[counter]['class'] = "publication";
|
||||||
|
} else {
|
||||||
|
url = "http://localhost:3000/dataset?datasetId="+mydata['to'].content;
|
||||||
|
this.publicationInfo.similarResearchResults[counter]['class'] = "dataset";
|
||||||
|
}
|
||||||
|
|
||||||
|
this.publicationInfo.similarResearchResults[counter]['url'] = url;
|
||||||
|
this.publicationInfo.similarResearchResults[counter]['name'] = mydata['title'].content;
|
||||||
|
this.publicationInfo.similarResearchResults[counter]['date'] = mydata.dateofacceptance.substring(0,4);;
|
||||||
|
this.publicationInfo.similarResearchResults[counter]['trust'] = Math.round(mydata.trust*100)+"%";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -142,13 +260,17 @@ export class PublicationService {
|
||||||
|
|
||||||
if(data[3] != null) {
|
if(data[3] != null) {
|
||||||
if(data[3].hasOwnProperty("instance")) {
|
if(data[3].hasOwnProperty("instance")) {
|
||||||
this.publicationInfo.downloadFrom = new Map<string, string[]>();
|
this.publicationInfo.downloadFrom = new Map<string, {"url": string[], "accessMode": string[]}>();
|
||||||
|
this.publicationInfo.publishedIn = new Map<string, {"url": string[], "accessMode": string[]}>();
|
||||||
|
|
||||||
this.publicationInfo.types = new Array<string>();
|
this.publicationInfo.types = new Array<string>();
|
||||||
|
|
||||||
let length = data[3]['instance'].length!=undefined ? data[3]['instance'].length : 1;
|
let length = data[3]['instance'].length!=undefined ? data[3]['instance'].length : 1;
|
||||||
|
|
||||||
let types = new Set<string>();
|
let types = new Set<string>();
|
||||||
let counter = 0;
|
let counter = 0;
|
||||||
|
let counter1 = 0;
|
||||||
|
let counter2 = 0;
|
||||||
let mydata;
|
let mydata;
|
||||||
for(let i=0; i<length; i++) {
|
for(let i=0; i<length; i++) {
|
||||||
mydata = length > 1 ? data[3]['instance'][i] : data[3]['instance'];
|
mydata = length > 1 ? data[3]['instance'][i] : data[3]['instance'];
|
||||||
|
@ -169,15 +291,95 @@ export class PublicationService {
|
||||||
url = mydata['webresource'][0].url;
|
url = mydata['webresource'][0].url;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!this.publicationInfo.downloadFrom.has(url)) {
|
if(mydata.hasOwnProperty("hostedby")) {
|
||||||
this.publicationInfo.downloadFrom.set(url, new Array<string>());
|
if(mydata['hostedby'].name != "other resources" && mydata['hostedby'].name != "Unknown Repository") {
|
||||||
|
if(!this.publicationInfo.downloadFrom.has(mydata['hostedby'].name)) {
|
||||||
|
this.publicationInfo.downloadFrom.set(mydata['hostedby'].name, {"url": null, "accessMode": null});
|
||||||
|
}
|
||||||
|
|
||||||
|
if(this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['url'] == null) {
|
||||||
|
this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['url'] = new Array<string>();
|
||||||
|
}
|
||||||
|
|
||||||
|
counter2 = this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['url'].length;
|
||||||
|
this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['url'][counter2] = url;
|
||||||
|
|
||||||
|
if(this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['accessMode'] == null) {
|
||||||
|
this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['accessMode'] = new Array<string>();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(mydata.hasOwnProperty("licence")) {
|
if(mydata.hasOwnProperty("licence")) {
|
||||||
this.publicationInfo.downloadFrom.get(url)[0] = mydata['licence'].classid;
|
this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['accessMode'][counter2] = mydata['licence'].classid;
|
||||||
|
} else {
|
||||||
|
this.publicationInfo.downloadFrom.get(mydata['hostedby'].name)['accessMode'][counter2] = "";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if(data[0] != null && data[0].hasOwnProperty("source")) {
|
||||||
|
let key: string;
|
||||||
|
if(Array.isArray(data[0].source)) {
|
||||||
|
if(!this.publicationInfo.publishedIn.has(data[0]['source'][counter1])) {
|
||||||
|
key = data[0]['source'][counter1];
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if(!this.publicationInfo.publishedIn.has(data[0]['source'])) {
|
||||||
|
key = data[0]['source'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
this.publicationInfo.publishedIn.set(key, {"url": null, "accessMode": null});
|
||||||
|
|
||||||
|
if(this.publicationInfo.publishedIn.get(key)['url'] == null) {
|
||||||
|
this.publicationInfo.publishedIn.get(key)['url'] = new Array<string>();
|
||||||
|
}
|
||||||
|
|
||||||
|
counter2 = this.publicationInfo.publishedIn.get(key)['url'].length;
|
||||||
|
this.publicationInfo.publishedIn.get(key)['url'][counter2] = url;
|
||||||
|
|
||||||
|
if(this.publicationInfo.publishedIn.get(key)['accessMode'] == null) {
|
||||||
|
this.publicationInfo.publishedIn.get(key)['accessMode'] = new Array<string>();
|
||||||
|
}
|
||||||
|
|
||||||
|
if(mydata.hasOwnProperty("licence")) {
|
||||||
|
this.publicationInfo.publishedIn.get(key)['accessMode'][counter2] = mydata['licence'].classid;
|
||||||
|
} else {
|
||||||
|
this.publicationInfo.publishedIn.get(key)['accessMode'][counter2] = "";
|
||||||
|
}
|
||||||
|
counter1++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if(this.publicationInfo.title != undefined) {
|
||||||
|
if(this.publicationInfo.title['url'] == "") {
|
||||||
|
this.publicationInfo.title['url'] = url;
|
||||||
|
}
|
||||||
|
|
||||||
|
switch (this.publicationInfo.title['accessMode']) {
|
||||||
|
case undefined:
|
||||||
|
this.publicationInfo.title['accessMode'] = mydata['accessMode'].classid;
|
||||||
|
this.publicationInfo.title['url'] = url;
|
||||||
|
break;
|
||||||
|
case "CLOSED":
|
||||||
|
if(mydata['licence'].classid == "OPEN" ||
|
||||||
|
mydata['licence'].classid == "EMBARGO" ||
|
||||||
|
mydata['licence'].classid == "RESTRICTED") {
|
||||||
|
this.publicationInfo.title['accessMode'] = mydata['licence'].classid;
|
||||||
|
this.publicationInfo.title['url'] = url;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case "RESTRICTED":
|
||||||
|
if(mydata['licence'].classid == "OPEN" ||
|
||||||
|
mydata['licence'].classid == "EMBARGO") {
|
||||||
|
this.publicationInfo.title['accessMode'] = mydata['licence'].classid;
|
||||||
|
this.publicationInfo.title['url'] = url;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case "EMBARGO":
|
||||||
|
if(mydata['licence'].classid == "OPEN") {
|
||||||
|
this.publicationInfo.title['accessMode'] = mydata['licence'].classid;
|
||||||
|
this.publicationInfo.title['url'] = url;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if(mydata.hasOwnProperty("hostedby")) {
|
|
||||||
this.publicationInfo.downloadFrom.get(url)[1] = mydata['hostedby'].name;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -201,19 +403,36 @@ export class PublicationService {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[4] != null) {
|
if(data[4] != null) {
|
||||||
this.publicationInfo.identifiers = new Map<string, string>();
|
let counter = 0;
|
||||||
|
this.publicationInfo.identifiers = new Map<string, string[]>();
|
||||||
|
|
||||||
if(data[4].hasOwnProperty("classname") && data[4]['classname'] != "") {
|
if(data[4].hasOwnProperty("classname") && data[4]['classname'] != "") {
|
||||||
this.publicationInfo.identifiers.set(data[4].classname, data[4].content);
|
if(data[4].classname == "doi" || data[4].classname == "pmc") {
|
||||||
|
if(!this.publicationInfo.identifiers.has(data[4].classname)) {
|
||||||
|
this.publicationInfo.identifiers.set(data[4].classname, new Array<string>());
|
||||||
|
}
|
||||||
|
counter = this.publicationInfo.identifiers.get(data[4].classname).length;
|
||||||
|
this.publicationInfo.identifiers.get(data[4].classname)[counter] = data[4].content;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
for(let i=0; i<data[4].length; i++) {
|
for(let i=0; i<data[4].length; i++) {
|
||||||
this.publicationInfo.identifiers.set(data[4][i].classname, data[4][i].content);
|
if(data[4][i].classname == "doi" || data[4][i].classname == "pmc") {
|
||||||
|
if(!this.publicationInfo.identifiers.has(data[4][i].classname)) {
|
||||||
|
this.publicationInfo.identifiers.set(data[4][i].classname, new Array<string>());
|
||||||
|
}
|
||||||
|
counter = this.publicationInfo.identifiers.get(data[4][i].classname).length;
|
||||||
|
this.publicationInfo.identifiers.get(data[4][i].classname)[counter] = data[4][i].content;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[5] != null) {
|
if(data[5] != null) {
|
||||||
this.publicationInfo.journal = data[5].content;
|
this.publicationInfo.journal = {"journal": "", "issn": "", "lissn": ""}
|
||||||
|
|
||||||
|
this.publicationInfo.journal['journal'] = data[5].content;
|
||||||
|
this.publicationInfo.journal['issn'] = data[5].issn;
|
||||||
|
this.publicationInfo.journal['lissn'] = data[5].lissn;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[6] != null) {
|
if(data[6] != null) {
|
||||||
|
@ -259,36 +478,50 @@ export class PublicationService {
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[9] != null) {
|
if(data[9] != null) {
|
||||||
this.publicationInfo.collectedFrom = new Map<string, string>();
|
this.publicationInfo.collectedFrom = new Array<{"name": string, "url": string}>();
|
||||||
|
|
||||||
let mydata;
|
let mydata;
|
||||||
let length = data[9].length!=undefined ? data[9].length : 1;
|
let length = data[9].length!=undefined ? data[9].length : 1;
|
||||||
for(let i=0; i<length; i++) {
|
for(let i=0; i<length; i++) {
|
||||||
mydata = length > 1 ? data[9][i] : data[9];
|
mydata = length > 1 ? data[9][i] : data[9];
|
||||||
let link = "https://beta.openaire.eu/search/dataprovider?datasourceId=";
|
let link = "https://beta.openaire.eu/search/dataprovider?datasourceId=";
|
||||||
this.publicationInfo.collectedFrom.set(mydata.name, link+mydata.id);
|
this.publicationInfo.collectedFrom[i] = {"name": "", "url": ""};
|
||||||
|
this.publicationInfo.collectedFrom[i]['name'] = mydata.name;
|
||||||
|
this.publicationInfo.collectedFrom[i]['url'] = link+mydata.id;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(this.publicationInfo.journal != null
|
if(this.publicationInfo.publisher != null
|
||||||
&& this.publicationInfo.identifiers != null
|
&& this.publicationInfo.identifiers != null
|
||||||
&& this.publicationInfo.identifiers.has("doi")) {
|
&& this.publicationInfo.identifiers.has('doi')) {
|
||||||
|
|
||||||
if( this.publicationInfo.downloadFrom == null) {
|
if( this.publicationInfo.downloadFrom == null) {
|
||||||
this.publicationInfo.downloadFrom = new Map<string, string[]>();
|
this.publicationInfo.downloadFrom = new Map<string, {"url": string[], "accessMode": string[]}>();
|
||||||
}
|
}
|
||||||
|
|
||||||
let url = "http://dx.doi.org/"+this.publicationInfo.identifiers.get("doi");
|
let key: string;
|
||||||
if(!this.publicationInfo.downloadFrom.has(url)) {
|
if(this.publicationInfo.journal != null) {
|
||||||
this.publicationInfo.downloadFrom.set(url, new Array<string>());
|
key = this.publicationInfo.publisher + "/ "+this.publicationInfo.journal
|
||||||
|
} else {
|
||||||
|
key = this.publicationInfo.publisher;
|
||||||
}
|
}
|
||||||
|
this.publicationInfo.downloadFrom.set(key, {"url": null, "accessMode": null});
|
||||||
|
|
||||||
this.publicationInfo.downloadFrom.get(url)[0] = "";
|
let url = "http://dx.doi.org/"+this.publicationInfo.identifiers.get("doi")[0];
|
||||||
this.publicationInfo.downloadFrom.get(url)[1] = this.publicationInfo.publisher+"/ "+this.publicationInfo.journal;
|
|
||||||
|
this.publicationInfo.downloadFrom.get(key)['url'] = new Array<string>();
|
||||||
|
this.publicationInfo.downloadFrom.get(key)['accessMode'] = new Array<string>();
|
||||||
|
|
||||||
|
this.publicationInfo.downloadFrom.get(key)['url'][0] = url;
|
||||||
|
this.publicationInfo.downloadFrom.get(key)['accessMode'][0] = "";
|
||||||
|
|
||||||
|
if(this.publicationInfo.title != undefined && this.publicationInfo.title['url'] == "") {
|
||||||
|
this.publicationInfo.title['url'] = url;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[10] != null) {
|
if(data[10] != null) {
|
||||||
this.publicationInfo.references = /*{};*/new Array<{[key: string]: string}>();
|
this.publicationInfo.references = new Array<{"name": string, "url": string}>();
|
||||||
|
|
||||||
let mydata;
|
let mydata;
|
||||||
let length = data[10].length!=undefined ? data[10].length : 1;
|
let length = data[10].length!=undefined ? data[10].length : 1;
|
||||||
|
@ -308,14 +541,15 @@ export class PublicationService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
this.publicationInfo.references[mydata.position-1] = {};
|
this.publicationInfo.references[mydata.position-1] = { "name": "", "url": ""};
|
||||||
this.publicationInfo.references[mydata.position-1]['text'] = mydata.rawText;
|
this.publicationInfo.references[mydata.position-1]['name'] = mydata.rawText;
|
||||||
this.publicationInfo.references[mydata.position-1]['url'] = url;
|
this.publicationInfo.references[mydata.position-1]['url'] = url;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(data[11] != null) {
|
if(data[11] != null) {
|
||||||
this.publicationInfo.contexts = new Array<{ [key: string]: string }>();
|
this.publicationInfo.contexts = new Array<
|
||||||
|
{ "labelContext": string, "labelCategory": string, "labelConcept": string}>();
|
||||||
|
|
||||||
let position = 0;
|
let position = 0;
|
||||||
let labels = "";
|
let labels = "";
|
||||||
|
@ -324,6 +558,7 @@ export class PublicationService {
|
||||||
for(let i=0; i<length; i++) {
|
for(let i=0; i<length; i++) {
|
||||||
mydata = length > 1 ? data[11][i] : data[11];
|
mydata = length > 1 ? data[11][i] : data[11];
|
||||||
|
|
||||||
|
if(mydata.hasOwnProperty("type") && mydata['type'] == "community") {
|
||||||
if(mydata.hasOwnProperty("category")) {
|
if(mydata.hasOwnProperty("category")) {
|
||||||
if(mydata['category'].hasOwnProperty("concept")) {
|
if(mydata['category'].hasOwnProperty("concept")) {
|
||||||
let mydata1;
|
let mydata1;
|
||||||
|
@ -331,7 +566,7 @@ export class PublicationService {
|
||||||
for(let j=0; j<length1; j++) {
|
for(let j=0; j<length1; j++) {
|
||||||
mydata1 = length1 > 1 ? mydata['category']['concept'][j] : mydata['category']['concept'];
|
mydata1 = length1 > 1 ? mydata['category']['concept'][j] : mydata['category']['concept'];
|
||||||
|
|
||||||
this.publicationInfo.contexts[position] = {};
|
this.publicationInfo.contexts[position] = {"labelContext": "", "labelCategory": "", "labelConcept": ""};
|
||||||
this.publicationInfo.contexts[position]['labelContext'] = mydata.label;
|
this.publicationInfo.contexts[position]['labelContext'] = mydata.label;
|
||||||
this.publicationInfo.contexts[position]['labelCategory'] = mydata['category'].label;;
|
this.publicationInfo.contexts[position]['labelCategory'] = mydata['category'].label;;
|
||||||
this.publicationInfo.contexts[position]['labelConcept'] = mydata1.label;
|
this.publicationInfo.contexts[position]['labelConcept'] = mydata1.label;
|
||||||
|
@ -339,19 +574,20 @@ export class PublicationService {
|
||||||
position++;
|
position++;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.publicationInfo.contexts[position] = {};
|
this.publicationInfo.contexts[position] = {"labelContext": "", "labelCategory": "", "labelConcept": ""};
|
||||||
this.publicationInfo.contexts[position]['labelContext'] = mydata.label;
|
this.publicationInfo.contexts[position]['labelContext'] = mydata.label;
|
||||||
this.publicationInfo.contexts[position]['labelCategory'] = mydata['category'].label;;
|
this.publicationInfo.contexts[position]['labelCategory'] = mydata['category'].label;;
|
||||||
this.publicationInfo.contexts[position]['labelConcept'] = null;
|
this.publicationInfo.contexts[position]['labelConcept'] = null;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
this.publicationInfo.contexts[position] = {};
|
this.publicationInfo.contexts[position] = {"labelContext": "", "labelCategory": "", "labelConcept": ""};
|
||||||
this.publicationInfo.contexts[position]['labelContext'] = mydata.label;
|
this.publicationInfo.contexts[position]['labelContext'] = mydata.label;
|
||||||
this.publicationInfo.contexts[position]['labelCategory'] = null;
|
this.publicationInfo.contexts[position]['labelCategory'] = null;
|
||||||
this.publicationInfo.contexts[position]['labelConcept'] = null;
|
this.publicationInfo.contexts[position]['labelConcept'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//this.printPublicationInfo();
|
//this.printPublicationInfo();
|
||||||
return this.publicationInfo;
|
return this.publicationInfo;
|
||||||
|
@ -375,7 +611,7 @@ export class PublicationService {
|
||||||
console.info("undefined");
|
console.info("undefined");
|
||||||
}
|
}
|
||||||
console.info("\n");
|
console.info("\n");
|
||||||
|
/*
|
||||||
console.info("\nRELATED RESEARCH DATA:");
|
console.info("\nRELATED RESEARCH DATA:");
|
||||||
if(this.publicationInfo.relatedResearchData != undefined) {
|
if(this.publicationInfo.relatedResearchData != undefined) {
|
||||||
this.publicationInfo.relatedResearchData.forEach(function (value, key, map) {
|
this.publicationInfo.relatedResearchData.forEach(function (value, key, map) {
|
||||||
|
@ -395,7 +631,7 @@ export class PublicationService {
|
||||||
console.info("undefined");
|
console.info("undefined");
|
||||||
}
|
}
|
||||||
console.info("\n");
|
console.info("\n");
|
||||||
|
*/
|
||||||
console.info("TYPES: "+this.publicationInfo.types);
|
console.info("TYPES: "+this.publicationInfo.types);
|
||||||
console.info("\nDOWNLOAD FROM:");
|
console.info("\nDOWNLOAD FROM:");
|
||||||
if(this.publicationInfo.downloadFrom != undefined) {
|
if(this.publicationInfo.downloadFrom != undefined) {
|
||||||
|
@ -457,16 +693,6 @@ export class PublicationService {
|
||||||
}
|
}
|
||||||
console.info("\n");
|
console.info("\n");
|
||||||
|
|
||||||
console.info("\nDOWNLOAD FROM:");
|
|
||||||
if(this.publicationInfo.downloadFrom != undefined) {
|
|
||||||
this.publicationInfo.downloadFrom.forEach(function (value, key, map) {
|
|
||||||
console.info(key + " = " + value);
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
console.info("undefined");
|
|
||||||
}
|
|
||||||
console.info("\n");
|
|
||||||
|
|
||||||
console.info("\nREFERENCES:");
|
console.info("\nREFERENCES:");
|
||||||
if(this.publicationInfo.references != undefined) {
|
if(this.publicationInfo.references != undefined) {
|
||||||
for(let i in this.publicationInfo.references) {
|
for(let i in this.publicationInfo.references) {
|
||||||
|
|
Loading…
Reference in New Issue