1. 즐겨찾기 > 프로필 오픈 > 동료삭제시 '소속부서'그룹에서도 삭제되는 문제 수정.
2. 소속부서 인원들은 타 그룹에서 프로필을 오픈한 것 이외에 다른곳에서 프로필 오픈시 동료 추가삭제 버튼 표현하지 않도록 수정.
This commit is contained in:
parent
4d303df05a
commit
dbdc164e0f
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "ucap-webmessenger",
|
"name": "ucap-webmessenger",
|
||||||
"version": "0.0.4",
|
"version": "0.0.5",
|
||||||
"author": {
|
"author": {
|
||||||
"name": "LG CNS",
|
"name": "LG CNS",
|
||||||
"email": "lgucap@lgcns.com"
|
"email": "lgucap@lgcns.com"
|
||||||
|
|
|
@ -481,16 +481,18 @@ export class GroupComponent implements OnInit, OnDestroy {
|
||||||
);
|
);
|
||||||
switch (menuType) {
|
switch (menuType) {
|
||||||
case 'VIEW_PROFILE':
|
case 'VIEW_PROFILE':
|
||||||
|
let useBuddyButton = false;
|
||||||
|
if (
|
||||||
|
!!group &&
|
||||||
|
environment.productConfig.CommonSetting.useMyDeptGroup &&
|
||||||
|
environment.productConfig.CommonSetting.myDeptGroupSeq !== group.seq
|
||||||
|
) {
|
||||||
|
useBuddyButton = true;
|
||||||
|
}
|
||||||
this.openProfile.emit({
|
this.openProfile.emit({
|
||||||
userSeq: userInfo.seq,
|
userSeq: userInfo.seq,
|
||||||
openProfileOptions: {
|
openProfileOptions: {
|
||||||
useDelBuddybutton:
|
useBuddyButton
|
||||||
!!group &&
|
|
||||||
environment.productConfig.CommonSetting.useMyDeptGroup &&
|
|
||||||
environment.productConfig.CommonSetting.myDeptGroupSeq ===
|
|
||||||
group.seq
|
|
||||||
? false
|
|
||||||
: true
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
|
@ -628,15 +630,19 @@ export class GroupComponent implements OnInit, OnDestroy {
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickOpenProfile(userSeq: number, group: GroupDetailData) {
|
onClickOpenProfile(userSeq: number, group: GroupDetailData) {
|
||||||
|
let useBuddyButton = false;
|
||||||
|
if (
|
||||||
|
!!group &&
|
||||||
|
environment.productConfig.CommonSetting.useMyDeptGroup &&
|
||||||
|
environment.productConfig.CommonSetting.myDeptGroupSeq !== group.seq
|
||||||
|
) {
|
||||||
|
useBuddyButton = true;
|
||||||
|
}
|
||||||
|
|
||||||
this.openProfile.emit({
|
this.openProfile.emit({
|
||||||
userSeq,
|
userSeq,
|
||||||
openProfileOptions: {
|
openProfileOptions: {
|
||||||
useDelBuddybutton:
|
useBuddyButton
|
||||||
!!group &&
|
|
||||||
environment.productConfig.CommonSetting.useMyDeptGroup &&
|
|
||||||
environment.productConfig.CommonSetting.myDeptGroupSeq === group.seq
|
|
||||||
? false
|
|
||||||
: true
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
[isBuddy]="isBuddy"
|
[isBuddy]="isBuddy"
|
||||||
[isFavorit]="isFavorit"
|
[isFavorit]="isFavorit"
|
||||||
[openProfileOptions]="data.openProfileOptions"
|
[openProfileOptions]="data.openProfileOptions"
|
||||||
|
[useBuddyToggleButton]="useBuddyToggleButton"
|
||||||
[authInfo]="authInfo"
|
[authInfo]="authInfo"
|
||||||
(openChat)="onClickChat($event)"
|
(openChat)="onClickChat($event)"
|
||||||
(sendMessage)="onClickSendMessage($event)"
|
(sendMessage)="onClickSendMessage($event)"
|
||||||
|
|
|
@ -78,8 +78,10 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||||
isBuddy: boolean;
|
isBuddy: boolean;
|
||||||
isFavorit: boolean;
|
isFavorit: boolean;
|
||||||
editableProfileImage: boolean;
|
editableProfileImage: boolean;
|
||||||
|
useBuddyToggleButton: boolean;
|
||||||
|
|
||||||
selectAllBuddy2Subscription: Subscription;
|
selectAllBuddy2Subscription: Subscription;
|
||||||
|
myDeptUserListSubscription: Subscription;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
public dialogRef: MatDialogRef<ProfileDialogData, ProfileDialogResult>,
|
public dialogRef: MatDialogRef<ProfileDialogData, ProfileDialogResult>,
|
||||||
|
@ -128,12 +130,37 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||||
})
|
})
|
||||||
)
|
)
|
||||||
.subscribe();
|
.subscribe();
|
||||||
|
|
||||||
|
if (!!this.data.openProfileOptions) {
|
||||||
|
this.useBuddyToggleButton = !!this.data.openProfileOptions.useBuddyButton;
|
||||||
|
} else {
|
||||||
|
this.getCheckMyDeptUser();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnDestroy(): void {
|
ngOnDestroy(): void {
|
||||||
if (!!this.selectAllBuddy2Subscription) {
|
if (!!this.selectAllBuddy2Subscription) {
|
||||||
this.selectAllBuddy2Subscription.unsubscribe();
|
this.selectAllBuddy2Subscription.unsubscribe();
|
||||||
}
|
}
|
||||||
|
if (!!this.myDeptUserListSubscription) {
|
||||||
|
this.myDeptUserListSubscription.unsubscribe();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
getCheckMyDeptUser() {
|
||||||
|
this.myDeptUserListSubscription = this.store
|
||||||
|
.pipe(
|
||||||
|
select(
|
||||||
|
AppStore.MessengerSelector.QuerySelector.myDepartmentUserInfoList
|
||||||
|
),
|
||||||
|
map(myDeptUserList => {
|
||||||
|
const users = myDeptUserList.filter(
|
||||||
|
buddy => buddy.seq === this.data.userInfo.seq
|
||||||
|
);
|
||||||
|
this.useBuddyToggleButton = users.length === 0;
|
||||||
|
})
|
||||||
|
)
|
||||||
|
.subscribe();
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickChat(userInfo: UserInfoSS) {
|
onClickChat(userInfo: UserInfoSS) {
|
||||||
|
@ -339,6 +366,8 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||||
SyncStore.delBuddyAndClear({ seq: param.userInfo.seq })
|
SyncStore.delBuddyAndClear({ seq: param.userInfo.seq })
|
||||||
);
|
);
|
||||||
this.isBuddy = false;
|
this.isBuddy = false;
|
||||||
|
|
||||||
|
this.getCheckMyDeptUser();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1015,8 +1015,9 @@ export class Effects {
|
||||||
// 소속부서(내부서) 고정그룹 사용시 소속부서원을 삭제하지 않는다.
|
// 소속부서(내부서) 고정그룹 사용시 소속부서원을 삭제하지 않는다.
|
||||||
if (
|
if (
|
||||||
environment.productConfig.CommonSetting.useMyDeptGroup &&
|
environment.productConfig.CommonSetting.useMyDeptGroup &&
|
||||||
myDeptUserList.filter(deptUser => deptUser.seq === group.seq)
|
environment.productConfig.CommonSetting.fixedGroupSeqs.filter(
|
||||||
.length > 0
|
fixedGroupSeq => fixedGroupSeq === group.seq
|
||||||
|
).length > 0
|
||||||
) {
|
) {
|
||||||
// skip;;
|
// skip;;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -199,6 +199,9 @@
|
||||||
"notificationIsOn": "Notification is on",
|
"notificationIsOn": "Notification is on",
|
||||||
"notificationIsOff": "Notification is off",
|
"notificationIsOff": "Notification is off",
|
||||||
"typeMessage": "Type your message.",
|
"typeMessage": "Type your message.",
|
||||||
|
"btnAttachFile": "Attach files",
|
||||||
|
"btnSticker": "Sticker",
|
||||||
|
"btnTranslate": "Translate",
|
||||||
"event": {
|
"event": {
|
||||||
"inviteToRoomWith": "{{owner}} invited {{inviter}}.",
|
"inviteToRoomWith": "{{owner}} invited {{inviter}}.",
|
||||||
"exitFromRoomWith": "{{exitor}} has left.",
|
"exitFromRoomWith": "{{exitor}} has left.",
|
||||||
|
|
|
@ -199,6 +199,9 @@
|
||||||
"notificationIsOn": "알림 켜짐",
|
"notificationIsOn": "알림 켜짐",
|
||||||
"notificationIsOff": "알림 꺼짐",
|
"notificationIsOff": "알림 꺼짐",
|
||||||
"typeMessage": "대화를 입력하세요.",
|
"typeMessage": "대화를 입력하세요.",
|
||||||
|
"btnAttachFile": "첨부파일",
|
||||||
|
"btnSticker": "스티커",
|
||||||
|
"btnTranslate": "번역",
|
||||||
"event": {
|
"event": {
|
||||||
"inviteToRoomWith": "{{owner}}이 {{inviter}}을 초대했습니다.",
|
"inviteToRoomWith": "{{owner}}이 {{inviter}}을 초대했습니다.",
|
||||||
"exitFromRoomWith": "{{exitor}}님이 퇴장하셨습니다.",
|
"exitFromRoomWith": "{{exitor}}님이 퇴장하셨습니다.",
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
export interface OpenProfileOptions {
|
export interface OpenProfileOptions {
|
||||||
useDelBuddybutton?: boolean;
|
useBuddyButton?: boolean;
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,7 +5,12 @@
|
||||||
fxLayoutAlign="center center"
|
fxLayoutAlign="center center"
|
||||||
>
|
>
|
||||||
<div class="add-option">
|
<div class="add-option">
|
||||||
<button mat-icon-button class="material-icons" (click)="onClickFileInput()">
|
<button
|
||||||
|
mat-icon-button
|
||||||
|
class="material-icons"
|
||||||
|
(click)="onClickFileInput()"
|
||||||
|
matTooltip="{{ 'chat.btnAttachFile' | translate }}"
|
||||||
|
>
|
||||||
<mat-icon>attach_file</mat-icon>
|
<mat-icon>attach_file</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
<input
|
<input
|
||||||
|
@ -20,6 +25,7 @@
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
class="material-icons"
|
class="material-icons"
|
||||||
(click)="onClickStickerSelector()"
|
(click)="onClickStickerSelector()"
|
||||||
|
matTooltip="{{ 'chat.btnSticker' | translate }}"
|
||||||
>
|
>
|
||||||
<mat-icon>sentiment_satisfied_alt</mat-icon>
|
<mat-icon>sentiment_satisfied_alt</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
|
@ -28,6 +34,7 @@
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
class="material-icons"
|
class="material-icons"
|
||||||
(click)="onClickTranslation()"
|
(click)="onClickTranslation()"
|
||||||
|
matTooltip="{{ 'chat.btnTranslate' | translate }}"
|
||||||
>
|
>
|
||||||
<mat-icon>g_translate</mat-icon>
|
<mat-icon>g_translate</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
|
|
|
@ -34,6 +34,7 @@ import { VideoConferenceComponent as MBVideoConferenceComponent } from './compon
|
||||||
import { AllimComponent as MBAllimComponent } from './components/message-box/allim.component';
|
import { AllimComponent as MBAllimComponent } from './components/message-box/allim.component';
|
||||||
import { SearchComponent } from './components/search.component';
|
import { SearchComponent } from './components/search.component';
|
||||||
import { TranslateModule } from '@ngx-translate/core';
|
import { TranslateModule } from '@ngx-translate/core';
|
||||||
|
import { MatTooltipModule } from '@angular/material';
|
||||||
|
|
||||||
const COMPONENTS = [
|
const COMPONENTS = [
|
||||||
FormComponent,
|
FormComponent,
|
||||||
|
@ -72,6 +73,7 @@ const PROVIDERS = [DatePipe];
|
||||||
MatInputModule,
|
MatInputModule,
|
||||||
MatButtonModule,
|
MatButtonModule,
|
||||||
MatMenuModule,
|
MatMenuModule,
|
||||||
|
MatTooltipModule,
|
||||||
|
|
||||||
TranslateModule,
|
TranslateModule,
|
||||||
|
|
||||||
|
|
|
@ -98,7 +98,7 @@
|
||||||
stroke-linecap="butt"
|
stroke-linecap="butt"
|
||||||
stroke-linejoin="round"
|
stroke-linejoin="round"
|
||||||
class="on"
|
class="on"
|
||||||
*ngIf="!isBuddy"
|
*ngIf="getShowBuddyToggleBtn('ADD')"
|
||||||
(click)="onClickAddBuddy()"
|
(click)="onClickAddBuddy()"
|
||||||
matTooltip="{{ 'profile.addBuddy' | translate }}"
|
matTooltip="{{ 'profile.addBuddy' | translate }}"
|
||||||
>
|
>
|
||||||
|
@ -120,7 +120,7 @@
|
||||||
stroke-linecap="butt"
|
stroke-linecap="butt"
|
||||||
stroke-linejoin="round"
|
stroke-linejoin="round"
|
||||||
class="on"
|
class="on"
|
||||||
*ngIf="getShowBuddyDelBtn()"
|
*ngIf="getShowBuddyToggleBtn('DEL')"
|
||||||
(click)="onClickDelBuddy()"
|
(click)="onClickDelBuddy()"
|
||||||
matTooltip="{{ 'profile.removeBuddy' | translate }}"
|
matTooltip="{{ 'profile.removeBuddy' | translate }}"
|
||||||
>
|
>
|
||||||
|
|
|
@ -41,6 +41,8 @@ export class ProfileComponent implements OnInit {
|
||||||
@Input()
|
@Input()
|
||||||
openProfileOptions?: OpenProfileOptions;
|
openProfileOptions?: OpenProfileOptions;
|
||||||
@Input()
|
@Input()
|
||||||
|
useBuddyToggleButton: boolean;
|
||||||
|
@Input()
|
||||||
authInfo: AuthResponse;
|
authInfo: AuthResponse;
|
||||||
|
|
||||||
@Output()
|
@Output()
|
||||||
|
@ -225,18 +227,21 @@ export class ProfileComponent implements OnInit {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
getShowBuddyDelBtn(): boolean {
|
getShowBuddyToggleBtn(type: 'DEL' | 'ADD'): boolean {
|
||||||
|
let rtn = false;
|
||||||
|
if (!this.useBuddyToggleButton) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (type === 'ADD') {
|
||||||
|
if (!this.isBuddy) {
|
||||||
|
rtn = true;
|
||||||
|
}
|
||||||
|
} else if (type === 'DEL') {
|
||||||
if (!!this.isBuddy) {
|
if (!!this.isBuddy) {
|
||||||
if (
|
rtn = true;
|
||||||
!!this.openProfileOptions &&
|
|
||||||
!this.openProfileOptions.useDelBuddybutton
|
|
||||||
) {
|
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
return rtn;
|
||||||
return false;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user