Merge branch 'new-theme' of code-repo.d4science.org:MaDgIK/monitor-dashboard into new-theme
This commit is contained in:
commit
06959c7526
|
@ -170,12 +170,17 @@ export class AppComponent implements OnInit, OnDestroy {
|
||||||
}
|
}
|
||||||
}));
|
}));
|
||||||
this.subscriptions.push(this.userManagementService.getUserInfo().subscribe(user => {
|
this.subscriptions.push(this.userManagementService.getUserInfo().subscribe(user => {
|
||||||
this.user = user;
|
|
||||||
if (user) {
|
if (user) {
|
||||||
|
this.user = user;
|
||||||
this.buildMenu();
|
this.buildMenu();
|
||||||
if (!this.notificationGroupsInitialized) {
|
if (!this.notificationGroupsInitialized) {
|
||||||
this.setNotificationGroups();
|
this.setNotificationGroups();
|
||||||
}
|
}
|
||||||
|
} else if(this.user) {
|
||||||
|
this.user = user;
|
||||||
|
this.buildMenu();
|
||||||
|
this.notificationGroupsInitialized = false;
|
||||||
|
this.notificationGroups = [];
|
||||||
}
|
}
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
|
@ -86,6 +86,8 @@ export class ManageStakeholdersComponent implements OnInit, OnDestroy {
|
||||||
this.displayStakeholders = res[1];
|
this.displayStakeholders = res[1];
|
||||||
this.alias = res[2];
|
this.alias = res[2];
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
|
}, error => {
|
||||||
|
this.loading = false;
|
||||||
}));
|
}));
|
||||||
|
|
||||||
this.subscriptions.push(UIkit.util.on(document, 'hidden', '#edit_modal', (): void => {
|
this.subscriptions.push(UIkit.util.on(document, 'hidden', '#edit_modal', (): void => {
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 2261f4ae6f8ea4a2d52aaf75c857e583bf913721
|
Subproject commit fa919431d3be63fb4045d47083b3ba7cd6414e03
|
|
@ -27,8 +27,7 @@ export class AdminDashboardGuard implements CanActivate, CanActivateChild {
|
||||||
check(path: string, alias: string): Observable<boolean> | boolean {
|
check(path: string, alias: string): Observable<boolean> | boolean {
|
||||||
let errorCode = LoginErrorCodes.NOT_LOGIN;
|
let errorCode = LoginErrorCodes.NOT_LOGIN;
|
||||||
return zip(
|
return zip(
|
||||||
this.userManagementService.getUserInfo(false)
|
this.userManagementService.getUserInfo() ,this.stakeholderService.getStakeholder(alias)
|
||||||
,this.stakeholderService.getStakeholder(alias)
|
|
||||||
).pipe(take(1),map(res => {
|
).pipe(take(1),map(res => {
|
||||||
if(res[0]) {
|
if(res[0]) {
|
||||||
errorCode = LoginErrorCodes.NOT_ADMIN;
|
errorCode = LoginErrorCodes.NOT_ADMIN;
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit eb5739ab8271aa71c8e58998ab88c61878f8788d
|
Subproject commit f085a90973b216b89065848dba864e2d581acc84
|
Loading…
Reference in New Issue