From 265305b7fc66f626e5517c002440654e482daf1b Mon Sep 17 00:00:00 2001 From: Park Byung Eun Date: Fri, 26 Aug 2022 07:55:12 +0000 Subject: [PATCH] bug fix --- src/app/modules/beteran/component/home.component.ts | 10 +++++++++- .../compose/compose/sign-in-compose.component.ts | 2 ++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/app/modules/beteran/component/home.component.ts b/src/app/modules/beteran/component/home.component.ts index b5c9672..7c45a52 100644 --- a/src/app/modules/beteran/component/home.component.ts +++ b/src/app/modules/beteran/component/home.component.ts @@ -245,13 +245,21 @@ export class HomeComponent implements OnInit { __onClickCompose(composeMenuType: ComposeMenuType): void { let selectType: any; + if ( + !this.loggedIn && + composeMenuType !== ComposeMenuType.signIn && + composeMenuType !== ComposeMenuType.signup + ) { + alert('로그인 후 이용해주세요.'); + return; + } switch (composeMenuType) { case ComposeMenuType.signOut: // selectType = SignInComposeComponent; return; break; case ComposeMenuType.signIn: - selectType = SignUpComposeComponent; + selectType = SignInComposeComponent; break; case ComposeMenuType.signup: selectType = SignUpComposeComponent; diff --git a/src/app/modules/beteran/compose/compose/sign-in-compose.component.ts b/src/app/modules/beteran/compose/compose/sign-in-compose.component.ts index 42564ad..501fc35 100644 --- a/src/app/modules/beteran/compose/compose/sign-in-compose.component.ts +++ b/src/app/modules/beteran/compose/compose/sign-in-compose.component.ts @@ -1,6 +1,7 @@ import { Component, OnInit, ViewEncapsulation } from '@angular/core'; import { FormBuilder, FormGroup, Validators } from '@angular/forms'; import { MatDialogRef } from '@angular/material/dialog'; +import { fuseAnimations } from '@fuse/animations'; import { FuseAlertType } from '@fuse/components/alert'; import { AuthService } from 'app/core/auth/auth.service'; @@ -8,6 +9,7 @@ import { AuthService } from 'app/core/auth/auth.service'; selector: 'sign-in-compose', templateUrl: './sign-in-compose.component.html', encapsulation: ViewEncapsulation.None, + animations: fuseAnimations, }) export class SignInComposeComponent implements OnInit { signInComposeForm!: FormGroup;