This commit is contained in:
richard-loafle 2020-01-23 14:15:18 +09:00
commit 5fc468c7c2

View File

@ -6,7 +6,8 @@ import {
EventEmitter,
Input,
ViewChild,
AfterViewChecked
AfterViewChecked,
ChangeDetectorRef
} from '@angular/core';
import { ucapAnimations, DialogService } from '@ucap-webmessenger/ui';
import { Observable, Subscription, of } from 'rxjs';
@ -158,6 +159,7 @@ export class OrganizationComponent
private queryProtocolService: QueryProtocolService,
private dialogService: DialogService,
private translateService: TranslateService,
private changeDetectorRef: ChangeDetectorRef,
private logger: NGXLogger
) {
this.loginInfo = this.sessionStorageService.get<LoginInfo>(KEY_LOGIN_INFO);
@ -374,11 +376,13 @@ export class OrganizationComponent
if (
!compareList ||
compareList.length === 0 ||
compareList.filter(
compareList
.filter(item => item.seq !== this.loginRes.userSeq)
.filter(
item =>
!(
this.selectedUserList.filter(user => user.seq === item.seq).length >
0
this.selectedUserList.filter(user => user.seq === item.seq)
.length > 0
)
).length > 0
) {
@ -418,6 +422,8 @@ export class OrganizationComponent
: this.selectedDepartmentUserInfoList
).filter(user => user.seq !== this.loginRes.userSeq)
});
this.changeDetectorRef.detectChanges();
}
/** 리스트가 checkable 할 경우 checkbox 의 change 이벤트를 상위 컴포넌트로 전달한다. */
@ -507,10 +513,22 @@ export class OrganizationComponent
const seq: number[] = [];
this.selectedUserList.map(user => seq.push(user.seq));
this.store.dispatch(ChatStore.openRoom({ userSeqList: seq }));
// 상위 컴포넌트의 selectedUserList clear.
this.checkAllUser.emit({
isChecked: false,
userInfos: this.selectedUserList
});
}
}
onClickConference() {
this.logger.debug('onClickConference', this.selectedUserList);
// 상위 컴포넌트의 selectedUserList clear.
this.checkAllUser.emit({
isChecked: false,
userInfos: this.selectedUserList
});
}
onContextMenuOrgUser(