+
diff --git a/landingPages/project/project.component.ts b/landingPages/project/project.component.ts
index 5a978549..6b272bbc 100644
--- a/landingPages/project/project.component.ts
+++ b/landingPages/project/project.component.ts
@@ -427,7 +427,7 @@ export class ProjectComponent {
'{"library":"HighCharts","chartDescription":{"queries":[{"name":"Research outcomes","type":"pie","query":{"name":"projOA","parameters":["'+this.projectId+'"]}}],"chart":{"backgroundColor":"#FFFFFFFF","borderColor":"#335cadff","borderRadius":0,"borderWidth":0,"plotBorderColor":"#ccccccff","plotBorderWidth":0},"title":{"text":"Access mode of research outcomes"},"subtitle":{},"yAxis":{"title":{"text":"Research outcomes"}},"xAxis":{"title":{"text":"Access mode"}},"lang":{"noData":"No Data available for the Query"},"exporting":{"enabled":false},"plotOptions":{"series":{"dataLabels":{"enabled":false}}},"legend":{"enabled":true,"align":"center","verticalAlign":"bottom","layout":"horizontal"},"credits":{"href":null,"enabled":true,"text":"Created by OpenAIRE via HighCharts"}}}');
this.chartDatasourcesUrl = this.properties.statisticsFrameNewAPIURL +
'chart?json='+StringUtils.URIEncode(
- '{"library":"HighCharts","chartDescription":{"queries":[{"name":"Research outcomes","type":"bar","query":{"name":"projPubsRepos","parameters":["'+this.projectId+'"]}}],"chart":{"backgroundColor":"#FFFFFFFF","borderColor":"#335cadff","borderRadius":0,"borderWidth":0,"plotBorderColor":"#ccccccff","plotBorderWidth":0},"title":{"text":"Research outcomes per datasource"},"subtitle":{},"yAxis":{"title":{"text":"Research outcomes"}},"xAxis":{"title":{"text":"Datasource"}},"lang":{"noData":"No Data available for the Query"},"exporting":{"enabled":false},"plotOptions":{"series":{"dataLabels":{"enabled":false}}},"legend":{"enabled":true,"align":"center","verticalAlign":"bottom","layout":"horizontal"},"credits":{"href":null,"enabled":true,"text":"Created by OpenAIRE via HighCharts"}}}');
+ '{"library":"HighCharts","chartDescription":{"queries":[{"name":"Research outcomes","type":"bar","query":{"name":"projPubsRepos","parameters":["'+this.projectId+'"]}}],"chart":{"backgroundColor":"#FFFFFFFF","borderColor":"#335cadff","borderRadius":0,"borderWidth":0,"plotBorderColor":"#ccccccff","plotBorderWidth":0},"title":{"text":"Research outcomes per datasource"},"subtitle":{},"yAxis":{"title":{"text":"Research outcomes"}},"xAxis":{"title":{"text":"Datasource"}},"lang":{"noData":"No Data available for the Query"},"exporting":{"enabled":false},"plotOptions":{"series":{"dataLabels":{"enabled":true}}},"legend":{"enabled":true,"align":"center","verticalAlign":"bottom","layout":"horizontal"},"credits":{"href":null,"enabled":true,"text":"Created by OpenAIRE via HighCharts"}}}');
} else {
this.chartScientificResultsUrl = this.properties.statisticsFrameAPIURL + '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": ["Research Outcomes"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=90%&h=90%';
this.chartAccessModeUrl = this.properties.statisticsFrameAPIURL + '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": ["Research Outcomes"], "in": [], "filters": [{"name": "result_datasources-datasource-name", "values": [" "], "to": "-1"}], "having": [], "incfilters": [], "inchaving": [], "title": "", "subtitle": "", "xaxistitle": ""}&w=90%&h=90%';
@@ -779,6 +779,14 @@ export class ProjectComponent {
HelperFunctions.scroll();
}
+ public getParamsForSearchLink(type: string = "") {
+ if(type) {
+ return this.routerHelper.createQueryParams(['f0', 'fv0', 'type', 'qf', 'sortBy'], ['relprojectid', this.projectId, type, 'false', 'resultdateofacceptance,descending']);
+ } else {
+ return this.routerHelper.createQueryParams(['f0', 'fv0'], ['relprojectid', this.projectId]);
+ }
+ }
+
public get hasPrimaryInfo(): boolean {
return !!this.projectInfo && (
!!this.projectInfo.description
diff --git a/landingPages/project/project.module.ts b/landingPages/project/project.module.ts
index 131a5ceb..61b6228d 100644
--- a/landingPages/project/project.module.ts
+++ b/landingPages/project/project.module.ts
@@ -29,7 +29,7 @@ import {FeedbackModule} from "../feedback/feedback.module";
import {AltMetricsModule} from "../../utils/altmetrics.module";
import {TabsModule} from "../../utils/tabs/tabs.module";
import {SearchResultsModule} from "../../searchPages/searchUtils/searchResults.module";
-import {ResultPreviewModule} from "../../utils/result-preview/result-preview.module";
+//import {ResultPreviewModule} from "../../utils/result-preview/result-preview.module";
import {ModalSelectModule} from "../../utils/modal-select/modal-select.module";
@NgModule({
@@ -40,7 +40,7 @@ import {ModalSelectModule} from "../../utils/modal-select/modal-select.module";
SearchResearchResultsServiceModule, ProjectServiceModule,
Schema2jsonldModule, SEOServiceModule, HelperModule,
LandingHeaderModule, MatSelectModule, FeedbackModule, AltMetricsModule,
- TabsModule, ResultPreviewModule, ModalSelectModule
+ TabsModule, ModalSelectModule, SearchResultsModule//, ResultPreviewModule
],
declarations: [
ProjectComponent
diff --git a/services/searchResearchResults.service.ts b/services/searchResearchResults.service.ts
index 9dbf60cc..2c995a11 100644
--- a/services/searchResearchResults.service.ts
+++ b/services/searchResearchResults.service.ts
@@ -130,7 +130,16 @@ export class SearchResearchResultsService {
searchResultForEntity (resultType:string, params: string, page: number, size: number, properties:EnvProperties):any {
let link = properties.searchAPIURLLAst;
- let url = link+params+"/"+this.getEntityName(resultType,true)+ "?format=json";
+ //let url = link+params+"/"+this.getEntityName(resultType,true)+ "?format=json";
+ //url += "&page="+(page-1)+"&size="+size;
+ //url += "&sortBy=resultdateofacceptance,descending";
+
+ //let url = link+"/resources2?format=json&query="+params+" sortBy resultdateofacceptance/sort.descending&type="+this.getEntityName(resultType,true);
+
+ let url = link+"/"+this.getEntityName(resultType,true);
+ url += "?format=json";
+ url += "&fq="+params;
+ url += "&sortBy=resultdateofacceptance,descending";
url += "&page="+(page-1)+"&size="+size;
return this.http.get((properties.useCache)? (properties.cacheUrl+encodeURIComponent(url)): url)
@@ -139,7 +148,9 @@ export class SearchResearchResultsService {
//???? why different from above?
searchForDataproviders(resultType:string, params: string, page: number, size: number, properties:EnvProperties):any {
let link = properties.searchAPIURLLAst;
- let url = link+params+ "&page="+(page-1)+"&size="+size + "&format=json";
+ let url = link+params;
+ url += "&sortBy=resultdateofacceptance,descending";
+ url += "&page="+(page-1)+"&size="+size + "&format=json";
return this.http.get((properties.useCache)? (properties.cacheUrl+encodeURIComponent(url)): url)
.pipe(map(res => [res['meta'].total, this.parseResults(resultType, res['results'], properties)]));
}
diff --git a/utils/fetchEntitiesClasses/fetchResearchResults.class.ts b/utils/fetchEntitiesClasses/fetchResearchResults.class.ts
index dadd3cc3..d0c828c2 100644
--- a/utils/fetchEntitiesClasses/fetchResearchResults.class.ts
+++ b/utils/fetchEntitiesClasses/fetchResearchResults.class.ts
@@ -139,9 +139,11 @@ export class FetchResearchResults {
var parameters = "";
if(entity == "project") {
- parameters = "projects/"+id;
+ //parameters = "projects/"+id;
+ parameters = '(relprojectid exact "'+id+'")';
} else if(entity == "organization") {
- parameters = "organizations/"+id;
+ //parameters = "organizations/"+id;
+ parameters = '(relorganizationid exact "'+id+'")';
}
if(parameters != "") {