Revision 57380
Added by Konstantinos Triantafyllou over 4 years ago
modules/uoa-monitor-portal/trunk/monitor/src/app/utils/entities/stakeholder.ts | ||
---|---|---|
131 | 131 |
|
132 | 132 |
let c_pubs_gg_funding_scheme = new Indicator("What is the percentage of green and gold publications by funding scheme / programme?",null, "chart","medium",true, |
133 | 133 |
true, [new IndicatorPath("bar", "stats-tool", "chart?json="+encodeURIComponent('{"library":"HighCharts","chartDescription":{"colors":["#42a5f5","#26a69a","#90ed7d","#607d8b","#00838f","#689f38","#e4d354","#2b908f","#546e7a","#01579"],"queries":[{"name":"Gold","color":"#f8b500","type":"bar","query":{"select":[{"field":"result","aggregate":"count"},{"field":"result.project.funding level 1","aggregate":null}],"filters":[{"groupFilters":[{"field":"result.project.funder","type":"=","values":["'+stakeholder.index_name+'"]},,{"field":"result.type","type":"=","values":["publication"]},{"field":"result.access mode","type":"=","values":["Open Access"]}],"op":"AND"},{"groupFilters":[{"field":"result.datasource.type","type":"=","values":["Journal"]},{"field":"result.datasource.type","type":"=","values":["Journal Aggregator/Publisher"]}],"op":"OR"}],"entity":"result","profile":"OpenAIRE original","limit":"0"}},{"name":"Green","color":"#239d60","type":"bar","query":{"select":[{"field":"result","aggregate":"count"},{"field":"result.project.funding level 1","aggregate":null}],"filters":[{"groupFilters":[{"field":"result.project.funder","type":"=","values":["'+stakeholder.index_name+'"]},{"field":"result.project.funding level 0","type":"=","values":["H2020"]},{"field":"result.type","type":"=","values":["publication"]},{"field":"result.access mode","type":"=","values":["Open Access"]}],"op":"AND"},{"groupFilters":[{"field":"result.datasource.type","type":"=","values":["Institutional Repository"]},{"field":"result.datasource.type","type":"=","values":["Thematic Repository"]}],"op":"OR"}],"entity":"result","profile":"OpenAIRE original","limit":"0"}}],"chart":{"backgroundColor":"#FFFFFFFF","borderColor":"#335cadff","borderRadius":0,"borderWidth":0,"plotBorderColor":"#ccccccff","plotBorderWidth":0},"title":{"text":"H2020 green and gold publications"},"subtitle":{"text":"by funding scheme"},"yAxis":{"title":{"text":"Publications"}},"xAxis":{"title":{"text":"Funding scheme"}},"lang":{"noData":"No Data available for the Query"},"exporting":{"enabled":true},"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"}}}'), null)]); |
134 |
pubDefSub.charts.push(c_pubs_gg_funding_scheme); |
|
134 |
//pubDefSub.charts.push(c_pubs_gg_funding_scheme);
|
|
135 | 135 |
|
136 | 136 |
let c_pubs_open = new Indicator("Open Access publications timeline",null, "chart","medium",true, true, |
137 | 137 |
[new IndicatorPath("column", "stats-tool", "chart?json="+encodeURIComponent('{"library":"HighCharts","chartDescription":{"queries":[{"name":"OA publications","type":"column","query":{"select":[{"field":"publication","aggregate":"count"},{"field":"publication.year","aggregate":null}],"filters":[{"groupFilters":[{"field":"publication.access mode","type":"=","values":["Open Access"]}],"op":"AND"},{"groupFilters":[{"field":"publication.year","type":">=","values":["2000"]},{"field":"publication.year","type":"<=","values":["2019"]}],"op":"AND"},{"groupFilters":[{"field":"publication.project.funder","type":"=","values":["'+stakeholder.index_name+'"]}],"op":"AND"}],"entity":"publication","profile":"OpenAIRE All-inclusive","limit":"30"}}],"chart":{"backgroundColor":"#FFFFFFFF","borderColor":"#335cadff","borderRadius":0,"borderWidth":0,"plotBorderColor":"#ccccccff","plotBorderWidth":0},"title":{"text":"Open Access Publications"},"subtitle":{},"yAxis":{"title":{"text":"publications"}},"xAxis":{"title":{"text":"year"}},"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"}}}'), null)]); |
modules/uoa-monitor-portal/trunk/monitor/src/app/monitor/monitor.component.html | ||
---|---|---|
20 | 20 |
<div class="uk-navbar-center"> |
21 | 21 |
<ul class="uk-navbar-nav"> |
22 | 22 |
<ng-template ngFor [ngForOf]="stakeholder.topics" let-topic let-i="index"> |
23 |
<li *ngIf="topic.isPublic && topic.isActive" [ngClass]="(topic.alias === activeTopic.alias)?'uk-active':''"> |
|
23 |
<li *ngIf="topic.isPublic && topic.isActive" |
|
24 |
[ngClass]="(topic.alias === activeTopic.alias)?'uk-active':''"> |
|
24 | 25 |
<a (click)="navigateTo(stakeholder.alias, topic.alias)">{{topic.name}}</a> |
25 | 26 |
</li> |
26 | 27 |
</ng-template> |
... | ... | |
34 | 35 |
<div *ngIf="activeSubCategory" class="uk-width-expand uk-padding uk-text-center@s uk-text-left@m"> |
35 | 36 |
<h5 class="uk-margin-bottom uk-text-bold">Indicators</h5> |
36 | 37 |
<div class="uk-grid-medium uk-margin-bottom" uk-grid> |
37 |
<div *ngFor="let number of activeSubCategory.numbers; let i=index;" |
|
38 |
[class.uk-width-1-3@m]="number.width === 'small'" |
|
39 |
[class.uk-width-1-2@m]="number.width === 'medium'" |
|
40 |
[class.uk-width-1-1@m]="number.width === 'large'"> |
|
41 |
<div class="uk-card uk-card-default uk-padding-small" [attr.uk-tooltip]="number.description"> |
|
42 |
<h6>{{number.name}}</h6> |
|
43 |
<div class="uk-h2"> |
|
44 |
{{numberResults.get(i)|number}} |
|
38 |
<ng-template ngFor [ngForOf]="activeSubCategory.numbers" let-number let-i="index"> |
|
39 |
<div *ngIf="number.isActive && number.isPublic" |
|
40 |
[class.uk-width-1-3@m]="number.width === 'small'" |
|
41 |
[class.uk-width-1-2@m]="number.width === 'medium'" |
|
42 |
[class.uk-width-1-1@m]="number.width === 'large'"> |
|
43 |
<div class="uk-card uk-card-default uk-padding-small" [attr.uk-tooltip]="number.description"> |
|
44 |
<h6>{{number.name}}</h6> |
|
45 |
<div class="uk-h2"> |
|
46 |
{{numberResults.get(i)|number}} |
|
47 |
</div> |
|
45 | 48 |
</div> |
46 | 49 |
</div> |
47 |
</div>
|
|
50 |
</ng-template>
|
|
48 | 51 |
</div> |
49 | 52 |
<div class="uk-grid-medium uk-margin-bottom" uk-grid> |
50 |
<div *ngFor="let chart of activeSubCategory.charts; let i=index;" |
|
53 |
<ng-template ngFor [ngForOf]="activeSubCategory.charts" let-chart let-i="index"> |
|
54 |
<div *ngIf="chart.isActive && chart.isPublic" |
|
51 | 55 |
[class.uk-width-1-3@m]="chart.width === 'small'" |
52 | 56 |
[class.uk-width-1-2@m]="chart.width === 'medium'" |
53 | 57 |
[class.uk-width-1-1@m]="chart.width === 'large'"> |
54 | 58 |
<div> |
55 | 59 |
<h5>{{chart.name}}</h5> |
56 | 60 |
<div class="uk-card uk-card-default uk-padding-small" [attr.uk-tooltip]="chart.description"> |
57 |
<div class="uk-button-group"> |
|
61 |
<div *ngIf="chart.indicatorPaths.length > 1" class="uk-button-group">
|
|
58 | 62 |
<button *ngFor="let indicatorPath of chart.indicatorPaths;" |
59 | 63 |
class="uk-button" |
60 | 64 |
(click)="setActiveChart(i, indicatorPath.type)" |
... | ... | |
62 | 66 |
{{indicatorPath.type}} |
63 | 67 |
</button> |
64 | 68 |
</div> |
65 |
<iframe *ngIf="chartsActiveType.get(i).source !== 'fake'" [src]="getUrlByStakeHolder(chartsActiveType.get(i))" |
|
69 |
<iframe *ngIf="chartsActiveType.get(i).source !== 'fake'" |
|
70 |
[src]="getUrlByStakeHolder(chartsActiveType.get(i))" |
|
66 | 71 |
class="uk-width-1-1" |
67 | 72 |
height="600"></iframe> |
68 |
<img *ngIf="chartsActiveType.get(i).source === 'fake'" [src]="getUrlByStakeHolder(chartsActiveType.get(i))" |
|
69 |
class="uk-width-1-1" |
|
70 |
height="600"> |
|
73 |
<img *ngIf="chartsActiveType.get(i).source === 'fake'" |
|
74 |
[src]="getUrlByStakeHolder(chartsActiveType.get(i))" |
|
75 |
class="uk-width-1-1" |
|
76 |
height="600"> |
|
71 | 77 |
</div> |
72 | 78 |
</div> |
73 | 79 |
</div> |
80 |
</ng-template> |
|
74 | 81 |
</div> |
75 | 82 |
</div> |
76 | 83 |
</div> |
Also available in: Unified diff
[Monitor]: Add active and public for charts and numbers