[Trunk | Monitor Dashboard]: monitor.component: Show "style_switcher" (icon for administration portal), if user is logged in (not logged in and admin).
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-monitor-portal/trunk/monitor_dashboard@58725 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
2eb711011e
commit
7737ecaa42
|
@ -173,7 +173,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<a *ngIf="stakeholder && isAdmin()" id="style_switcher" class="" routerLinkActive="active"
|
<a *ngIf="stakeholder && isLoggedIn()" id="style_switcher" class="" routerLinkActive="active"
|
||||||
[routerLink]="['/admin', this.stakeholder.alias]">
|
[routerLink]="['/admin', this.stakeholder.alias]">
|
||||||
<div id="style_switcher_toggle"><i class="material-icons">settings</i></div>
|
<div id="style_switcher_toggle"><i class="material-icons">settings</i></div>
|
||||||
</a>
|
</a>
|
||||||
|
|
|
@ -391,6 +391,10 @@ export class MonitorComponent implements OnInit, OnDestroy, IDeactivateComponent
|
||||||
return this.user && Session.isPortalAdministrator(this.user);
|
return this.user && Session.isPortalAdministrator(this.user);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
isLoggedIn() {
|
||||||
|
return this.user;
|
||||||
|
}
|
||||||
|
|
||||||
public isPublicOrIsMember(isPublic: boolean): boolean {
|
public isPublicOrIsMember(isPublic: boolean): boolean {
|
||||||
if (isPublic) {
|
if (isPublic) {
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue