From 069b3e6e67fdcb87963a07b5dd3a8ba2a01ff4bf Mon Sep 17 00:00:00 2001 From: leejinho Date: Tue, 17 Mar 2020 10:35:59 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9C=A0=EC=A0=80=EC=84=A0=ED=83=9D=ED=8C=9D?= =?UTF-8?q?=EC=97=85=20>=20=EC=83=88=EB=A1=9C=EC=9A=B4=20=EB=8C=80?= =?UTF-8?q?=ED=99=94=20=EA=B0=9C=EC=84=A4=EC=8B=9C=20300=EB=AA=85=20?= =?UTF-8?q?=EC=A0=9C=ED=95=9C=20=EB=A1=9C=EC=A7=81=20=EC=B6=94=EA=B0=80.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../chat/create-chat.dialog.component.html | 48 +++++++++++++++++-- .../chat/create-chat.dialog.component.ts | 7 ++- 2 files changed, 50 insertions(+), 5 deletions(-) diff --git a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.html b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.html index d16c2637..98d7fe83 100644 --- a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.html +++ b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.html @@ -262,8 +262,48 @@ - - {{ selectedUserList.length }} - {{ 'common.units.persons' | translate }} - + + + + {{ selectedUserList.length }} / + {{ environment.productConfig.CommonSetting.maxChatRoomUser - 1 }} + {{ 'common.units.persons' | translate }} + + + ({{ + 'chat.errors.maxCountOfRoomMemberWith' + | translate + : { + maxCount: + environment.productConfig.CommonSetting.maxChatRoomUser - 1 + } + }}) + + + + + {{ selectedUserList.length }} + {{ 'common.units.persons' | translate }} + + diff --git a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.ts b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.ts index 53891855..58ceec7b 100644 --- a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.ts +++ b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/chat/create-chat.dialog.component.ts @@ -134,6 +134,7 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy { currentTabIndex: number; UserSelectDialogType = UserSelectDialogType; + environment = environment; loginRes: LoginResponse; loginResSubscription: Subscription; @@ -740,8 +741,12 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy { if (this.selectedUserList.length === 0 && !this.selectedRoom) { return true; } - return false; + } else if (this.data.type === UserSelectDialogType.NewChat) { + return ( + this.selectedUserList.length >= + this.environment.productConfig.CommonSetting.maxChatRoomUser + ); } else { return false; }