From c0343db0e158bf515a0316ffd228f02ded9074db Mon Sep 17 00:00:00 2001 From: Bastian Hofmann Date: Wed, 25 Sep 2019 15:05:52 +0200 Subject: [PATCH] Fix broken about dialog on sign in page Signed-off-by: Bastian Hofmann --- src/portal/src/app/sign-in/sign-in.component.html | 5 +++-- src/portal/src/app/sign-in/sign-in.component.ts | 14 ++++++++++++++ 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/src/portal/src/app/sign-in/sign-in.component.html b/src/portal/src/app/sign-in/sign-in.component.html index 5258aa345..58413c95b 100644 --- a/src/portal/src/app/sign-in/sign-in.component.html +++ b/src/portal/src/app/sign-in/sign-in.component.html @@ -1,6 +1,6 @@ - + - \ No newline at end of file + + \ No newline at end of file diff --git a/src/portal/src/app/sign-in/sign-in.component.ts b/src/portal/src/app/sign-in/sign-in.component.ts index 764688439..2fcdcb567 100644 --- a/src/portal/src/app/sign-in/sign-in.component.ts +++ b/src/portal/src/app/sign-in/sign-in.component.ts @@ -29,6 +29,9 @@ import { User } from '../user/user'; import { CookieService, CookieOptions } from 'ngx-cookie'; import { SkinableConfig } from "../skinable-config.service"; +import {ModalEvent} from "../base/modal-event"; +import {modalEvents} from "../base/modal-events.const"; +import {AboutDialogComponent} from "../shared/about-dialog/about-dialog.component"; // Define status flags for signing in states export const signInStatusNormal = 0; @@ -57,6 +60,7 @@ export class SignInComponent implements AfterViewChecked, OnInit { @ViewChild('signInForm', {static: true}) currentForm: NgForm; @ViewChild('signupDialog', {static: false}) signUpDialog: SignUpComponent; @ViewChild('forgotPwdDialog', {static: false}) forgotPwdDialog: ForgotPasswordComponent; + @ViewChild(AboutDialogComponent, {static: false}) aboutDialog: AboutDialogComponent; // Status flag signInStatus: number = signInStatusNormal; @@ -283,6 +287,16 @@ export class SignInComponent implements AfterViewChecked, OnInit { this.forgotPwdDialog.open(); } + // Open modal dialog + openModal(event: ModalEvent): void { + switch (event.modalName) { + case modalEvents.ABOUT: + this.aboutDialog.open(); + break; + default: + break; + } + } }