diff --git a/portal-2/src/app/searchPages/advanced/advancedSearchDataProviders.component.ts b/portal-2/src/app/searchPages/advanced/advancedSearchDataProviders.component.ts index 6fc92253..bc354c92 100644 --- a/portal-2/src/app/searchPages/advanced/advancedSearchDataProviders.component.ts +++ b/portal-2/src/app/searchPages/advanced/advancedSearchDataProviders.component.ts @@ -15,6 +15,7 @@ import {SearchUtilsClass } from '../searchUtils/searchUtils.class'; selector: 'advanced-search-dataprovider', template: ` diff --git a/portal-2/src/app/searchPages/dataProviders/entityRegistries.component.ts b/portal-2/src/app/searchPages/dataProviders/entityRegistries.component.ts index 22346de8..fedc865d 100644 --- a/portal-2/src/app/searchPages/dataProviders/entityRegistries.component.ts +++ b/portal-2/src/app/searchPages/dataProviders/entityRegistries.component.ts @@ -15,7 +15,7 @@ import {ExportCSVComponent} from '../../utils/exportCSV.component'; selector: 'search-entity-registries', template: ` - diff --git a/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts b/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts index 265fbc3c..fffd51e4 100644 --- a/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts +++ b/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts @@ -36,7 +36,7 @@ import {SearchUtilsClass} from './searchUtils.class'; (queryChange)="queryChanged($event)"> - +
@@ -52,6 +52,7 @@ import {SearchUtilsClass} from './searchUtils.class'; export class AdvancedSearchPageComponent { @Input() pageTitle = ""; @Input() results = []; + @Input() type; @Input() entityType; @Input() searchUtils:SearchUtilsClass = new SearchUtilsClass(); @Input() fieldIds: string[]; diff --git a/portal-2/src/app/searchPages/searchUtils/searchDownload.component.ts b/portal-2/src/app/searchPages/searchUtils/searchDownload.component.ts index 5f44b6d2..d5d4725c 100644 --- a/portal-2/src/app/searchPages/searchUtils/searchDownload.component.ts +++ b/portal-2/src/app/searchPages/searchUtils/searchDownload.component.ts @@ -1,23 +1,25 @@ import {Component, Input, Output, EventEmitter, ViewChild} from '@angular/core'; import {Observable} from 'rxjs/Observable'; import {AlertModal} from '../../utils/modal/alert'; +import {OpenaireProperties} from '../../utils/properties/openaireProperties'; @Component({ selector: 'search-download', template: `
-
- + -
+
@@ -28,12 +30,14 @@ export class SearchDownloadComponent { @Input() totalResults:number = 0; @ViewChild(AlertModal) alertApplyAll; @Output() downloadClick = new EventEmitter(); + private downloadURLAPI: string; constructor () { - } + + } ngOnInit() { - + this.downloadURLAPI = OpenaireProperties.getCsvApi(); } confirmClose(data){ diff --git a/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts b/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts index ca7758f3..83ecd2fd 100644 --- a/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts +++ b/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts @@ -41,7 +41,7 @@ import {DOI} from '../../utils/string-utils.class';
- +
@@ -51,7 +51,7 @@ import {DOI} from '../../utils/string-utils.class';
- +
@@ -125,7 +125,7 @@ export class SearchPageComponent { var doiQuery = ""; var keywordQuery = ""; if((keyword && keyword.length > 0)){ - if((this.type == 'publication' ||this.type == 'dataset')){ + if((this.type == 'publications' ||this.type == 'datasets')){ var DOIs:string[] = DOI.getDOIsFromString(keyword); var doisParams = ""; @@ -173,7 +173,7 @@ export class SearchPageComponent { var doiQuery = ""; var keywordQuery = ""; if((keyword && keyword.length > 0)){ - if((this.type == 'publication' ||this.type == 'dataset')){ + if((this.type == 'publications' ||this.type == 'datasets')){ var DOIs:string[] = DOI.getDOIsFromString(keyword); var doisParams = ""; @@ -273,7 +273,7 @@ export class SearchPageComponent { var keywordQuery = ""; console.info("keyyyyword::::"+ this.searchUtils.keyword ) if((this.searchUtils.keyword && this.searchUtils.keyword.length > 0)){ - if((this.type == 'publication' ||this.type == 'dataset')){ + if((this.type == 'publications' ||this.type == 'datasets')){ var DOIs:string[] = DOI.getDOIsFromString(this.searchUtils.keyword); var doisParams = ""; @@ -315,7 +315,7 @@ export class SearchPageComponent { var doiQuery = ""; var keywordQuery = ""; if((this.searchUtils.keyword && this.searchUtils.keyword.length > 0)){ - if((this.type == 'publication' ||this.type == 'dataset')){ + if((this.type == 'publications' ||this.type == 'datasets')){ var DOIs:string[] = DOI.getDOIsFromString(this.searchUtils.keyword); var doisParams = ""; for(var i =0 ;i < DOIs.length; i++){ diff --git a/portal-2/src/app/searchPages/searchUtils/searchPaging.component.ts b/portal-2/src/app/searchPages/searchUtils/searchPaging.component.ts index 2dde1f77..ead58de6 100644 --- a/portal-2/src/app/searchPages/searchUtils/searchPaging.component.ts +++ b/portal-2/src/app/searchPages/searchUtils/searchPaging.component.ts @@ -9,7 +9,7 @@ import {Observable} from 'rxjs/Observable';
- {{searchUtils.totalResults}} documents, page {{searchUtils.page}} of {{(totalPages())}} + {{searchUtils.totalResults}} {{type}}, page {{searchUtils.page}} of {{(totalPages())}}
` @@ -19,6 +19,7 @@ export class SearchPagingComponent { @Input() searchUtils; @Input() results; @Input() baseUrl; + @Input() type; // @Input() totalResults:number = 0; constructor () { diff --git a/portal-2/src/app/searchPages/simple/searchDataproviders.component.ts b/portal-2/src/app/searchPages/simple/searchDataproviders.component.ts index aa4ee076..ef099056 100644 --- a/portal-2/src/app/searchPages/simple/searchDataproviders.component.ts +++ b/portal-2/src/app/searchPages/simple/searchDataproviders.component.ts @@ -14,7 +14,7 @@ import {SearchUtilsClass } from '../searchUtils/searchUtils.class'; selector: 'search-dataproviders', template: ` - diff --git a/portal-2/src/app/searchPages/simple/searchDatasets.component.ts b/portal-2/src/app/searchPages/simple/searchDatasets.component.ts index 03f6048d..54bc93bc 100644 --- a/portal-2/src/app/searchPages/simple/searchDatasets.component.ts +++ b/portal-2/src/app/searchPages/simple/searchDatasets.component.ts @@ -15,7 +15,7 @@ import {DOI} from '../../utils/string-utils.class'; selector: 'search-datasets', template: ` - diff --git a/portal-2/src/app/searchPages/simple/searchOrganizations.component.ts b/portal-2/src/app/searchPages/simple/searchOrganizations.component.ts index 822fb515..682a7d91 100644 --- a/portal-2/src/app/searchPages/simple/searchOrganizations.component.ts +++ b/portal-2/src/app/searchPages/simple/searchOrganizations.component.ts @@ -13,7 +13,7 @@ import {SearchUtilsClass } from '../searchUtils/searchUtils.class'; selector: 'search-organizations', template: ` - diff --git a/portal-2/src/app/searchPages/simple/searchPeople.component.ts b/portal-2/src/app/searchPages/simple/searchPeople.component.ts index 9361eba8..7ee413c1 100644 --- a/portal-2/src/app/searchPages/simple/searchPeople.component.ts +++ b/portal-2/src/app/searchPages/simple/searchPeople.component.ts @@ -15,7 +15,7 @@ import {SearchUtilsClass } from '../searchUtils/searchUtils.class'; selector: 'search-people', template: ` - diff --git a/portal-2/src/app/searchPages/simple/searchProjects.component.ts b/portal-2/src/app/searchPages/simple/searchProjects.component.ts index 0c6d45f1..6001f4d8 100644 --- a/portal-2/src/app/searchPages/simple/searchProjects.component.ts +++ b/portal-2/src/app/searchPages/simple/searchProjects.component.ts @@ -13,7 +13,7 @@ import {SearchUtilsClass } from '../searchUtils/searchUtils.class'; selector: 'search-projects', template: ` - diff --git a/portal-2/src/app/searchPages/simple/searchPublications.component.ts b/portal-2/src/app/searchPages/simple/searchPublications.component.ts index 71cfa784..b50b709f 100644 --- a/portal-2/src/app/searchPages/simple/searchPublications.component.ts +++ b/portal-2/src/app/searchPages/simple/searchPublications.component.ts @@ -17,7 +17,7 @@ import {DOI} from '../../utils/string-utils.class'; selector: 'search-publications', template: ` - diff --git a/portal-2/src/app/utils/properties/openaireProperties.ts b/portal-2/src/app/utils/properties/openaireProperties.ts index 7c399e91..093c97c0 100644 --- a/portal-2/src/app/utils/properties/openaireProperties.ts +++ b/portal-2/src/app/utils/properties/openaireProperties.ts @@ -35,24 +35,23 @@ export class OpenaireProperties { private static claimsAPIURL = "http://scoobydoo.di.uoa.gr:8080/dnet-openaire-connector-service-1.0.0-SNAPSHOT/rest/claimsService/"; // private static searchAPIURL = "http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/"; - // private static searchAPIURLLAst = "http://astero.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/"; - // private searchAPIURL = "http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2.0/api/"; private static searchAPIURL = "http://scoobydoo.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/"; // private static searchAPIURLLAst = "http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/"; - private static searchAPIURLLAst = "http://scoobydoo.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/"; //private static searchAPIURLLAst = "http://scoobydoo.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/"; // private static searchResourcesAPIURL = "http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/resources"; private static searchResourcesAPIURL = "http://scoobydoo.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/resources"; - + //private static searchServiveURL = "http://astero.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/"; private static searchServiveURL = "http://scoobydoo.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/"; // private static searchServiveURL = "http://services.openaire.eu:8380/search/"; //private static searchServiveURL = "http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/"; + private static csvServiceAPIURL = "http://rudie.di.uoa.gr:8080/dnet-functionality-services-2.0.0-SNAPSHOT/rest/v2/api/";//publications?format=csv + private static searchCrossrefAPIURL = "http://api.crossref.org/works"; private static searchDataciteAPIURL = "http://search.datacite.org/api"; private static searchOrcidURL = "https://pub.orcid.org/"; @@ -234,6 +233,10 @@ export class OpenaireProperties { public static getHelpdesk():string{ return this.helpdesk; } + + public static getCsvApi(): string { + return this.csvServiceAPIURL; + } } export class ErrorCodes { public LOADING = 0;