From 3f714679d1ba92cc341cb55707c0a2b59ca5c0a2 Mon Sep 17 00:00:00 2001 From: Max Peintner Date: Thu, 27 Aug 2020 16:32:03 +0200 Subject: [PATCH] fix(console): mfa refresh after verification, member eventemitter (#651) * refresh mfa * fix: detail link from contributors * lint --- .../src/app/pages/orgs/org-detail/org-detail.component.ts | 4 +--- .../app/pages/orgs/org-members/org-members.component.html | 8 ++++---- .../app/pages/orgs/org-members/org-members.component.scss | 4 ++++ .../granted-project-detail.component.ts | 5 +---- .../owned-project-detail.component.ts | 4 +--- .../auth-user-mfa/auth-user-mfa.component.ts | 2 +- 6 files changed, 12 insertions(+), 15 deletions(-) diff --git a/console/src/app/pages/orgs/org-detail/org-detail.component.ts b/console/src/app/pages/orgs/org-detail/org-detail.component.ts index cf1ad62a85..5aff57f85b 100644 --- a/console/src/app/pages/orgs/org-detail/org-detail.component.ts +++ b/console/src/app/pages/orgs/org-detail/org-detail.component.ts @@ -190,9 +190,7 @@ export class OrgDetailComponent implements OnInit, OnDestroy { } public showDetail(): void { - if (this.org?.state === OrgState.ORGSTATE_ACTIVE) { - this.router.navigate(['org/members']); - } + this.router.navigate(['org/members']); } public verifyDomain(domain: OrgDomainView.AsObject): void { diff --git a/console/src/app/pages/orgs/org-members/org-members.component.html b/console/src/app/pages/orgs/org-members/org-members.component.html index c34214a808..df707d6de0 100644 --- a/console/src/app/pages/orgs/org-members/org-members.component.html +++ b/console/src/app/pages/orgs/org-members/org-members.component.html @@ -1,14 +1,14 @@ - - + + - + add{{ 'ACTIONS.NEW' | translate }} diff --git a/console/src/app/pages/orgs/org-members/org-members.component.scss b/console/src/app/pages/orgs/org-members/org-members.component.scss index 87c2505c6c..b6cb54e69f 100644 --- a/console/src/app/pages/orgs/org-members/org-members.component.scss +++ b/console/src/app/pages/orgs/org-members/org-members.component.scss @@ -37,6 +37,10 @@ } } +.add-button { + border-radius: .5rem; +} + .pointer { outline: none; cursor: pointer; diff --git a/console/src/app/pages/projects/granted-projects/granted-project-detail/granted-project-detail.component.ts b/console/src/app/pages/projects/granted-projects/granted-project-detail/granted-project-detail.component.ts index 4a9b53e765..474e3315b8 100644 --- a/console/src/app/pages/projects/granted-projects/granted-project-detail/granted-project-detail.component.ts +++ b/console/src/app/pages/projects/granted-projects/granted-project-detail/granted-project-detail.component.ts @@ -13,7 +13,6 @@ import { UserGrantContext } from 'src/app/modules/user-grants/user-grants-dataso import { Application, ApplicationSearchResponse, - ProjectGrantState, ProjectGrantView, ProjectMember, ProjectMemberSearchResponse, @@ -162,8 +161,6 @@ export class GrantedProjectDetailComponent implements OnInit, OnDestroy { } public showDetail(): void { - if (this.project.state === ProjectGrantState.PROJECTGRANTSTATE_ACTIVE) { - this.router.navigate(['granted-projects', this.project.projectId, 'grant', this.grantId, 'members']); - } + this.router.navigate(['granted-projects', this.project.projectId, 'grant', this.grantId, 'members']); } } diff --git a/console/src/app/pages/projects/owned-projects/owned-project-detail/owned-project-detail.component.ts b/console/src/app/pages/projects/owned-projects/owned-project-detail/owned-project-detail.component.ts index 1841235323..97ab2e9da5 100644 --- a/console/src/app/pages/projects/owned-projects/owned-project-detail/owned-project-detail.component.ts +++ b/console/src/app/pages/projects/owned-projects/owned-project-detail/owned-project-detail.component.ts @@ -234,8 +234,6 @@ export class OwnedProjectDetailComponent implements OnInit, OnDestroy { } public showDetail(): void { - if (this.project?.state === ProjectState.PROJECTSTATE_ACTIVE) { - this.router.navigate(['projects', this.project.projectId, 'members']); - } + this.router.navigate(['projects', this.project.projectId, 'members']); } } diff --git a/console/src/app/pages/users/user-detail/auth-user-detail/auth-user-mfa/auth-user-mfa.component.ts b/console/src/app/pages/users/user-detail/auth-user-detail/auth-user-mfa/auth-user-mfa.component.ts index e93ee56497..f621bbca93 100644 --- a/console/src/app/pages/users/user-detail/auth-user-detail/auth-user-mfa/auth-user-mfa.component.ts +++ b/console/src/app/pages/users/user-detail/auth-user-detail/auth-user-mfa/auth-user-mfa.component.ts @@ -49,7 +49,7 @@ export class AuthUserMfaComponent implements OnInit, OnDestroy { dialogRef.afterClosed().subscribe((code) => { if (code) { (this.service as AuthUserService).VerifyMfaOTP(code).then(() => { - // TODO: show state + this.getOTP(); }); } });