[Library|Trunk]

Monitor dashboard:
- add properties for stats tool for monitor and new schema
- apply filter for country and organization



git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@60254 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
argiro.kokogiannaki 2021-01-15 12:27:52 +00:00
parent 3b0f4a3e2b
commit 2600f89b77
2 changed files with 10 additions and 4 deletions

View File

@ -1,4 +1,5 @@
import {SafeResourceUrl} from "@angular/platform-browser";
import {properties} from "../../../../environments/environment";
export const ChartHelper = {
prefix: "((__",
@ -209,17 +210,20 @@ export class IndicatorFilterUtils{
}else if (field == "project"){
return this.getProjectFilter(filterType);
}
//TODO uncomment to add other options --> following doesn't work
/* else if (field == "country"){
else if (field == "country"){
return this.getCountryFilter(filterType);
}else if (field == "organization"){
return this.getOrganizationFilter(filterType);
}*/
}
}
static getResultFilter(dbType: string = null, filterType:FilterType) {
if (filterType == "fundingL0") {
return '{"groupFilters":[{"field":"' + dbType + '.project.funding level 0","type":"=","values":["' + ChartHelper.prefix + 'fundingL0' + ChartHelper.suffix + '"]}],"op":"AND"}';
if(properties.useOldStatisticsSchema) {
return '{"groupFilters":[{"field":"' + dbType + '.project.funding level 0","type":"=","values":["' + ChartHelper.prefix + 'fundingL0' + ChartHelper.suffix + '"]}],"op":"AND"}';
}else{//new statistcs schema
return '{"groupFilters":[{"field":"' + dbType + '.project funding level 0","type":"=","values":["' + ChartHelper.prefix + 'fundingL0' + ChartHelper.suffix + '"]}],"op":"AND"}';
}
} else if (filterType == "start_year") {
return '{"groupFilters":[{"field":"' + dbType + '.year","type":">=","values":["' + ChartHelper.prefix + 'start_year' + ChartHelper.suffix + '"]}],"op":"AND"}';
} else if (filterType == "end_year") {

View File

@ -18,6 +18,8 @@ export interface EnvProperties {
statisticsFrameAPIURL?: string;
statisticsFrameNewAPIURL?: string;
useNewStatistisTool?: boolean;
useOldStatisticsSchema?: boolean;
monitorStatsFrameUrl?:string;
disableFrameLoad?:boolean
statisticsAPIURL?: string;
impactFactorsAPIURL?: string;