Publication & Dataset Landing pages: small fix of description lists in basic information | Datatable for dataproviders: small fix in keyword search | Landing pages: loading message for basic information | Open graph tags do not cause any errors in server side (location.path needed sometimes) | Query results in tabs of landing pages only if number of results > 0 | Responsive tabs in all landing pages | Publication landing page: display only tabs with > 0 results (to be done for every landing page)
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-portal/trunk@47677 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
f960fa8970
commit
8791c050d9
|
@ -1,6 +1,7 @@
|
||||||
<div class="uk-container uk-margin-top datasource">
|
<div class="uk-container uk-margin-top datasource">
|
||||||
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
|
<div *ngIf="showLoading" class="uk-alert uk-alert-primary" role="alert">Loading...</div>
|
||||||
|
|
||||||
<div *ngIf="dataProviderInfo != null" uk-grid>
|
<div *ngIf="dataProviderInfo != null" uk-grid>
|
||||||
|
|
||||||
|
@ -42,10 +43,41 @@
|
||||||
[_dataproviderService]="_dataproviderService">
|
[_dataproviderService]="_dataproviderService">
|
||||||
</tabs-->
|
</tabs-->
|
||||||
<div *ngIf="showTabs">
|
<div *ngIf="showTabs">
|
||||||
<ul class="uk-tab" data-uk-switcher="{connect:'#tab-content'}">
|
<ul *ngIf="dataProviderInfo.tabs != undefined" class="uk-tab uk-visible@m" uk-tab="connect: #tab-content">
|
||||||
<li *ngFor="let tab of dataProviderInfo.tabs; let i=index" id="{{dataProviderInfo.tabs[i].content}}">
|
<li *ngFor="let tab of dataProviderInfo.tabs; let i=index" id="{{dataProviderInfo.tabs[i].content}}">
|
||||||
<a
|
<a
|
||||||
(click)="search(tab.content, 1, 10)">
|
(click)="search(tab.content, 1, 10); activeTab=tab.name">
|
||||||
|
{{tab.name}}
|
||||||
|
<i *ngIf="tab.content == 'metricsTab'" class="uk-icon-line-chart"></i>
|
||||||
|
<i *ngIf="tab.content == 'statisticsTab'" class="uk-icon-pie-chart"></i>
|
||||||
|
|
||||||
|
<span class="uk-badge uk-badge-notification" *ngIf="tab.content=='publicationsTab'">
|
||||||
|
{{fetchPublications.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
<span class="uk-badge uk-badge-notification" *ngIf="tab.content=='datasetsTab'">
|
||||||
|
{{fetchDatasets.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
<span class="uk-badge uk-badge-notification" *ngIf="tab.content=='projectsTab'">
|
||||||
|
{{fetchProjects.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
<span class="uk-badge uk-badge-notification" *ngIf="tab.content=='datasourcesTab'">
|
||||||
|
{{fetchDataproviders.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
<span class="uk-badge uk-badge-notification" *ngIf="tab.content=='organizationsTab'">
|
||||||
|
{{dataProviderInfo.organizations.length}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<button class="uk-button uk-button-default uk-hidden@m" type="button">
|
||||||
|
<span uk-navbar-toggle-icon></span> <span class="uk-margin-small-left">{{activeTab}}</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<ul *ngIf="dataProviderInfo.tabs != undefined" id="toggle-small-tabs" class="uk-subnav uk-subnav-pill uk-dropdown uk-hidden@m" uk-switcher="{connect: #tab-content}" uk-dropdown="mode: click" uk-toggle="target: #toggle-small-tabs">
|
||||||
|
<li *ngFor="let tab of dataProviderInfo.tabs; let i=index" id="{{dataProviderInfo.tabs[i].content}}">
|
||||||
|
<a
|
||||||
|
(click)="search(tab.content, 1, 10); activeTab=tab.name">
|
||||||
{{tab.name}}
|
{{tab.name}}
|
||||||
<i *ngIf="tab.content == 'metricsTab'" class="uk-icon-line-chart"></i>
|
<i *ngIf="tab.content == 'metricsTab'" class="uk-icon-line-chart"></i>
|
||||||
<i *ngIf="tab.content == 'statisticsTab'" class="uk-icon-pie-chart"></i>
|
<i *ngIf="tab.content == 'statisticsTab'" class="uk-icon-pie-chart"></i>
|
||||||
|
|
|
@ -37,6 +37,8 @@ export class DataProviderComponent {
|
||||||
|
|
||||||
public warningMessage = "";
|
public warningMessage = "";
|
||||||
public errorMessage = "";
|
public errorMessage = "";
|
||||||
|
public showLoading: boolean = true;
|
||||||
|
|
||||||
public relatedDataprovidersResultsType: string;
|
public relatedDataprovidersResultsType: string;
|
||||||
public paramsForSearchLink = {};//: string = "";
|
public paramsForSearchLink = {};//: string = "";
|
||||||
|
|
||||||
|
@ -52,6 +54,7 @@ export class DataProviderComponent {
|
||||||
private totalDownloads: number;
|
private totalDownloads: number;
|
||||||
private pageViews: number;
|
private pageViews: number;
|
||||||
|
|
||||||
|
private activeTab: string = "";
|
||||||
public statsClicked: boolean = false;
|
public statsClicked: boolean = false;
|
||||||
private docsTimelineUrl: string;
|
private docsTimelineUrl: string;
|
||||||
private docsTypesUrl:string;
|
private docsTypesUrl:string;
|
||||||
|
@ -113,6 +116,8 @@ export class DataProviderComponent {
|
||||||
getDataProviderInfo(id:string) {
|
getDataProviderInfo(id:string) {
|
||||||
this.warningMessage = '';
|
this.warningMessage = '';
|
||||||
this.errorMessage=""
|
this.errorMessage=""
|
||||||
|
this.showLoading = true;
|
||||||
|
|
||||||
this.showTabs = false ;
|
this.showTabs = false ;
|
||||||
if(this.datasourceId==null || this.datasourceId==''){
|
if(this.datasourceId==null || this.datasourceId==''){
|
||||||
this.warningMessage="No valid datasource id";
|
this.warningMessage="No valid datasource id";
|
||||||
|
@ -124,11 +129,18 @@ export class DataProviderComponent {
|
||||||
this.showTabs = true ;
|
this.showTabs = true ;
|
||||||
this.updateTitle(this.dataProviderInfo.title.name);
|
this.updateTitle(this.dataProviderInfo.title.name);
|
||||||
this.updateDescription("Data provider, search, repositories, open access,"+this.dataProviderInfo.title.name);
|
this.updateDescription("Data provider, search, repositories, open access,"+this.dataProviderInfo.title.name);
|
||||||
|
|
||||||
|
this.showLoading = false;
|
||||||
|
|
||||||
|
if(this.dataProviderInfo.tabs != undefined && this.dataProviderInfo.tabs.length > 0) {
|
||||||
|
this.activeTab = this.dataProviderInfo.tabs[0].name;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
err => {
|
err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
// console.info("error");
|
// console.info("error");
|
||||||
this.errorMessage = 'No dataProvider found';
|
this.errorMessage = 'No dataProvider found';
|
||||||
|
this.showLoading = false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -243,6 +255,9 @@ export class DataProviderComponent {
|
||||||
|
|
||||||
private countPublications(page: number, size: number) {
|
private countPublications(page: number, size: number) {
|
||||||
this.fetchPublications.getResultsForDataproviders(this.datasourceId, this.dataProviderInfo.resultsBy, page, size);
|
this.fetchPublications.getResultsForDataproviders(this.datasourceId, this.dataProviderInfo.resultsBy, page, size);
|
||||||
|
if(this.fetchPublications.searchUtils.totalResults == 0) {
|
||||||
|
this.reloadPublications = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchDatasets(page: number, size: number) {
|
private searchDatasets(page: number, size: number) {
|
||||||
|
@ -254,6 +269,9 @@ export class DataProviderComponent {
|
||||||
|
|
||||||
private countDatasets(page: number, size: number) {
|
private countDatasets(page: number, size: number) {
|
||||||
this.fetchDatasets.getResultsForDataproviders(this.datasourceId, this.dataProviderInfo.resultsBy, page, size);
|
this.fetchDatasets.getResultsForDataproviders(this.datasourceId, this.dataProviderInfo.resultsBy, page, size);
|
||||||
|
if(this.fetchDatasets.searchUtils.totalResults == 0) {
|
||||||
|
this.reloadDatasets = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchProjects(page: number, size: number) {
|
private searchProjects(page: number, size: number) {
|
||||||
|
@ -265,6 +283,9 @@ export class DataProviderComponent {
|
||||||
|
|
||||||
private countProjects(page: number, size: number) {
|
private countProjects(page: number, size: number) {
|
||||||
this.fetchProjects.getResultsForDataproviders(this.datasourceId, page, size);
|
this.fetchProjects.getResultsForDataproviders(this.datasourceId, page, size);
|
||||||
|
if(this.fetchProjects.searchUtils.totalResults == 0) {
|
||||||
|
this.reloadProjects = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchDatasources(page: number, size: number) {
|
private searchDatasources(page: number, size: number) {
|
||||||
|
@ -278,6 +299,9 @@ export class DataProviderComponent {
|
||||||
|
|
||||||
private countDatasources(page: number, size: number) {
|
private countDatasources(page: number, size: number) {
|
||||||
this.fetchDataproviders.getResultsForDataproviders(this.datasourceId, page, size);
|
this.fetchDataproviders.getResultsForDataproviders(this.datasourceId, page, size);
|
||||||
|
if(this.fetchDataproviders.searchUtils.totalResults == 0) {
|
||||||
|
this.reloadDataproviders = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchRelatedDatasources(page: number, size: number) {
|
private searchRelatedDatasources(page: number, size: number) {
|
||||||
|
@ -289,6 +313,9 @@ export class DataProviderComponent {
|
||||||
|
|
||||||
private countRelatedDatasources(page: number, size: number) {
|
private countRelatedDatasources(page: number, size: number) {
|
||||||
this.fetchResultsAggregators.getAggregatorResults(this.datasourceId, page, size);
|
this.fetchResultsAggregators.getAggregatorResults(this.datasourceId, page, size);
|
||||||
|
if(this.fetchResultsAggregators.searchUtils.totalResults == 0) {
|
||||||
|
this.reloadRelatedDatasources = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public metricsResults($event) {
|
public metricsResults($event) {
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
|
|
||||||
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
|
<div *ngIf="showLoading" class="uk-alert uk-alert-primary" role="alert">Loading...</div>
|
||||||
|
|
||||||
<div *ngIf="datasetInfo != null" uk-grid>
|
<div *ngIf="datasetInfo != null" uk-grid>
|
||||||
<div class="uk-width-3-4@l uk-width-3-4@xl uk-width-3-4@m uk-width-1-1@s">
|
<div class="uk-width-3-4@l uk-width-3-4@xl uk-width-3-4@m uk-width-1-1@s">
|
||||||
|
@ -33,13 +34,13 @@
|
||||||
<dd *ngIf="datasetInfo.type != undefined">{{datasetInfo.type}}</dd>
|
<dd *ngIf="datasetInfo.type != undefined">{{datasetInfo.type}}</dd>
|
||||||
<dt *ngIf="datasetInfo.embargoEndDate">Embargo end date: </dt>
|
<dt *ngIf="datasetInfo.embargoEndDate">Embargo end date: </dt>
|
||||||
<dd *ngIf="datasetInfo.embargoEndDate">{{datasetInfo.embargoEndDate}}</dd>
|
<dd *ngIf="datasetInfo.embargoEndDate">{{datasetInfo.embargoEndDate}}</dd>
|
||||||
|
|
||||||
<showIdentifiers [identifiers]="datasetInfo.identifiers"></showIdentifiers>
|
|
||||||
<showSubjects [subjects]="datasetInfo.subjects"
|
|
||||||
[otherSubjects]="datasetInfo.otherSubjects"
|
|
||||||
[classifiedSubjects]="datasetInfo.classifiedSubjects">
|
|
||||||
</showSubjects>
|
|
||||||
</dl>
|
</dl>
|
||||||
|
<showIdentifiers [identifiers]="datasetInfo.identifiers"></showIdentifiers>
|
||||||
|
<showSubjects [subjects]="datasetInfo.subjects"
|
||||||
|
[otherSubjects]="datasetInfo.otherSubjects"
|
||||||
|
[classifiedSubjects]="datasetInfo.classifiedSubjects">
|
||||||
|
</showSubjects>
|
||||||
|
|
||||||
|
|
||||||
<blockquote *ngIf="datasetInfo.description != ''">
|
<blockquote *ngIf="datasetInfo.description != ''">
|
||||||
<div class="uk-text-justify">{{datasetInfo.description}}</div>
|
<div class="uk-text-justify">{{datasetInfo.description}}</div>
|
||||||
|
@ -49,8 +50,9 @@
|
||||||
|
|
||||||
<a class="uk-float-right uk-button uk-button-default" [queryParams]="routerHelper.createQueryParams(['id','type','linkTo'],[datasetId,'publication','result'])" routerLinkActive="router-link-active" routerLink="/participate/direct-claim" > <span uk-icon="icon: link"></span> Links to research Results</a>
|
<a class="uk-float-right uk-button uk-button-default" [queryParams]="routerHelper.createQueryParams(['id','type','linkTo'],[datasetId,'publication','result'])" routerLinkActive="router-link-active" routerLink="/participate/direct-claim" > <span uk-icon="icon: link"></span> Links to research Results</a>
|
||||||
</div>
|
</div>
|
||||||
<ul class="uk-tab" data-uk-switcher="{connect:'#tab-content'}">
|
|
||||||
<li class="uk-active">
|
<ul class="uk-tab uk-visible@m" uk-tab="connect: #tab-content">
|
||||||
|
<li (click)="activeTab='Related Research Results'">
|
||||||
<a>
|
<a>
|
||||||
Related Research Results
|
Related Research Results
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -59,7 +61,7 @@
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
<li (click)="activeTab='Similar Research Results'">
|
||||||
<a>
|
<a>
|
||||||
Similar Research Results
|
Similar Research Results
|
||||||
<span *ngIf="!datasetInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!datasetInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -69,7 +71,38 @@
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li (click)="metricsClicked=true">
|
<li (click)="metricsClicked=true; activeTab='Metrics'">
|
||||||
|
<a>
|
||||||
|
Metrics
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<button class="uk-button uk-button-default uk-hidden@m" type="button">
|
||||||
|
<span uk-navbar-toggle-icon></span> <span class="uk-margin-small-left">{{activeTab}}</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<ul id="toggle-small-tabs" class="uk-subnav uk-subnav-pill uk-dropdown uk-hidden@m" uk-switcher="{connect: #tab-content}" uk-dropdown="mode: click" uk-toggle="target: #toggle-small-tabs">
|
||||||
|
<li (click)="activeTab='Related Research Results'">
|
||||||
|
<a>
|
||||||
|
Related Research Results
|
||||||
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
{{relatedResearchResultsNum}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li (click)="activeTab='Similar Research Results'">
|
||||||
|
<a>
|
||||||
|
Similar Research Results
|
||||||
|
<span *ngIf="!datasetInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
<span *ngIf="datasetInfo.similarResearchResults" class="uk-badge uk-badge-notification">
|
||||||
|
{{datasetInfo.similarResearchResults.length}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li (click)="metricsClicked=true; activeTab='Metrics'">
|
||||||
<a>
|
<a>
|
||||||
Metrics
|
Metrics
|
||||||
</a>
|
</a>
|
||||||
|
|
|
@ -27,6 +27,8 @@ export class DatasetComponent {
|
||||||
private datasetId : string ;
|
private datasetId : string ;
|
||||||
private result ;
|
private result ;
|
||||||
sub: any;
|
sub: any;
|
||||||
|
|
||||||
|
private activeTab: string = "Related Research Results";
|
||||||
private metricsClicked: boolean;
|
private metricsClicked: boolean;
|
||||||
private viewsFrameUrl: string;
|
private viewsFrameUrl: string;
|
||||||
private downloadsFrameUrl: string;
|
private downloadsFrameUrl: string;
|
||||||
|
@ -38,6 +40,8 @@ export class DatasetComponent {
|
||||||
|
|
||||||
public warningMessage = "";
|
public warningMessage = "";
|
||||||
public errorMessage = "";
|
public errorMessage = "";
|
||||||
|
public showLoading: boolean = true;
|
||||||
|
|
||||||
public routerHelper:RouterHelper = new RouterHelper();
|
public routerHelper:RouterHelper = new RouterHelper();
|
||||||
|
|
||||||
constructor (private element: ElementRef,
|
constructor (private element: ElementRef,
|
||||||
|
@ -86,6 +90,7 @@ export class DatasetComponent {
|
||||||
getDatasetInfo(id:string) {
|
getDatasetInfo(id:string) {
|
||||||
this.warningMessage = '';
|
this.warningMessage = '';
|
||||||
this.errorMessage=""
|
this.errorMessage=""
|
||||||
|
this.showLoading = true;
|
||||||
|
|
||||||
this._datasetService.getDatasetInfo(id).subscribe(
|
this._datasetService.getDatasetInfo(id).subscribe(
|
||||||
data => {
|
data => {
|
||||||
|
@ -102,12 +107,15 @@ export class DatasetComponent {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
this.relatedResearchResultsNum = relatedResearchResultsNum;
|
this.relatedResearchResultsNum = relatedResearchResultsNum;
|
||||||
|
|
||||||
|
this.showLoading = false;
|
||||||
},
|
},
|
||||||
err => {
|
err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
console.info("error");
|
console.info("error");
|
||||||
|
|
||||||
this.errorMessage = 'No dataset found';
|
this.errorMessage = 'No dataset found';
|
||||||
|
this.showLoading = false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<div class="uk-container uk-margin-top organization">
|
<div class="uk-container uk-margin-top organization">
|
||||||
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
|
<div *ngIf="showLoading" class="uk-alert uk-alert-primary" role="alert">Loading...</div>
|
||||||
|
|
||||||
<!--div class="container-header" >
|
<!--div class="container-header" >
|
||||||
<div *ngIf="organizationInfo != null">
|
<div *ngIf="organizationInfo != null">
|
||||||
|
@ -30,8 +31,8 @@
|
||||||
<dd *ngIf="organizationInfo.country">{{organizationInfo.country}}</dd>
|
<dd *ngIf="organizationInfo.country">{{organizationInfo.country}}</dd>
|
||||||
</dl>
|
</dl>
|
||||||
|
|
||||||
<ul class="uk-tab" data-uk-switcher="{connect:'#tab-content'}">
|
<ul class="uk-tab uk-visible@m" uk-tab="connect: #tab-content">
|
||||||
<li class="uk-active">
|
<li (click)="activeTab='Publications'">
|
||||||
<a>
|
<a>
|
||||||
Publications
|
Publications
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -39,7 +40,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="projectsClicked=true;">
|
<li (click)="activeTab='Projects'; projectsClicked=true;">
|
||||||
<a>
|
<a>
|
||||||
Projects
|
Projects
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -48,7 +49,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="searchDataprovidersInit()">
|
<li (click)="activeTab='Data Providers'; searchDataprovidersInit()">
|
||||||
<a>
|
<a>
|
||||||
Data Providers
|
Data Providers
|
||||||
<!--span *ngIf="organizationInfo.dataProviders == undefined" class="badge">0</span>
|
<!--span *ngIf="organizationInfo.dataProviders == undefined" class="badge">0</span>
|
||||||
|
@ -60,13 +61,45 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<!--li (click)="getMetrics()">
|
|
||||||
<a href="#metricsTab">
|
|
||||||
Metrics
|
|
||||||
</a>
|
|
||||||
</li-->
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<button class="uk-button uk-button-default uk-hidden@m" type="button">
|
||||||
|
<span uk-navbar-toggle-icon></span> <span class="uk-margin-small-left">{{activeTab}}</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<ul id="toggle-small-tabs" class="uk-subnav uk-subnav-pill uk-dropdown uk-hidden@m" uk-switcher="{connect: #tab-content}" uk-dropdown="mode: click" uk-toggle="target: #toggle-small-tabs">
|
||||||
|
<li (click)="activeTab='Publications'">
|
||||||
|
<a>
|
||||||
|
Publications
|
||||||
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
{{fetchPublications.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li (click)="activeTab='Projects'; projectsClicked=true;">
|
||||||
|
<a>
|
||||||
|
Projects
|
||||||
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
<!--{{(searchingProjectsTabComponent)?searchingProjectsTabComponent.fetchProjects.totalResults:0}}-->
|
||||||
|
{{fetchProjects.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li (click)="activeTab='Data Providers'; searchDataprovidersInit()">
|
||||||
|
<a>
|
||||||
|
Data Providers
|
||||||
|
<!--span *ngIf="organizationInfo.dataProviders == undefined" class="badge">0</span>
|
||||||
|
<span *ngIf="organizationInfo.dataProviders != undefined" class="badge">
|
||||||
|
{{organizationInfo.dataProviders.length}}
|
||||||
|
</span-->
|
||||||
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
{{fetchDataproviders.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
|
||||||
<ul id="tab-content" class="uk-switcher uk-margin custom-tab-content">
|
<ul id="tab-content" class="uk-switcher uk-margin custom-tab-content">
|
||||||
<li class="uk-animation-fade">
|
<li class="uk-animation-fade">
|
||||||
<div *ngIf="fetchPublications.searchUtils.status == errorCodes.NONE" class="uk-alert uk-alert-primary uk-animation-fade" role="alert">There are no publications</div>
|
<div *ngIf="fetchPublications.searchUtils.status == errorCodes.NONE" class="uk-alert uk-alert-primary uk-animation-fade" role="alert">There are no publications</div>
|
||||||
|
@ -119,14 +152,6 @@
|
||||||
</tab-result>
|
</tab-result>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
<!--li id="metricsTab">
|
|
||||||
<div *ngIf="metrics == undefined" class = "uk-alert uk-alert-warning">
|
|
||||||
Metrics are currently unavailable
|
|
||||||
</div>
|
|
||||||
<div *ngIf="metrics != undefined" class="uk-panel uk-padding uk-background-muted">
|
|
||||||
<b>Views: </b>{{metrics}}
|
|
||||||
</div>
|
|
||||||
</li-->
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -34,6 +34,7 @@ export class OrganizationComponent {
|
||||||
private emptyFundersSet: boolean = true;
|
private emptyFundersSet: boolean = true;
|
||||||
public warningMessage = "";
|
public warningMessage = "";
|
||||||
public errorMessage = "";
|
public errorMessage = "";
|
||||||
|
public showLoading: boolean = true;
|
||||||
|
|
||||||
public downloadURLAPI: string;
|
public downloadURLAPI: string;
|
||||||
public csvProjectParamsHead: string;
|
public csvProjectParamsHead: string;
|
||||||
|
@ -41,9 +42,9 @@ export class OrganizationComponent {
|
||||||
public csvParamsTail: string;
|
public csvParamsTail: string;
|
||||||
|
|
||||||
sub: any;
|
sub: any;
|
||||||
subDataproviders: any;
|
|
||||||
subDataprovidersCount: any;
|
|
||||||
|
|
||||||
|
public activeTab: string = "Publications";
|
||||||
|
public reloadDataproviders: boolean = true;
|
||||||
public projectsClicked: boolean = false;
|
public projectsClicked: boolean = false;
|
||||||
|
|
||||||
public fetchPublications: FetchPublications;
|
public fetchPublications: FetchPublications;
|
||||||
|
@ -108,34 +109,18 @@ export class OrganizationComponent {
|
||||||
this.downloadURLAPI = OpenaireProperties.getCsvAPIURL();
|
this.downloadURLAPI = OpenaireProperties.getCsvAPIURL();
|
||||||
this.csvProjectParamsHead = 'format=csv&type=projects&page=0&query=( (oaftype exact project)and (funderid exact "';
|
this.csvProjectParamsHead = 'format=csv&type=projects&page=0&query=( (oaftype exact project)and (funderid exact "';
|
||||||
//this.csvPublicationParamsHead = 'format=csv-special&type=publications&page=0&query=((((oaftype exact result) and (resulttypeid exact publication)) and (funderid exact ';
|
//this.csvPublicationParamsHead = 'format=csv-special&type=publications&page=0&query=((((oaftype exact result) and (resulttypeid exact publication)) and (funderid exact ';
|
||||||
/*
|
|
||||||
this.subDataprovidersCount = this.route.queryParams.subscribe(params => {
|
|
||||||
this._searchDataprovidersService.numOfDataproviders("organizations/"+this.organizationId+"/datasources/count").subscribe(
|
|
||||||
data => {
|
|
||||||
this.fetchDataproviders.searchUtils.totalResults = data;
|
|
||||||
console.info("this.fetchDataproviders.searchUtils.totalResults = "+this.fetchDataproviders.searchUtils.totalResults);
|
|
||||||
},
|
|
||||||
err => {
|
|
||||||
console.log(err);
|
|
||||||
}
|
|
||||||
);
|
|
||||||
})
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
ngOnDestroy() {
|
ngOnDestroy() {
|
||||||
this.sub.unsubscribe();
|
this.sub.unsubscribe();
|
||||||
if(this.subDataproviders != undefined) {
|
|
||||||
this.subDataproviders.unsubscribe();
|
|
||||||
}
|
|
||||||
//this.subDataprovidersCount.unsubscribe();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private getOrganizationInfo () {
|
private getOrganizationInfo () {
|
||||||
|
|
||||||
this.warningMessage = '';
|
this.warningMessage = '';
|
||||||
this.errorMessage=""
|
this.errorMessage=""
|
||||||
|
this.showLoading = true;
|
||||||
|
|
||||||
this._organizationService.getOrganizationInfo(this.organizationId).subscribe(
|
this._organizationService.getOrganizationInfo(this.organizationId).subscribe(
|
||||||
data => {
|
data => {
|
||||||
|
@ -146,13 +131,21 @@ export class OrganizationComponent {
|
||||||
this.updateTitle(this.organizationInfo.title.name);
|
this.updateTitle(this.organizationInfo.title.name);
|
||||||
this.updateDescription("Organization, country, projects, search, repositories, open access"+this.organizationInfo.title.name);
|
this.updateDescription("Organization, country, projects, search, repositories, open access"+this.organizationInfo.title.name);
|
||||||
|
|
||||||
this.fetchPublications.getResultsForEntity("organization", this.organizationId, 1, 10);
|
|
||||||
this.linkToSearchPublications = OpenaireProperties.getLinkToAdvancedSearchPublications();
|
|
||||||
//this.fetchProjects.getNumForEntity("organization", this.organizationId);
|
|
||||||
var refineFields:string [] = ["funderid"];
|
var refineFields:string [] = ["funderid"];
|
||||||
|
|
||||||
|
this.searchPublications();
|
||||||
|
//this.fetchProjects.getNumForEntity("organization", this.organizationId);
|
||||||
this.fetchProjects.getResultsForOrganizations(this.organizationId, "", 1, 0,refineFields);
|
this.fetchProjects.getResultsForOrganizations(this.organizationId, "", 1, 0,refineFields);
|
||||||
|
if(this.fetchProjects.searchUtils.totalResults > 0) {
|
||||||
|
//this.activeTab = "Projects";
|
||||||
|
} else {
|
||||||
|
//this.searchDataprovidersInit();
|
||||||
|
}
|
||||||
|
|
||||||
this.fetchDataproviders.getNumForEntity("organization", this.organizationId);
|
this.fetchDataproviders.getNumForEntity("organization", this.organizationId);
|
||||||
|
|
||||||
|
this.showLoading = false;
|
||||||
|
|
||||||
/*let projectsNum = 0;
|
/*let projectsNum = 0;
|
||||||
|
|
||||||
if(this.organizationInfo.projects != undefined) {
|
if(this.organizationInfo.projects != undefined) {
|
||||||
|
@ -170,6 +163,7 @@ export class OrganizationComponent {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
|
|
||||||
this.errorMessage = 'No organization found';
|
this.errorMessage = 'No organization found';
|
||||||
|
this.showLoading = false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -212,16 +206,31 @@ export class OrganizationComponent {
|
||||||
//return this.projectsData;
|
//return this.projectsData;
|
||||||
//}
|
//}
|
||||||
|
|
||||||
|
private searchPublications() {
|
||||||
|
this.fetchPublications.getResultsForEntity("organization", this.organizationId, 1, 10);
|
||||||
|
this.linkToSearchPublications = OpenaireProperties.getLinkToAdvancedSearchPublications();// + "?project=" + this.projectId+"&pr=and";
|
||||||
|
if(this.fetchPublications.searchUtils.totalResults > 0) {
|
||||||
|
//this.activeTab = "Publications";
|
||||||
|
} else {
|
||||||
|
//this.projectsClicked = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private searchDataproviders() {
|
private searchDataproviders() {
|
||||||
this.fetchDataproviders.getResultsForEntity("organization", this.organizationId, 1, 10);
|
this.fetchDataproviders.getResultsForEntity("organization", this.organizationId, 1, 10);
|
||||||
this.linkToSearchDataproviders = OpenaireProperties.getLinkToAdvancedSearchDataProviders();
|
this.linkToSearchDataproviders = OpenaireProperties.getLinkToAdvancedSearchDataProviders();
|
||||||
|
|
||||||
|
if(this.fetchDataproviders.searchUtils.totalResults > 0) {
|
||||||
|
this.reloadDataproviders = false;
|
||||||
|
//this.activeTab = "Data Providers";
|
||||||
|
} else {
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchDataprovidersInit() {
|
private searchDataprovidersInit() {
|
||||||
if(this.subDataproviders == undefined && this.fetchDataproviders.searchUtils.totalResults > 0) {
|
if(this.reloadDataproviders && this.fetchDataproviders.searchUtils.totalResults > 0) {
|
||||||
this.subDataproviders = this.route.queryParams.subscribe(params => {
|
this.searchDataproviders();
|
||||||
this.searchDataproviders();
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<div class="uk-container uk-margin-top project">
|
<div class="uk-container uk-margin-top project">
|
||||||
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
|
<div *ngIf="showLoading" class="uk-alert uk-alert-primary" role="alert">Loading...</div>
|
||||||
|
|
||||||
<div *ngIf="projectInfo != null" uk-grid>
|
<div *ngIf="projectInfo != null" uk-grid>
|
||||||
<div class="uk-width-3-4@l uk-width-3-4@xl uk-width-3-4@m uk-width-1-1@s">
|
<div class="uk-width-3-4@l uk-width-3-4@xl uk-width-3-4@m uk-width-1-1@s">
|
||||||
|
@ -55,9 +56,8 @@
|
||||||
</dd>
|
</dd>
|
||||||
</dl>
|
</dl>
|
||||||
|
|
||||||
|
<ul class="uk-tab uk-visible@m" uk-tab="connect: #tab-content">
|
||||||
<ul class="uk-tab" data-uk-switcher="{connect:'#tab-content'}">
|
<li (click)="activeTab='Publications'">
|
||||||
<li class="uk-active">
|
|
||||||
<a>
|
<a>
|
||||||
Publications
|
Publications
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -65,7 +65,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="searchDatasetsInit()">
|
<li (click)="activeTab='Research Data'; searchDatasetsInit()">
|
||||||
<a>
|
<a>
|
||||||
Research Data
|
Research Data
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -73,13 +73,13 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="statsClicked=true;">
|
<li (click)="activeTab='Statistics'; statsClicked=true">
|
||||||
<a>
|
<a>
|
||||||
Statistics
|
Statistics
|
||||||
<i class="uk-icon-pie-chart"></i>
|
<i class="uk-icon-pie-chart"></i>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="metricsClicked=true;">
|
<li (click)="activeTab='Metrics'; metricsClicked=true">
|
||||||
<a>
|
<a>
|
||||||
Metrics
|
Metrics
|
||||||
<i class="uk-icon-line-chart"></i>
|
<i class="uk-icon-line-chart"></i>
|
||||||
|
@ -87,6 +87,41 @@
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<button class="uk-button uk-button-default uk-hidden@m" type="button">
|
||||||
|
<span uk-navbar-toggle-icon></span> <span class="uk-margin-small-left">{{activeTab}}</span>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
<ul id="toggle-small-tabs" class="uk-subnav uk-subnav-pill uk-dropdown uk-hidden@m" uk-switcher="{connect: #tab-content}" uk-dropdown="mode: click" uk-toggle="target: #toggle-small-tabs">
|
||||||
|
<li (click)="activeTab='Publications'">
|
||||||
|
<a>
|
||||||
|
Publications
|
||||||
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
{{fetchPublications.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li (click)="searchDatasetsInit(); activeTab='Research Data'">
|
||||||
|
<a>
|
||||||
|
Research Data
|
||||||
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
{{fetchDatasets.searchUtils.totalResults}}
|
||||||
|
</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li (click)="statsClicked=true; activeTab='Statistics'">
|
||||||
|
<a>
|
||||||
|
Statistics
|
||||||
|
<i class="uk-icon-pie-chart"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li (click)="metricsClicked=true; activeTab='Metrics'">
|
||||||
|
<a>
|
||||||
|
Metrics
|
||||||
|
<i class="uk-icon-line-chart"></i>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
<ul id="tab-content" class="uk-switcher uk-margin custom-tab-content">
|
<ul id="tab-content" class="uk-switcher uk-margin custom-tab-content">
|
||||||
<li class="uk-animation-fade">
|
<li class="uk-animation-fade">
|
||||||
<!--div *ngIf="fetchPublications.searchUtils.totalResults == 0" class = "uk-alert uk-alert-primary" >
|
<!--div *ngIf="fetchPublications.searchUtils.totalResults == 0" class = "uk-alert uk-alert-primary" >
|
||||||
|
|
|
@ -48,11 +48,12 @@ export class ProjectComponent{
|
||||||
|
|
||||||
public warningMessage = "";
|
public warningMessage = "";
|
||||||
public errorMessage = "";
|
public errorMessage = "";
|
||||||
|
public showLoading: boolean = true;
|
||||||
|
|
||||||
sub: any;
|
sub: any;
|
||||||
subPublications: any;
|
|
||||||
subDatasets: any;
|
public activeTab: string = "Publications";
|
||||||
subDatasetsCount: any;
|
public reloadDatasets: boolean = true;
|
||||||
|
|
||||||
public fetchPublications : FetchPublications;
|
public fetchPublications : FetchPublications;
|
||||||
public linkToSearchPublications = "";
|
public linkToSearchPublications = "";
|
||||||
|
@ -107,20 +108,8 @@ export class ProjectComponent{
|
||||||
+ "\n</script>";
|
+ "\n</script>";
|
||||||
|
|
||||||
this.getProjectInfo(this.projectId);
|
this.getProjectInfo(this.projectId);
|
||||||
// this.subPublications = this.route.queryParams.subscribe(params => {
|
|
||||||
this.searchPublications();
|
this.searchPublications();
|
||||||
// });
|
|
||||||
|
|
||||||
//this.subDatasetsCount = this._searchDatasetsService.numOfEntityDatasets(this.projectId, "projects/").subscribe(
|
|
||||||
// data => {
|
|
||||||
// this.fetchDatasets.searchUtils.totalResults = data;
|
|
||||||
// },
|
|
||||||
// err => {
|
|
||||||
// console.log(err);
|
|
||||||
// }
|
|
||||||
//);
|
|
||||||
this.fetchDatasets.getNumForEntity("project", this.projectId);
|
this.fetchDatasets.getNumForEntity("project", this.projectId);
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
this.warningMessage="No valid project id";
|
this.warningMessage="No valid project id";
|
||||||
}
|
}
|
||||||
|
@ -140,7 +129,6 @@ export class ProjectComponent{
|
||||||
|
|
||||||
ngOnDestroy() {
|
ngOnDestroy() {
|
||||||
this.sub.unsubscribe();
|
this.sub.unsubscribe();
|
||||||
//this.subDatasetsCount.unsubscribe();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
createClipboard() {
|
createClipboard() {
|
||||||
|
@ -157,22 +145,36 @@ export class ProjectComponent{
|
||||||
private searchPublications() {
|
private searchPublications() {
|
||||||
this.fetchPublications.getResultsForEntity("project", this.projectId, 1, 10);
|
this.fetchPublications.getResultsForEntity("project", this.projectId, 1, 10);
|
||||||
this.linkToSearchPublications = OpenaireProperties.getLinkToAdvancedSearchPublications();// + "?project=" + this.projectId+"&pr=and";
|
this.linkToSearchPublications = OpenaireProperties.getLinkToAdvancedSearchPublications();// + "?project=" + this.projectId+"&pr=and";
|
||||||
|
if(this.fetchPublications.searchUtils.totalResults > 0) {
|
||||||
|
//this.activeTab = "Publications";
|
||||||
|
} else {
|
||||||
|
//this.searchDatasetsInit();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchDatasets() {
|
private searchDatasets() {
|
||||||
this.fetchDatasets.getResultsForEntity("project", this.projectId, 1, 10);
|
this.fetchDatasets.getResultsForEntity("project", this.projectId, 1, 10);
|
||||||
this.linkToSearchDatasets = OpenaireProperties.getLinkToAdvancedSearchDatasets();// + "?project=" + this.projectId+"&pr=and";
|
this.linkToSearchDatasets = OpenaireProperties.getLinkToAdvancedSearchDatasets();// + "?project=" + this.projectId+"&pr=and";
|
||||||
|
|
||||||
|
this.reloadDatasets = false;
|
||||||
|
//this.activeTab = "Research Data";
|
||||||
}
|
}
|
||||||
|
|
||||||
private searchDatasetsInit() {
|
private searchDatasetsInit() {
|
||||||
if(this.subDatasets == undefined && this.fetchDatasets.searchUtils.totalResults > 0) {
|
console.info("searchDatasetsInit");
|
||||||
|
if(this.reloadDatasets && this.fetchDatasets.searchUtils.totalResults > 0) {
|
||||||
this.searchDatasets();
|
this.searchDatasets();
|
||||||
|
} else if(this.fetchDatasets.searchUtils.totalResults == 0) {
|
||||||
|
//this.statsClicked=true;
|
||||||
|
//this.activeTab = "Statistics";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
getProjectInfo (id:string) {
|
getProjectInfo (id:string) {
|
||||||
this.warningMessage = '';
|
this.warningMessage = '';
|
||||||
this.errorMessage=""
|
this.errorMessage=""
|
||||||
|
this.showLoading = true;
|
||||||
|
|
||||||
this._projectService.getProjectInfo(id).subscribe(
|
this._projectService.getProjectInfo(id).subscribe(
|
||||||
data => {
|
data => {
|
||||||
this.projectInfo = data;
|
this.projectInfo = data;
|
||||||
|
@ -198,10 +200,13 @@ console.info(this.projectInfo.title);
|
||||||
this.chartScientificResultsUrl='https://beta.openaire.eu/stats/chart.php?com=query&persistent=false&data={"query":"projScient","projTitle":"'+this.projectId+'", "table": "result", "fields": [{"fld": "number", "agg": "count", "type": "spline", "yaxis":1, "c":false}], "xaxis":{"name": "result_classifications-type", "agg": "avg"}, "group": "", "color": "", "type": "chart", "size":30, "sort": "xaxis", "xStyle":{"r": "-", "s": "-", "l": "-", "ft": "-", "wt": "-"}, "yaxisheaders": [""], "fieldsheaders": ["Publications"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=600&h=250';
|
this.chartScientificResultsUrl='https://beta.openaire.eu/stats/chart.php?com=query&persistent=false&data={"query":"projScient","projTitle":"'+this.projectId+'", "table": "result", "fields": [{"fld": "number", "agg": "count", "type": "spline", "yaxis":1, "c":false}], "xaxis":{"name": "result_classifications-type", "agg": "avg"}, "group": "", "color": "", "type": "chart", "size":30, "sort": "xaxis", "xStyle":{"r": "-", "s": "-", "l": "-", "ft": "-", "wt": "-"}, "yaxisheaders": [""], "fieldsheaders": ["Publications"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=600&h=250';
|
||||||
this.chartAccessModeUrl='https://beta.openaire.eu/stats/chart.php?com=query&persistent=false&data={"query":"projOA","projTitle":"'+this.projectId+'", "table": "result", "fields": [{"fld": "number", "agg": "count", "type": "pie", "yaxis":1, "c":false}], "xaxis":{"name": "result_classifications-type", "agg": "avg"}, "group": "", "color": "", "type": "chart", "size":30, "sort": "xaxis", "xStyle":{"r": "-", "s": "-", "l": "-", "ft": "-", "wt": "-"}, "yaxisheaders": [""], "fieldsheaders": ["Publications"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=600&h=250';
|
this.chartAccessModeUrl='https://beta.openaire.eu/stats/chart.php?com=query&persistent=false&data={"query":"projOA","projTitle":"'+this.projectId+'", "table": "result", "fields": [{"fld": "number", "agg": "count", "type": "pie", "yaxis":1, "c":false}], "xaxis":{"name": "result_classifications-type", "agg": "avg"}, "group": "", "color": "", "type": "chart", "size":30, "sort": "xaxis", "xStyle":{"r": "-", "s": "-", "l": "-", "ft": "-", "wt": "-"}, "yaxisheaders": [""], "fieldsheaders": ["Publications"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=600&h=250';
|
||||||
this.chartDatasourcesUrl= 'https://beta.openaire.eu/stats/chart.php?com=query&persistent=false&data={"query":"projPubsRepos","projTitle":"'+this.projectId+'", "table": "result", "fields": [{"fld": "number", "agg": "count", "type": "column", "yaxis":1, "c":false}], "xaxis":{"name": "result_classifications-type", "agg": "avg"}, "group": "", "color": "", "type": "chart", "size":30, "sort": "xaxis", "xStyle":{"r": "-", "s": "-", "l": "-", "ft": "-", "wt": "-"}, "yaxisheaders": [""], "fieldsheaders": ["Publications"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=600&h=250';
|
this.chartDatasourcesUrl= 'https://beta.openaire.eu/stats/chart.php?com=query&persistent=false&data={"query":"projPubsRepos","projTitle":"'+this.projectId+'", "table": "result", "fields": [{"fld": "number", "agg": "count", "type": "column", "yaxis":1, "c":false}], "xaxis":{"name": "result_classifications-type", "agg": "avg"}, "group": "", "color": "", "type": "chart", "size":30, "sort": "xaxis", "xStyle":{"r": "-", "s": "-", "l": "-", "ft": "-", "wt": "-"}, "yaxisheaders": [""], "fieldsheaders": ["Publications"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=600&h=250';
|
||||||
|
|
||||||
|
this.showLoading = false;
|
||||||
},
|
},
|
||||||
err => {
|
err => {
|
||||||
console.log(err);
|
console.log(err);
|
||||||
this.errorMessage = 'No project found';
|
this.errorMessage = 'No project found';
|
||||||
|
this.showLoading = false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
|
||||||
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
|
||||||
|
<div *ngIf="showLoading" class="uk-alert uk-alert-primary" role="alert">Loading...</div>
|
||||||
|
|
||||||
<div *ngIf="publicationInfo != null" uk-grid>
|
<div *ngIf="publicationInfo != null" uk-grid>
|
||||||
<div class="uk-width-3-4@l uk-width-3-4@xl uk-width-3-4@m uk-width-1-1@s">
|
<div class="uk-width-3-4@l uk-width-3-4@xl uk-width-3-4@m uk-width-1-1@s">
|
||||||
|
@ -51,13 +51,13 @@
|
||||||
<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">Embargo end date: </dt>
|
<dt *ngIf="publicationInfo.embargoEndDate">Embargo end date: </dt>
|
||||||
<dd *ngIf="publicationInfo.embargoEndDate">{{publicationInfo.embargoEndDate}}</dd>
|
<dd *ngIf="publicationInfo.embargoEndDate">{{publicationInfo.embargoEndDate}}</dd>
|
||||||
|
</dl>
|
||||||
|
|
||||||
<showIdentifiers [identifiers]="publicationInfo.identifiers"></showIdentifiers>
|
<showIdentifiers [identifiers]="publicationInfo.identifiers"></showIdentifiers>
|
||||||
<showSubjects [subjects]="publicationInfo.subjects"
|
<showSubjects [subjects]="publicationInfo.subjects"
|
||||||
[otherSubjects]="publicationInfo.otherSubjects"
|
[otherSubjects]="publicationInfo.otherSubjects"
|
||||||
[classifiedSubjects]="publicationInfo.classifiedSubjects">
|
[classifiedSubjects]="publicationInfo.classifiedSubjects">
|
||||||
</showSubjects>
|
</showSubjects>
|
||||||
</dl>
|
|
||||||
|
|
||||||
<blockquote *ngIf="publicationInfo.description">
|
<blockquote *ngIf="publicationInfo.description">
|
||||||
<div class="uk-text-justify">{{publicationInfo.description}}</div>
|
<div class="uk-text-justify">{{publicationInfo.description}}</div>
|
||||||
|
@ -69,7 +69,7 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<ul class="uk-tab uk-visible@xl" uk-tab="connect: #tab-content">
|
<ul class="uk-tab uk-visible@xl" uk-tab="connect: #tab-content">
|
||||||
<li (click)="activeTab='References'">
|
<li *ngIf="publicationInfo.references" (click)="activeTab='References'">
|
||||||
<a>
|
<a>
|
||||||
References
|
References
|
||||||
<span *ngIf="!publicationInfo.references" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!publicationInfo.references" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -78,7 +78,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="activeTab='Related Research Results'">
|
<li *ngIf="publicationInfo.relatedResearchResults" (click)="activeTab='Related Research Results'">
|
||||||
<a>
|
<a>
|
||||||
Related Research Results
|
Related Research Results
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -86,7 +86,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="activeTab='Similar Research Results'">
|
<li *ngIf="publicationInfo.similarResearchResults" (click)="activeTab='Similar Research Results'">
|
||||||
<a>
|
<a>
|
||||||
Similar Research Results
|
Similar Research Results
|
||||||
<span *ngIf="!publicationInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!publicationInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -95,7 +95,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="activeTab='Related Organizations'">
|
<li *ngIf="publicationInfo.organizations" (click)="activeTab='Related Organizations'">
|
||||||
<a>
|
<a>
|
||||||
Related Organizations
|
Related Organizations
|
||||||
<span *ngIf="!publicationInfo.organizations" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!publicationInfo.organizations" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -130,7 +130,7 @@
|
||||||
</button>
|
</button>
|
||||||
|
|
||||||
<ul id="toggle-small-tabs" class="uk-subnav uk-subnav-pill uk-dropdown uk-hidden@xl" uk-switcher="{connect: #tab-content}" uk-dropdown="mode: click" uk-toggle="target: #toggle-small-tabs">
|
<ul id="toggle-small-tabs" class="uk-subnav uk-subnav-pill uk-dropdown uk-hidden@xl" uk-switcher="{connect: #tab-content}" uk-dropdown="mode: click" uk-toggle="target: #toggle-small-tabs">
|
||||||
<li (click)="activeTab='References'">
|
<li *ngIf="publicationInfo.references" (click)="activeTab='References'">
|
||||||
<a>
|
<a>
|
||||||
References
|
References
|
||||||
<span *ngIf="!publicationInfo.references" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!publicationInfo.references" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -139,7 +139,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="activeTab='Related Research Results'">
|
<li *ngIf="publicationInfo.relatedResearchResults" (click)="activeTab='Related Research Results'">
|
||||||
<a>
|
<a>
|
||||||
Related Research Results
|
Related Research Results
|
||||||
<span class="uk-badge uk-badge-notification">
|
<span class="uk-badge uk-badge-notification">
|
||||||
|
@ -147,7 +147,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="activeTab='Similar Research Results'">
|
<li *ngIf="publicationInfo.similarResearchResults" (click)="activeTab='Similar Research Results'">
|
||||||
<a>
|
<a>
|
||||||
Similar Research Results
|
Similar Research Results
|
||||||
<span *ngIf="!publicationInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!publicationInfo.similarResearchResults" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -156,7 +156,7 @@
|
||||||
</span>
|
</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li (click)="activeTab='Related Organizations'">
|
<li *ngIf="publicationInfo.organizations" (click)="activeTab='Related Organizations'">
|
||||||
<a>
|
<a>
|
||||||
Related Organizations
|
Related Organizations
|
||||||
<span *ngIf="!publicationInfo.organizations" class="uk-badge uk-badge-notification">0</span>
|
<span *ngIf="!publicationInfo.organizations" class="uk-badge uk-badge-notification">0</span>
|
||||||
|
@ -185,7 +185,7 @@
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<ul id="tab-content" class="uk-switcher uk-margin custom-tab-content">
|
<ul id="tab-content" class="uk-switcher uk-margin custom-tab-content">
|
||||||
<li class="uk-animation-fade">
|
<li *ngIf="publicationInfo.references" class="uk-animation-fade">
|
||||||
<div *ngIf="!publicationInfo.references" class = "uk-alert uk-alert-primary" >
|
<div *ngIf="!publicationInfo.references" class = "uk-alert uk-alert-primary" >
|
||||||
There are no references
|
There are no references
|
||||||
</div>
|
</div>
|
||||||
|
@ -225,7 +225,7 @@
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="uk-animation-fade">
|
<li *ngIf="publicationInfo.relatedResearchResults" class="uk-animation-fade">
|
||||||
<div *ngIf="!publicationInfo.relatedResearchResults" class = "uk-alert uk-alert-primary">
|
<div *ngIf="!publicationInfo.relatedResearchResults" class = "uk-alert uk-alert-primary">
|
||||||
There are no related research results
|
There are no related research results
|
||||||
</div>
|
</div>
|
||||||
|
@ -239,7 +239,7 @@
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
|
||||||
<li class="uk-animation-fade">
|
<li *ngIf="publicationInfo.similarResearchResults" class="uk-animation-fade">
|
||||||
<div *ngIf="!publicationInfo.similarResearchResults" class = "uk-alert uk-alert-primary">
|
<div *ngIf="!publicationInfo.similarResearchResults" class = "uk-alert uk-alert-primary">
|
||||||
There are no similar research results
|
There are no similar research results
|
||||||
</div>
|
</div>
|
||||||
|
@ -249,7 +249,7 @@
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="uk-animation-fade">
|
<li *ngIf="publicationInfo.organizations" class="uk-animation-fade">
|
||||||
<div *ngIf="!publicationInfo.organizations" class = "uk-alert uk-alert-primary">
|
<div *ngIf="!publicationInfo.organizations" class = "uk-alert uk-alert-primary">
|
||||||
There are no related organizations
|
There are no related organizations
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -47,6 +47,8 @@ export class PublicationComponent {
|
||||||
|
|
||||||
public warningMessage = "";
|
public warningMessage = "";
|
||||||
public errorMessage = "";
|
public errorMessage = "";
|
||||||
|
public showLoading: boolean = true;
|
||||||
|
|
||||||
public routerHelper:RouterHelper = new RouterHelper();
|
public routerHelper:RouterHelper = new RouterHelper();
|
||||||
|
|
||||||
public activeTab: string = "References";
|
public activeTab: string = "References";
|
||||||
|
@ -88,6 +90,7 @@ export class PublicationComponent {
|
||||||
if (typeof document !== 'undefined') {
|
if (typeof document !== 'undefined') {
|
||||||
this.element.nativeElement.scrollIntoView();
|
this.element.nativeElement.scrollIntoView();
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -98,12 +101,12 @@ export class PublicationComponent {
|
||||||
getPublicationInfo(id:string) {
|
getPublicationInfo(id:string) {
|
||||||
this.warningMessage = '';
|
this.warningMessage = '';
|
||||||
this.errorMessage=""
|
this.errorMessage=""
|
||||||
|
this.showLoading = true;
|
||||||
|
|
||||||
this._publicationService.getPublicationInfo(this.articleId).subscribe(
|
this._publicationService.getPublicationInfo(this.articleId).subscribe(
|
||||||
data => {
|
data => {
|
||||||
this.publicationInfo = data;
|
this.publicationInfo = data;
|
||||||
|
|
||||||
|
|
||||||
// this.result = []
|
// this.result = []
|
||||||
// this.result = {id: id, type :"dataset", source : "openaire", title: this.publicationInfo.title,url: '', result: '', accessRights: this.publicationInfo.bestlicense, embargoEndDate: ''};
|
// this.result = {id: id, type :"dataset", source : "openaire", title: this.publicationInfo.title,url: '', result: '', accessRights: this.publicationInfo.bestlicense, embargoEndDate: ''};
|
||||||
this.updateTitle(this.publicationInfo.title.name);
|
this.updateTitle(this.publicationInfo.title.name);
|
||||||
|
@ -131,12 +134,32 @@ export class PublicationComponent {
|
||||||
if(this.publicationInfo.identifiers != undefined && this.publicationInfo.identifiers.has('doi')) {
|
if(this.publicationInfo.identifiers != undefined && this.publicationInfo.identifiers.has('doi')) {
|
||||||
this.doi = this.publicationInfo.identifiers.get('doi')[0];
|
this.doi = this.publicationInfo.identifiers.get('doi')[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.showLoading = false;
|
||||||
|
|
||||||
|
if(this.publicationInfo.references) {
|
||||||
|
this.activeTab = "References";
|
||||||
|
} else if(this.publicationInfo.relatedResearchResults) {
|
||||||
|
this.activeTab = "Related Research Results";
|
||||||
|
} else if(this.publicationInfo.similarResearchResults) {
|
||||||
|
this.activeTab = "Similar Research Results";
|
||||||
|
} else if(this.publicationInfo.organizations) {
|
||||||
|
this.activeTab = "Related Organizations";
|
||||||
|
} else if(this.publicationInfo.bioentities) {
|
||||||
|
this.activeTab = "bioentities";
|
||||||
|
} else if(this.publicationInfo.software) {
|
||||||
|
this.activeTab = "Software";
|
||||||
|
} else {
|
||||||
|
this.activeTab = "Metrics";
|
||||||
|
}
|
||||||
|
console.info("activeTab is "+this.activeTab);
|
||||||
},
|
},
|
||||||
err => {
|
err => {
|
||||||
console.log(err);
|
console.log(err);
|
||||||
console.info("error");
|
console.info("error");
|
||||||
|
|
||||||
this.errorMessage = 'No publication found';
|
this.errorMessage = 'No publication found';
|
||||||
|
this.showLoading = false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@ import {OpenaireProperties} from '../utils/properties/openaireProperties';
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'showIdentifiers',
|
selector: 'showIdentifiers',
|
||||||
template: `
|
template: `
|
||||||
<span class="uk-description-list-horizontal" *ngIf="identifiers != undefined && identifiers.size > 0">
|
<dl class="uk-description-list" *ngIf="identifiers != undefined && identifiers.size > 0">
|
||||||
<dt>Identifiers:</dt>
|
<dt>Identifiers:</dt>
|
||||||
<dd>
|
<dd>
|
||||||
<span *ngFor="let key of identifiers.keys() let i=index">
|
<span *ngFor="let key of identifiers.keys() let i=index">
|
||||||
|
@ -21,7 +21,7 @@ import {OpenaireProperties} from '../utils/properties/openaireProperties';
|
||||||
</span>
|
</span>
|
||||||
</span>
|
</span>
|
||||||
</dd>
|
</dd>
|
||||||
</span>
|
</dl>
|
||||||
|
|
||||||
`
|
`
|
||||||
})
|
})
|
||||||
|
|
|
@ -3,7 +3,7 @@ import {Component, Input} from '@angular/core';
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'showSubjects',
|
selector: 'showSubjects',
|
||||||
template: `
|
template: `
|
||||||
<span class="uk-description-list-horizontal" *ngIf="subjects != undefined">
|
<dl class="uk-description-list" *ngIf="subjects != undefined">
|
||||||
|
|
||||||
<dt *ngIf="(subjects != undefined && subjects.length > 0) ||
|
<dt *ngIf="(subjects != undefined && subjects.length > 0) ||
|
||||||
(otherSubjects != undefined && otherSubjects.size > 0)">
|
(otherSubjects != undefined && otherSubjects.size > 0)">
|
||||||
|
@ -50,7 +50,7 @@ import {Component, Input} from '@angular/core';
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</dd>
|
</dd>
|
||||||
</span>
|
</dl>
|
||||||
`
|
`
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|
|
@ -74,7 +74,9 @@ export class AdvancedSearchPageComponent {
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.updateTitle("Advanced search "+this.pageTitle);
|
this.updateTitle("Advanced search "+this.pageTitle);
|
||||||
this.updateDescription("Openaire, search, repositories, open access, type, data provider, funder, project, "+ this.pageTitle);
|
this.updateDescription("Openaire, search, repositories, open access, type, data provider, funder, project, "+ this.pageTitle);
|
||||||
this.updateUrl(OpenaireProperties.getBaseLink()+location.pathname);
|
if(typeof window !== 'undefined') {
|
||||||
|
this.updateUrl(OpenaireProperties.getBaseLink()+location.pathname);
|
||||||
|
}
|
||||||
|
|
||||||
this.searchUtils.baseUrl = "/" + this.searchUtils.baseUrl;
|
this.searchUtils.baseUrl = "/" + this.searchUtils.baseUrl;
|
||||||
this.updateBaseUrlWithParameters();
|
this.updateBaseUrlWithParameters();
|
||||||
|
|
|
@ -155,7 +155,9 @@ export class SearchPageComponent {
|
||||||
this.defineUrlParam();
|
this.defineUrlParam();
|
||||||
this.updateTitle(this.pageTitle);
|
this.updateTitle(this.pageTitle);
|
||||||
this.updateDescription("Openaire, search, repositories, open access, type, data provider, funder, project, " + this.type + "," +this.pageTitle);
|
this.updateDescription("Openaire, search, repositories, open access, type, data provider, funder, project, " + this.type + "," +this.pageTitle);
|
||||||
//this.updateUrl(OpenaireProperties.getBaseLink()+location.pathname);
|
if(typeof window !== 'undefined') {
|
||||||
|
this.updateUrl(OpenaireProperties.getBaseLink()+location.pathname);
|
||||||
|
}
|
||||||
// console.info(this.entityType + " " + this.urlParam + this.type);
|
// console.info(this.entityType + " " + this.urlParam + this.type);
|
||||||
}
|
}
|
||||||
ngAfterViewChecked(){
|
ngAfterViewChecked(){
|
||||||
|
|
|
@ -171,7 +171,9 @@ export class SearchPageTableViewComponent {
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.updateTitle(this.pageTitle);
|
this.updateTitle(this.pageTitle);
|
||||||
this.updateDescription("Openaire, search, repositories, open access, type, data provider, funder, project, " + this.type + "," +this.pageTitle);
|
this.updateDescription("Openaire, search, repositories, open access, type, data provider, funder, project, " + this.type + "," +this.pageTitle);
|
||||||
this.updateUrl(OpenaireProperties.getBaseLink()+location.pathname);
|
if(typeof window !== 'undefined') {
|
||||||
|
this.updateUrl(OpenaireProperties.getBaseLink()+location.pathname);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public sortByOrganization = (dataprovider: any) => {
|
public sortByOrganization = (dataprovider: any) => {
|
||||||
|
|
|
@ -350,7 +350,7 @@ export class SearchDataprovidersService {
|
||||||
result['organizations'] = res[1];
|
result['organizations'] = res[1];
|
||||||
result['countries'] = res[0];
|
result['countries'] = res[0];
|
||||||
result['subjects'] = this.getDataproviderSubjects(resData);
|
result['subjects'] = this.getDataproviderSubjects(resData);
|
||||||
console.log(result['subjects']);
|
//console.log(result['subjects']);
|
||||||
results.push(result);
|
results.push(result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -43,17 +43,22 @@ export class ContentProvidersDatatablePipe implements PipeTransform {
|
||||||
returnValue = true;
|
returnValue = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(row.countries.toLowerCase().indexOf(query) > -1) {
|
if(row.countries && row.countries.length > 0) {
|
||||||
returnValue = true;
|
for(let country of row.countries) {
|
||||||
|
if(country.toLowerCase().indexOf(query) > -1) {
|
||||||
|
returnValue = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(row.compatibility.toLowerCase().indexOf(query) > -1) {
|
if(row.compatibility.toLowerCase().indexOf(query) > -1) {
|
||||||
returnValue = true;
|
returnValue = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(row.organizations > 0) {
|
if(row.organizations && row.organizations.length > 0) {
|
||||||
for(let organization of row.organizations) {
|
for(let organization of row.organizations) {
|
||||||
if(row.organization.toLowerCase().indexOf(query) > -1) {
|
if(organization.name.toLowerCase().indexOf(query) > -1) {
|
||||||
returnValue = true;
|
returnValue = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue