From cf83f5bd9d1458070022381a969e151322990211 Mon Sep 17 00:00:00 2001 From: "k.triantafyllou" Date: Wed, 29 May 2024 13:05:46 +0300 Subject: [PATCH] [master | DONE]: Add result belongs to configuration. --- src/app/openaireLibrary | 2 +- src/app/shared/irish.ts | 133 +++++++++++++++++++++++++++++++++++++--- 2 files changed, 124 insertions(+), 11 deletions(-) diff --git a/src/app/openaireLibrary b/src/app/openaireLibrary index 1ac4365..65a60dd 160000 --- a/src/app/openaireLibrary +++ b/src/app/openaireLibrary @@ -1 +1 @@ -Subproject commit 1ac4365e054f97190a851d2a5e4b64d66198f3e3 +Subproject commit 65a60ddad12498a410a1779ad3c234f9fef24507 diff --git a/src/app/shared/irish.ts b/src/app/shared/irish.ts index 70199a4..1f10091 100644 --- a/src/app/shared/irish.ts +++ b/src/app/shared/irish.ts @@ -4,6 +4,8 @@ import {LayoutService} from "../openaireLibrary/dashboard/sharedComponents/sideb import {Role} from "../openaireLibrary/login/utils/helper.class"; import {Stakeholder} from "../openaireLibrary/monitor/entities/stakeholder"; import {LinksResolver} from "../search/links-resolver"; +import {BelongsTo} from "../openaireLibrary/utils/entities/resultLandingInfo"; +import {properties} from "../../environments/environment"; export class Irish { public static irishAdminToolsPortalType = "country"; @@ -56,28 +58,139 @@ export class Irish { /** OA Indicator */ Irish.initializeOAIndicators(); + + /* Landing belongs to*/ + BelongsTo.result = { + fields: [ + {path: ['countries'], value: 'Ireland'}, + {path: ['organizations', 'country'], value: 'Ireland'}, + {path: ['fundedByProjects', 'funderJurisdiction'], value: 'IE'} + ], + message: 'This ((result)) is not specific to Ireland. For more details, please visit ' + + 'OpenAIRE Explore.' + } } public static initializeOAIndicators(): void { StakeholderConfiguration.openAccess.set('country', { - numerator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"ie_monitor\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0}, - denominator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"ie_monitor\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0} + numerator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"ie_monitor\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + }, + denominator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"ie_monitor\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + } }); StakeholderConfiguration.openAccess.set('organization', { - numerator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.organization.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0}, - denominator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.organization.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0} + numerator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.organization.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + }, + denominator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.organization.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + } }); StakeholderConfiguration.openAccess.set('funder', { - numerator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.project.funder.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0}, - denominator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.project.funder.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0} + numerator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.project.funder.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + }, + denominator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.project.funder.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + } }); StakeholderConfiguration.openAccess.set('researcher', { - numerator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.result_orcid.orcid\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {"statsProfile": "openaire_stats"}, "filters": {}, "filtersApplied": 0}, - denominator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.result_orcid.orcid\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {"statsProfile": "openaire_stats"}, "filters": {}, "filtersApplied": 0} + numerator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.result_orcid.orcid\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {"statsProfile": "openaire_stats"}, + "filters": {}, + "filtersApplied": 0 + }, + denominator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.result_orcid.orcid\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {"statsProfile": "openaire_stats"}, + "filters": {}, + "filtersApplied": 0 + } }); StakeholderConfiguration.openAccess.set('datasource', { - numerator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.datasource.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0}, - denominator: {"type": null, "format": "NUMBER", "source": "stats-tool", "url": "raw?json=", "jsonPath": ["data", "0", "0", "0"], "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.datasource.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", "parameters": {}, "filters": {}, "filtersApplied": 0} + numerator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.datasource.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]},{\"field\":\"publication.indi_result_oa_with_license.oa_with_license\",\"type\":\"=\",\"values\":[\"1\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + }, + denominator: { + "type": null, + "format": "NUMBER", + "source": "stats-tool", + "url": "raw?json=", + "jsonPath": ["data", "0", "0", "0"], + "chartObject": "{\"verbose\":false,\"series\":[{\"query\":{\"parameters\":[],\"select\":[{\"field\":\"publication\",\"aggregate\":\"count\"}],\"filters\":[{\"groupFilters\":[{\"field\":\"publication.datasource.id\",\"type\":\"=\",\"values\":[\"((__index_id__))\"]},{\"field\":\"publication.result_refereed.refereed\",\"type\":\"=\",\"values\":[\"peerReviewed\"]}],\"op\":\"AND\"}],\"entity\":\"publication\",\"profile\":\"((__profile__))\",\"limit\":\"30\"}}]}", + "parameters": {}, + "filters": {}, + "filtersApplied": 0 + } }); } }