프로필 오픈시 user seq 만으로 띄울수 있도록 수정.
This commit is contained in:
parent
4224b0682d
commit
777756ded8
@ -17,7 +17,7 @@ import {
|
|||||||
CreateChatDialogData,
|
CreateChatDialogData,
|
||||||
CreateChatDialogResult
|
CreateChatDialogResult
|
||||||
} from '@app/layouts/messenger/dialogs/chat/create-chat.dialog.component';
|
} from '@app/layouts/messenger/dialogs/chat/create-chat.dialog.component';
|
||||||
import { Subscription, of, Observable } from 'rxjs';
|
import { Subscription, Observable } from 'rxjs';
|
||||||
import { Store, select } from '@ngrx/store';
|
import { Store, select } from '@ngrx/store';
|
||||||
|
|
||||||
import * as AppStore from '@app/store';
|
import * as AppStore from '@app/store';
|
||||||
@ -35,9 +35,8 @@ import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
|||||||
import { OpenProfileOptions } from '@ucap-webmessenger/protocol-buddy';
|
import { OpenProfileOptions } from '@ucap-webmessenger/protocol-buddy';
|
||||||
import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
||||||
import { VersionInfo2Response } from '@ucap-webmessenger/api-public';
|
import { VersionInfo2Response } from '@ucap-webmessenger/api-public';
|
||||||
import { MessageApiService, MessageType } from '@ucap-webmessenger/api-message';
|
import { MessageType } from '@ucap-webmessenger/api-message';
|
||||||
import { DeviceType } from '@ucap-webmessenger/core';
|
import { tap } from 'rxjs/operators';
|
||||||
import { map, catchError, tap } from 'rxjs/operators';
|
|
||||||
import {
|
import {
|
||||||
MessageWriteDialogComponent,
|
MessageWriteDialogComponent,
|
||||||
MessageWriteDialogResult,
|
MessageWriteDialogResult,
|
||||||
@ -46,8 +45,7 @@ import {
|
|||||||
import {
|
import {
|
||||||
EnvironmentsInfo,
|
EnvironmentsInfo,
|
||||||
KEY_ENVIRONMENTS_INFO,
|
KEY_ENVIRONMENTS_INFO,
|
||||||
KEY_VER_INFO,
|
KEY_VER_INFO
|
||||||
KEY_LOGIN_RES_INFO
|
|
||||||
} from '@app/types';
|
} from '@app/types';
|
||||||
import { MessageBoxComponent } from './left-sidenav/message.component';
|
import { MessageBoxComponent } from './left-sidenav/message.component';
|
||||||
import { environment } from '../../../../environments/environment';
|
import { environment } from '../../../../environments/environment';
|
||||||
@ -70,7 +68,7 @@ export enum MainMenu {
|
|||||||
export class LeftSideComponent implements OnInit, OnDestroy {
|
export class LeftSideComponent implements OnInit, OnDestroy {
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<{
|
openProfile = new EventEmitter<{
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
userSeq: number;
|
||||||
openProfileOptions?: OpenProfileOptions;
|
openProfileOptions?: OpenProfileOptions;
|
||||||
}>();
|
}>();
|
||||||
@Output()
|
@Output()
|
||||||
@ -264,11 +262,11 @@ export class LeftSideComponent implements OnInit, OnDestroy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(params: {
|
onClickOpenProfile(params: {
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
userSeq: number;
|
||||||
openProfileOptions?: OpenProfileOptions;
|
openProfileOptions?: OpenProfileOptions;
|
||||||
}) {
|
}) {
|
||||||
this.openProfile.emit({
|
this.openProfile.emit({
|
||||||
userInfo: params.userInfo,
|
userSeq: params.userSeq,
|
||||||
openProfileOptions: params.openProfileOptions
|
openProfileOptions: params.openProfileOptions
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -86,7 +86,7 @@ export class GroupComponent implements OnInit, OnDestroy {
|
|||||||
newGroupAndMember = new EventEmitter();
|
newGroupAndMember = new EventEmitter();
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<{
|
openProfile = new EventEmitter<{
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
userSeq: number;
|
||||||
openProfileOptions?: OpenProfileOptions;
|
openProfileOptions?: OpenProfileOptions;
|
||||||
}>();
|
}>();
|
||||||
|
|
||||||
@ -432,7 +432,7 @@ export class GroupComponent implements OnInit, OnDestroy {
|
|||||||
switch (menuType) {
|
switch (menuType) {
|
||||||
case 'VIEW_PROFILE':
|
case 'VIEW_PROFILE':
|
||||||
this.openProfile.emit({
|
this.openProfile.emit({
|
||||||
userInfo,
|
userSeq: userInfo.seq,
|
||||||
openProfileOptions: {
|
openProfileOptions: {
|
||||||
useDelBuddybutton:
|
useDelBuddybutton:
|
||||||
!!group &&
|
!!group &&
|
||||||
@ -570,11 +570,11 @@ export class GroupComponent implements OnInit, OnDestroy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(
|
onClickOpenProfile(
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN,
|
userSeq: number,
|
||||||
group: GroupDetailData
|
group: GroupDetailData
|
||||||
) {
|
) {
|
||||||
this.openProfile.emit({
|
this.openProfile.emit({
|
||||||
userInfo,
|
userSeq,
|
||||||
openProfileOptions: {
|
openProfileOptions: {
|
||||||
useDelBuddybutton:
|
useDelBuddybutton:
|
||||||
!!group &&
|
!!group &&
|
||||||
|
@ -75,7 +75,6 @@ import {
|
|||||||
CommonApiService,
|
CommonApiService,
|
||||||
FileTalkSaveRequest,
|
FileTalkSaveRequest,
|
||||||
FileTalkSaveResponse,
|
FileTalkSaveResponse,
|
||||||
TranslationReqRequest,
|
|
||||||
TranslationSaveRequest,
|
TranslationSaveRequest,
|
||||||
TranslationSaveResponse
|
TranslationSaveResponse
|
||||||
} from '@ucap-webmessenger/api-common';
|
} from '@ucap-webmessenger/api-common';
|
||||||
@ -117,7 +116,9 @@ import {
|
|||||||
})
|
})
|
||||||
export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<{ userInfo: UserInfo }>();
|
openProfile = new EventEmitter<{
|
||||||
|
userSeq: number;
|
||||||
|
}>();
|
||||||
|
|
||||||
@ViewChild('chatForm', { static: false })
|
@ViewChild('chatForm', { static: false })
|
||||||
private chatForm: UCapUiChatFormComponent;
|
private chatForm: UCapUiChatFormComponent;
|
||||||
@ -1322,7 +1323,7 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(userInfo: UserInfo) {
|
onClickOpenProfile(userSeq: number) {
|
||||||
if (
|
if (
|
||||||
this.roomInfo.roomType !== RoomType.Allim &&
|
this.roomInfo.roomType !== RoomType.Allim &&
|
||||||
this.roomInfo.roomType !== RoomType.Bot &&
|
this.roomInfo.roomType !== RoomType.Bot &&
|
||||||
@ -1330,7 +1331,7 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
|||||||
this.roomInfo.roomType !== RoomType.Allim_Elephant &&
|
this.roomInfo.roomType !== RoomType.Allim_Elephant &&
|
||||||
this.roomInfo.roomType !== RoomType.Allim_TMS
|
this.roomInfo.roomType !== RoomType.Allim_TMS
|
||||||
) {
|
) {
|
||||||
this.openProfile.emit({ userInfo });
|
this.openProfile.emit({ userSeq });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,11 +1,5 @@
|
|||||||
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
|
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
|
||||||
import { RightDrawer } from '@app/types';
|
import { RightDrawer } from '@app/types';
|
||||||
import { UserInfo } from '@ucap-webmessenger/protocol-room';
|
|
||||||
import {
|
|
||||||
UserInfoSS,
|
|
||||||
UserInfoF,
|
|
||||||
UserInfoDN
|
|
||||||
} from '@ucap-webmessenger/protocol-query';
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-layout-messenger-right-drawer',
|
selector: 'app-layout-messenger-right-drawer',
|
||||||
@ -18,7 +12,7 @@ export class RightDrawerComponent implements OnInit {
|
|||||||
|
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<{
|
openProfile = new EventEmitter<{
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
userSeq: number;
|
||||||
}>();
|
}>();
|
||||||
@Output()
|
@Output()
|
||||||
closeRightDrawer = new EventEmitter();
|
closeRightDrawer = new EventEmitter();
|
||||||
@ -29,8 +23,8 @@ export class RightDrawerComponent implements OnInit {
|
|||||||
|
|
||||||
ngOnInit() {}
|
ngOnInit() {}
|
||||||
|
|
||||||
onClickOpenProfile(userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN) {
|
onClickOpenProfile(userSeq: number) {
|
||||||
this.openProfile.emit({ userInfo });
|
this.openProfile.emit({ userSeq });
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickClose() {
|
onClickClose() {
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
[presence]="getStatusBulkInfo(userInfo) | async"
|
[presence]="getStatusBulkInfo(userInfo) | async"
|
||||||
[sessionVerinfo]="sessionVerinfo"
|
[sessionVerinfo]="sessionVerinfo"
|
||||||
(contextmenu)="onContextMenuRoomUser($event, userInfo)"
|
(contextmenu)="onContextMenuRoomUser($event, userInfo)"
|
||||||
(openProfile)="onClickOpenProfile($event)"
|
(openProfile)="onClickOpenProfile(userInfo.seq)"
|
||||||
>
|
>
|
||||||
</ucap-profile-user-list-item>
|
</ucap-profile-user-list-item>
|
||||||
</div>
|
</div>
|
||||||
|
@ -49,7 +49,7 @@ import { MatMenuTrigger, MatDialog } from '@angular/material';
|
|||||||
})
|
})
|
||||||
export class RoomUserListComponent implements OnInit, OnDestroy {
|
export class RoomUserListComponent implements OnInit, OnDestroy {
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<UserInfo>();
|
openProfile = new EventEmitter<number>();
|
||||||
|
|
||||||
@ViewChild('roomUserContextMenuTrigger', { static: true })
|
@ViewChild('roomUserContextMenuTrigger', { static: true })
|
||||||
roomUserContextMenuTrigger: MatMenuTrigger;
|
roomUserContextMenuTrigger: MatMenuTrigger;
|
||||||
@ -131,8 +131,8 @@ export class RoomUserListComponent implements OnInit, OnDestroy {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(userInfo: UserInfo) {
|
onClickOpenProfile(userSeq: number) {
|
||||||
this.openProfile.emit(userInfo);
|
this.openProfile.emit(userSeq);
|
||||||
}
|
}
|
||||||
|
|
||||||
async onClickAddMember() {
|
async onClickAddMember() {
|
||||||
|
@ -16,12 +16,6 @@ import * as MessageStore from '@app/store/messenger/message';
|
|||||||
import { Observable, Subscription, of } from 'rxjs';
|
import { Observable, Subscription, of } from 'rxjs';
|
||||||
import { UCAP_NATIVE_SERVICE, NativeService } from '@ucap-webmessenger/native';
|
import { UCAP_NATIVE_SERVICE, NativeService } from '@ucap-webmessenger/native';
|
||||||
|
|
||||||
import { UserInfo } from '@ucap-webmessenger/protocol-sync';
|
|
||||||
import {
|
|
||||||
UserInfoSS,
|
|
||||||
UserInfoF,
|
|
||||||
UserInfoDN
|
|
||||||
} from '@ucap-webmessenger/protocol-query';
|
|
||||||
import { StatusProtocolService } from '@ucap-webmessenger/protocol-status';
|
import { StatusProtocolService } from '@ucap-webmessenger/protocol-status';
|
||||||
import { StatusType, StatusCode } from '@ucap-webmessenger/core';
|
import { StatusType, StatusCode } from '@ucap-webmessenger/core';
|
||||||
import {
|
import {
|
||||||
@ -211,14 +205,17 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(params: {
|
onClickOpenProfile(params: {
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
userSeq: number;
|
||||||
openProfileOptions?: OpenProfileOptions;
|
openProfileOptions?: OpenProfileOptions;
|
||||||
}) {
|
}) {
|
||||||
|
if (!params.userSeq || params.userSeq < 0) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
// [GROUP]
|
// [GROUP]
|
||||||
// this.queryProtocolService
|
// this.queryProtocolService
|
||||||
// .dataUser({
|
// .dataUser({
|
||||||
// divCd: 'OPENPROF',
|
// divCd: 'OPENPROF',
|
||||||
// seq: userInfo.seq,
|
// seq: params.userSeq,
|
||||||
// senderCompanyCode: this.loginRes.userInfo.companyCode,
|
// senderCompanyCode: this.loginRes.userInfo.companyCode,
|
||||||
// senderEmployeeType: this.loginRes.userInfo.employeeType
|
// senderEmployeeType: this.loginRes.userInfo.employeeType
|
||||||
// })
|
// })
|
||||||
@ -244,7 +241,7 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
|||||||
this.daesangProtocolService
|
this.daesangProtocolService
|
||||||
.dataUserDaesang({
|
.dataUserDaesang({
|
||||||
divCd: 'OPENPROF',
|
divCd: 'OPENPROF',
|
||||||
seq: params.userInfo.seq,
|
seq: params.userSeq,
|
||||||
senderCompanyCode: this.loginRes.userInfo.companyCode,
|
senderCompanyCode: this.loginRes.userInfo.companyCode,
|
||||||
senderEmployeeType: this.loginRes.userInfo.employeeType
|
senderEmployeeType: this.loginRes.userInfo.employeeType
|
||||||
})
|
})
|
||||||
|
@ -120,7 +120,7 @@
|
|||||||
[base]="profileImageRoot"
|
[base]="profileImageRoot"
|
||||||
[path]="getUserProfile(message.senderSeq)"
|
[path]="getUserProfile(message.senderSeq)"
|
||||||
[default]="'assets/images/img_nophoto_50.png'"
|
[default]="'assets/images/img_nophoto_50.png'"
|
||||||
(click)="onClickOpenProfile($event, getUerInfo(message.senderSeq))"
|
(click)="onClickOpenProfile($event, message.senderSeq)"
|
||||||
/>
|
/>
|
||||||
<!-- <ucap-ui-imaage
|
<!-- <ucap-ui-imaage
|
||||||
[style]="'width: 50px; height: 50px;'"
|
[style]="'width: 50px; height: 50px;'"
|
||||||
|
@ -54,7 +54,7 @@ export class MessagesComponent implements OnInit {
|
|||||||
translationSimpleview = false;
|
translationSimpleview = false;
|
||||||
|
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<UserInfo>();
|
openProfile = new EventEmitter<number>();
|
||||||
@Output()
|
@Output()
|
||||||
moreEvent = new EventEmitter<number>();
|
moreEvent = new EventEmitter<number>();
|
||||||
@Output()
|
@Output()
|
||||||
@ -120,18 +120,6 @@ export class MessagesComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
getUerInfo(seq: number): UserInfo {
|
|
||||||
if (!this.userInfos) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
const userInfo: UserInfo[] = this.userInfos.filter(
|
|
||||||
user => user.seq === seq
|
|
||||||
);
|
|
||||||
if (!!userInfo && userInfo.length > 0) {
|
|
||||||
return userInfo[0];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
getEventSearched(seq: number): boolean {
|
getEventSearched(seq: number): boolean {
|
||||||
return (
|
return (
|
||||||
!!this.searchedList &&
|
!!this.searchedList &&
|
||||||
@ -213,11 +201,11 @@ export class MessagesComponent implements OnInit {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(event: MouseEvent, userInfo: UserInfo) {
|
onClickOpenProfile(event: MouseEvent, userSeq: number) {
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
|
|
||||||
this.openProfile.emit(userInfo);
|
this.openProfile.emit(userSeq);
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickMore(event: any) {
|
onClickMore(event: any) {
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
[base]="profileImageRoot"
|
[base]="profileImageRoot"
|
||||||
[path]="userInfo.profileImageFile"
|
[path]="userInfo.profileImageFile"
|
||||||
[default]="'assets/images/img_nophoto_50.png'"
|
[default]="'assets/images/img_nophoto_50.png'"
|
||||||
(click)="onClickOpenProfile($event, userInfo)"
|
(click)="onClickOpenProfile($event, userInfo.seq)"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<span
|
<span
|
||||||
|
@ -52,9 +52,7 @@ export class UserListItemComponent implements OnInit {
|
|||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
||||||
}>();
|
}>();
|
||||||
@Output()
|
@Output()
|
||||||
openProfile = new EventEmitter<
|
openProfile = new EventEmitter<number>();
|
||||||
UserInfo | UserInfoSS | UserInfoF | UserInfoDN
|
|
||||||
>();
|
|
||||||
|
|
||||||
PresenceType = PresenceType;
|
PresenceType = PresenceType;
|
||||||
|
|
||||||
@ -108,13 +106,10 @@ export class UserListItemComponent implements OnInit {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(
|
onClickOpenProfile(event: MouseEvent, userSeq: number) {
|
||||||
event: MouseEvent,
|
|
||||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN
|
|
||||||
) {
|
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
|
|
||||||
this.openProfile.emit(userInfo);
|
this.openProfile.emit(userSeq);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user