diff --git a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.html b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.html index 77859748..8e632e65 100644 --- a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.html +++ b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.html @@ -9,39 +9,38 @@ group - - - - - - - + + + + + + device_hub - - - + chat - - - - + +
- choiced users +
diff --git a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.ts b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.ts index 73c120ef..93da2500 100644 --- a/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.ts +++ b/projects/ucap-webmessenger-app/src/app/layouts/messenger/dialogs/create-chat.dialog.component.ts @@ -20,7 +20,12 @@ import { RoomUserDetailData, RoomUserData } from '@ucap-webmessenger/protocol-sync'; -import { DeptSearchType } from '@ucap-webmessenger/protocol-query'; +import { + DeptSearchType, + UserInfoSS, + UserInfoF, + UserInfoDN +} from '@ucap-webmessenger/protocol-query'; import { RoomInfo, UserInfoShort, @@ -70,6 +75,9 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy { roomUserShortList: RoomUserData[]; roomSubscription: Subscription; + // 수집 데이터 + selectedUserList: (UserInfo | UserInfoSS | UserInfoF | UserInfoDN)[] = []; + ngOnInit() { const loginInfo = this.sessionStorageService.get(KEY_LOGIN_INFO); this.companyCode = loginInfo.companyCode; @@ -189,9 +197,25 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy { ); } + onCheckGroup(params: { isChecked: boolean; group: GroupDetailData }) { + this.logger.debug(params); + } + onCheckUser(params: { + isChecked: boolean; + userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN; + }) { + if (params.isChecked) { + this.selectedUserList.push(params.userInfo); + } else { + this.selectedUserList = this.selectedUserList.filter( + item => item.seq !== params.userInfo.seq + ); + } + } + onClickChoice(choice: boolean): void { - this.dialogRef.close({ - choice - }); + // this.dialogRef.close({ + // choice + // }); } } diff --git a/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.html b/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.html index 17a31394..061fd0ef 100644 --- a/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.html +++ b/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.html @@ -28,7 +28,8 @@ (click)="onClickMore($event, groupBuddy.group)"> more_vert - + diff --git a/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.ts b/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.ts index 82d56061..8c021912 100644 --- a/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.ts +++ b/projects/ucap-webmessenger-ui-group/src/lib/components/expansion-panel.component.ts @@ -37,6 +37,12 @@ export class ExpansionPanelComponent implements OnInit { group: GroupDetailData; }>(); + @Output() + checkGroup = new EventEmitter<{ + isChecked: boolean; + group: GroupDetailData; + }>(); + @ContentChild(ExpansionPanelItemDirective, { read: TemplateRef, static: true @@ -60,4 +66,11 @@ export class ExpansionPanelComponent implements OnInit { onClickMore(event: MouseEvent, group: GroupDetailData) { this.more.emit({ event, group }); } + + onChangeCheck(value: boolean, group: GroupDetailData) { + this.checkGroup.emit({ + isChecked: value, + group + }); + } } diff --git a/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.html b/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.html index 51e1c876..72e92c65 100644 --- a/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.html +++ b/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.html @@ -33,5 +33,7 @@ - + + diff --git a/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.ts b/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.ts index b2acbc60..05a5fdca 100644 --- a/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.ts +++ b/projects/ucap-webmessenger-ui-profile/src/lib/components/user-list-item.component.ts @@ -23,6 +23,7 @@ import { StatusCode } from '@ucap-webmessenger/core'; import { PresenceType } from '../types/presence-type.type'; import { VersionInfo2Response } from '@ucap-webmessenger/api-public'; +import { MatCheckboxChange, MatPseudoCheckbox } from '@angular/material'; @Component({ selector: 'ucap-profile-user-list-item', @@ -42,12 +43,19 @@ export class UserListItemComponent implements OnInit, OnDestroy { @Input() checkable = false; @Input() + isChecked = false; + @Input() compactable = false; @Input() sessionVerinfo: VersionInfo2Response; - userPresence: StatusBulkInfo | StatusInfo; + @Output() + checkUser = new EventEmitter<{ + isChecked: boolean; + userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN; + }>(); + userPresence: StatusBulkInfo | StatusInfo; PresenceType = PresenceType; // private profileImageRootSubscription: Subscription; @@ -106,4 +114,14 @@ export class UserListItemComponent implements OnInit, OnDestroy { return rtnClass; } + + onChangeCheck( + value: boolean, + userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN + ) { + this.checkUser.emit({ + isChecked: value, + userInfo + }); + } }