[이슈처리 5] MyTalk 에서 unread count 보이는 문제 수정. #2

This commit is contained in:
leejinho 2019-11-22 09:17:47 +09:00
parent c7f6222c58
commit 729a95e1eb
2 changed files with 16 additions and 7 deletions

View File

@ -171,11 +171,7 @@
[userInfos]="userInfoList"
[loginRes]="loginRes"
[sessionVerInfo]="sessionVerInfo"
[isShowUnreadCount]="
roomInfo.roomType !== RoomType.Mytalk &&
roomInfo.roomType !== RoomType.Bot &&
roomInfo.roomType !== RoomType.Allim
"
[isShowUnreadCount]="getShowUnreadCount()"
(moreEvent)="onMoreEvent($event)"
(massDetail)="onMassDetail($event)"
(save)="onSave($event)"

View File

@ -151,8 +151,6 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
snackBarPreviewEvent: MatSnackBarRef<SimpleSnackBar>;
RoomType = RoomType;
constructor(
private store: Store<any>,
private sessionStorageService: SessionStorageService,
@ -355,6 +353,21 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
return true;
}
getShowUnreadCount(): boolean {
if (!this.roomInfo || this.roomInfo === undefined) {
return true;
}
if (
this.roomInfo.roomType === RoomType.Mytalk ||
this.roomInfo.roomType === RoomType.Bot ||
this.roomInfo.roomType === RoomType.Allim
) {
return false;
}
return true;
}
readyToReply(): void {
setTimeout(() => {
this.focusReplyInput();