Some fixes regarding Preview mode. Change round of numbers to over 1M and to one decimal.

This commit is contained in:
Konstantinos Triantafyllou 2023-01-11 16:09:26 +02:00
parent 7568509b95
commit b3403a65cf
6 changed files with 11 additions and 9 deletions

View File

@ -34,7 +34,7 @@
</div>
<div class="uk-margin-medium-bottom">
<div *ngIf="!user">
If you have been already a member of this dashboard - Sign in in order to enter the dashboard
If you are a member of this dashboard, please sign in.
</div>
<div>
If you want to be a member of this dashboard - Contact us.

View File

@ -128,6 +128,9 @@ export class AppComponent implements OnInit, OnDestroy {
}));
this.route.queryParams.subscribe(params => {
this.view = params['view'];
if(this.stakeholder) {
this.setSideBar();
}
});
this.layoutService.setSmallScreen((this.innerWidth && this.innerWidth <= 640));
this.layoutService.setOpen(!(this.innerWidth && this.innerWidth <= 640));
@ -277,7 +280,7 @@ export class AppComponent implements OnInit, OnDestroy {
let topicItem: MenuItem = new MenuItem(topic.alias, topic.name, "", '/' + this.stakeholder.alias + '/' + topic.alias,
null, [], [], {}, {svg: topic.icon}, null, null, (
'/' + this.stakeholder.alias + '/' + topic.alias));
topicItem.items = topic.categories.map(category => {
topicItem.items = topic.categories.filter(category => this.hasPermission(category.visibility)).map(category => {
return new MenuItem(category.alias, category.name, "", ('/' + this.stakeholder.alias + '/' + topic.alias + '/' + category.alias),
null, [], [], {}, {svg: topic.icon}, null, null,
('/' + this.stakeholder.alias + '/' + topic.alias + '/' + category.alias));

View File

@ -86,7 +86,7 @@
|| !activeTopic || !activeCategory || !activeSubCategory)" [ngIfElse]="content">
<div class="message uk-text-center">
<h3>
No indicators available yet. Stay tuned!
Nothing to see here!
</h3>
</div>
</ng-template>
@ -103,7 +103,7 @@
<div *ngIf="!showDescriptionOverlay[j]">
<div class="uk-text-small uk-text-truncate uk-margin-xsmall-bottom uk-margin-right">{{indicator.name}}</div>
<div class="number uk-text-small uk-text-bold uk-text-lowercase">
<span *ngIf="numberResults.get(i + '-' + j)">{{numberResults.get(i + '-' + j) | numberRound}}</span>
<span *ngIf="numberResults.get(i + '-' + j)">{{numberResults.get(i + '-' + j) | numberRound: 2:1}}</span>
<span *ngIf="!numberResults.get(i + '-' + j)">--</span>
</div>
<div *ngIf="indicator.description || indicator.additionalDescription"

@ -1 +1 @@
Subproject commit e0c45b1065a2456620f8b4774ab27ecc17b0bb87
Subproject commit 4cd5bcd12b6d41cef384b54aa4a9c3fecbb46a1f

View File

@ -68,7 +68,7 @@
</div>
<div class="uk-text-small uk-text-truncate uk-margin-xsmall-bottom uk-margin-right">{{indicator.name}}</div>
<div class="number uk-text-small uk-text-bold uk-text-lowercase">
<span *ngIf="numberResults.get(i + '-' + j)">{{numberResults.get(i + '-' + j) | numberRound}}</span>
<span *ngIf="numberResults.get(i + '-' + j)">{{numberResults.get(i + '-' + j) | numberRound: 2:1}}</span>
<span *ngIf="!numberResults.get(i + '-' + j)">--</span>
</div>
</div>

View File

@ -204,12 +204,11 @@
<div #preview uk-dropdown="mode: click; pos: bottom-left; offset: 5; delay-hide: 0; flip: false">
<ul class="uk-nav uk-dropdown-nav">
<li><a target="_blank"
[routerLink]="'/' + stakeholder.alias + '/' + stakeholder.topics[topicIndex].alias"
[routerLink]="'/' + stakeholder.alias"
[queryParams]="{view: 'PUBLIC'}"
(click)="hide(preview)">Public view</a>
</li>
<li><a target="_blank" [routerLink]="'/' + stakeholder.alias + '/' +
stakeholder.topics[topicIndex].alias"
<li><a target="_blank" [routerLink]="'/' + stakeholder.alias"
[queryParams]="{view: 'RESTRICTED'}"
(click)="hide(preview)">Restricted view</a>
</li>