Merge branch 'master' of http://10.81.13.221:6990/Web/next-ucap-messenger
This commit is contained in:
commit
746a5f2a5c
|
@ -166,6 +166,7 @@ function createTray() {
|
||||||
// accelerator: 'Q',
|
// accelerator: 'Q',
|
||||||
// selector: 'terminate:',
|
// selector: 'terminate:',
|
||||||
click: () => {
|
click: () => {
|
||||||
|
appWindow.show();
|
||||||
appWindow.browserWindow.webContents.send(MessengerChannel.Logout);
|
appWindow.browserWindow.webContents.send(MessengerChannel.Logout);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -109,9 +109,8 @@
|
||||||
</ng-template>
|
</ng-template>
|
||||||
</mat-tab>
|
</mat-tab>
|
||||||
|
|
||||||
<mat-tab [aria-label]="MainMenu.Call">
|
<!-- <mat-tab [aria-label]="MainMenu.Call">
|
||||||
<ng-template mat-tab-label>
|
<ng-template mat-tab-label>
|
||||||
<!--<mat-icon>phone</mat-icon>-->
|
|
||||||
<div class="icon-item" matTooltip="Call" matTooltipPosition="after">
|
<div class="icon-item" matTooltip="Call" matTooltipPosition="after">
|
||||||
<svg
|
<svg
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
@ -137,7 +136,7 @@
|
||||||
</svg>
|
</svg>
|
||||||
</div>
|
</div>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
</mat-tab>
|
</mat-tab> -->
|
||||||
</mat-tab-group>
|
</mat-tab-group>
|
||||||
|
|
||||||
<ucap-profile-my-profile-widget
|
<ucap-profile-my-profile-widget
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
<!--<mat-card class="confirm-card mat-elevation-z">
|
<mat-card class="confirm-card mat-elevation-z">
|
||||||
<mat-card-header cdkDrag cdkDragRootElement=".cdk-overlay-pane" cdkDragHandle>
|
<mat-card-header cdkDrag cdkDragRootElement=".cdk-overlay-pane" cdkDragHandle>
|
||||||
<mat-card-title>{{ data.title }}</mat-card-title>
|
<mat-card-title>{{ data.title }}</mat-card-title>
|
||||||
</mat-card-header>
|
</mat-card-header>
|
||||||
|
@ -29,100 +29,3 @@
|
||||||
</button>
|
</button>
|
||||||
</mat-card-actions>
|
</mat-card-actions>
|
||||||
</mat-card>
|
</mat-card>
|
||||||
-->
|
|
||||||
<mat-card class="confirm-card mat-elevation-z setting-frame">
|
|
||||||
<mat-card-header cdkDrag cdkDragRootElement=".cdk-overlay-pane" cdkDragHandle>
|
|
||||||
<mat-card-title>설정</mat-card-title>
|
|
||||||
</mat-card-header>
|
|
||||||
<mat-card-content>
|
|
||||||
<div fxFlex class="setting-tab">
|
|
||||||
<mat-tab-group animationDuration="0ms" vertical>
|
|
||||||
<mat-tab>
|
|
||||||
<ng-template mat-tab-label>
|
|
||||||
<span class="mdi mdi-settings"></span>
|
|
||||||
일반
|
|
||||||
</ng-template>
|
|
||||||
<ucap-settings-general class="setting-category general"></ucap-settings-general>
|
|
||||||
</mat-tab>
|
|
||||||
<mat-tab>
|
|
||||||
<ng-template mat-tab-label>
|
|
||||||
<span class="mdi mdi-lock"></span>
|
|
||||||
개인정보취급방침
|
|
||||||
</ng-template>
|
|
||||||
<ucap-settings-privacy class="setting-category"></ucap-settings-privacy>
|
|
||||||
</mat-tab>
|
|
||||||
<mat-tab>
|
|
||||||
<ng-template mat-tab-label>
|
|
||||||
<span class="mdi mdi-bell"></span>
|
|
||||||
알림
|
|
||||||
</ng-template>
|
|
||||||
<ucap-settings-notification class="setting-category"></ucap-settings-notification>
|
|
||||||
</mat-tab>
|
|
||||||
<mat-tab>
|
|
||||||
<ng-template mat-tab-label>
|
|
||||||
<span class="mdi mdi-headset"></span>
|
|
||||||
장치
|
|
||||||
</ng-template>
|
|
||||||
<ucap-settings-device class="setting-category"></ucap-settings-device>
|
|
||||||
</mat-tab>
|
|
||||||
<mat-tab>
|
|
||||||
<ng-template mat-tab-label>
|
|
||||||
<span class="mdi mdi-view-grid-plus"></span>
|
|
||||||
사용권한
|
|
||||||
</ng-template>
|
|
||||||
<ucap-settings-permission class="setting-category"></ucap-settings-permission>
|
|
||||||
</mat-tab>
|
|
||||||
<mat-tab>
|
|
||||||
<ng-template mat-tab-label>
|
|
||||||
<span class="mdi mdi-phone"></span>
|
|
||||||
통화
|
|
||||||
</ng-template>
|
|
||||||
<ucap-settings-call class="setting-category"></ucap-settings-call>
|
|
||||||
</mat-tab>
|
|
||||||
</mat-tab-group>
|
|
||||||
|
|
||||||
<!-- <div class="left-side-tabs-body">
|
|
||||||
<div
|
|
||||||
#tabs
|
|
||||||
id="tabs-0"
|
|
||||||
class="left-side-tabs-contents"
|
|
||||||
style="display: block;"
|
|
||||||
>
|
|
||||||
ddddd
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
#tabs
|
|
||||||
id="tabs-1"
|
|
||||||
class="left-side-tabs-contents"
|
|
||||||
style="display: none;"
|
|
||||||
>
|
|
||||||
dddagadsfgadsf
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
#tabs
|
|
||||||
id="tabs-2"
|
|
||||||
class="left-side-tabs-contents"
|
|
||||||
style="display: none;"
|
|
||||||
>
|
|
||||||
fbkasfldsafkskdf
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
#tabs
|
|
||||||
id="tabs-3"
|
|
||||||
class="left-side-tabs-contents"
|
|
||||||
style="display: none;"
|
|
||||||
>
|
|
||||||
rgkdsfgkdfglkdsflgs
|
|
||||||
</div>
|
|
||||||
</div> -->
|
|
||||||
</div>
|
|
||||||
</mat-card-content>
|
|
||||||
<mat-card-actions class="button-farm flex-row">
|
|
||||||
<button mat-stroked-button (click)="onClickChoice(false)" class="mat-primary">
|
|
||||||
No
|
|
||||||
</button>
|
|
||||||
<button mat-flat-button (click)="onClickChoice(true)" class="mat-primary">
|
|
||||||
Yes
|
|
||||||
</button>
|
|
||||||
</mat-card-actions>
|
|
||||||
</mat-card>
|
|
|
@ -1,4 +1,4 @@
|
||||||
/*::ng-deep .mat-card-header-tex{
|
::ng-deep .mat-card-header-tex{
|
||||||
margin:0;
|
margin:0;
|
||||||
}
|
}
|
||||||
.confirm-card{
|
.confirm-card{
|
||||||
|
@ -23,108 +23,4 @@ form{
|
||||||
.mat-form-field{
|
.mat-form-field{
|
||||||
width:100%;
|
width:100%;
|
||||||
}
|
}
|
||||||
}*/
|
|
||||||
|
|
||||||
|
|
||||||
::ng-deep .cdk-overlay-pane {
|
|
||||||
width: 600px;
|
|
||||||
max-height: 90%;
|
|
||||||
height:800px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::ng-deep .setting-frame{
|
|
||||||
padding: 16px;
|
|
||||||
height:100%;
|
|
||||||
min-width: 500px;
|
|
||||||
position: relative;
|
|
||||||
|
|
||||||
.mat-dialog-container {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mat-card-header {
|
|
||||||
position: relative;
|
|
||||||
width: 100%;
|
|
||||||
border-bottom:1px solid #dddddd;
|
|
||||||
margin-bottom: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.mat-card-content {
|
|
||||||
flex: 0 0 auto;
|
|
||||||
display: flex;
|
|
||||||
align-items: flex-start;
|
|
||||||
height: calc(100% - 100px);
|
|
||||||
border-bottom:1px solid #dddddd;
|
|
||||||
.setting-tab{
|
|
||||||
position: relative;
|
|
||||||
width:100%;
|
|
||||||
height:100%;
|
|
||||||
.mat-tab-body-wrapper{
|
|
||||||
border-left:1px solid #dddddd;
|
|
||||||
position: relative;
|
|
||||||
height:100%;
|
|
||||||
padding: 0 0 10px 10px;
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.button-farm {
|
|
||||||
text-align: right;
|
|
||||||
position: absolute;
|
|
||||||
width: 100%;
|
|
||||||
bottom: 10px;
|
|
||||||
.mat-primary {
|
|
||||||
margin-left: 4px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
::ng-deep .setting-tab{
|
|
||||||
.mat-tab-group{
|
|
||||||
position: relative;
|
|
||||||
height:100%;
|
|
||||||
width:100%;
|
|
||||||
.mat-tab-header{
|
|
||||||
.mat-tab-label-container{
|
|
||||||
.mat-tab-list{
|
|
||||||
.mat-tab-labels{
|
|
||||||
border-bottom:0;
|
|
||||||
padding-right:10px;
|
|
||||||
.mat-tab-label{
|
|
||||||
padding:0 10px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.mat-tab-body-wrapper{
|
|
||||||
.mat-tab-body{
|
|
||||||
.mat-tab-body-conten{
|
|
||||||
position:relative;
|
|
||||||
width:100%;
|
|
||||||
height:100%;
|
|
||||||
.mat-list-base{
|
|
||||||
position:relative;
|
|
||||||
.mat-list-option{
|
|
||||||
height:40px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
::ng-deep .setting-category{
|
|
||||||
.mat-list-base{
|
|
||||||
position:relative;
|
|
||||||
.mat-list-item{
|
|
||||||
font-size:15px;
|
|
||||||
|
|
||||||
}
|
|
||||||
.mat-divider{
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
|
@ -4,7 +4,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="app-layout-native-title-bar-title">UCAP M Messenger</div>
|
<div class="app-layout-native-title-bar-title">UCAP M Messenger</div>
|
||||||
<div class="app-layout-native-title-bar-spacer"></div>
|
<div class="app-layout-native-title-bar-spacer"></div>
|
||||||
<div class="app-layout-native-title-bar-link">
|
<div *ngIf="!!loginRes" class="app-layout-native-title-bar-link">
|
||||||
<button
|
<button
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
class="button app-layout-native-title-bar-setting"
|
class="button app-layout-native-title-bar-setting"
|
||||||
|
|
|
@ -4,12 +4,16 @@ import {
|
||||||
NativeService,
|
NativeService,
|
||||||
WindowState
|
WindowState
|
||||||
} from '@ucap-webmessenger/native';
|
} from '@ucap-webmessenger/native';
|
||||||
import { Observable } from 'rxjs';
|
import { Observable, Subscription } from 'rxjs';
|
||||||
import { Store } from '@ngrx/store';
|
import { Store, select } from '@ngrx/store';
|
||||||
|
|
||||||
|
import * as AppStore from '@app/store';
|
||||||
import * as AuthenticationStore from '@app/store/account/authentication';
|
import * as AuthenticationStore from '@app/store/account/authentication';
|
||||||
import * as SettingsStore from '@app/store/messenger/settings';
|
import * as SettingsStore from '@app/store/messenger/settings';
|
||||||
|
|
||||||
|
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||||
|
import { tap } from 'rxjs/operators';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-layout-native-top-bar',
|
selector: 'app-layout-native-top-bar',
|
||||||
templateUrl: './top-bar.component.html',
|
templateUrl: './top-bar.component.html',
|
||||||
|
@ -19,6 +23,8 @@ export class TopBarComponent implements OnInit, OnDestroy {
|
||||||
windowStateChanged$: Observable<WindowState>;
|
windowStateChanged$: Observable<WindowState>;
|
||||||
|
|
||||||
WindowState = WindowState;
|
WindowState = WindowState;
|
||||||
|
loginRes: LoginResponse;
|
||||||
|
loginResSubscription: Subscription;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private store: Store<any>,
|
private store: Store<any>,
|
||||||
|
@ -27,6 +33,15 @@ export class TopBarComponent implements OnInit, OnDestroy {
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
this.windowStateChanged$ = this.nativeService.windowStateChanged();
|
this.windowStateChanged$ = this.nativeService.windowStateChanged();
|
||||||
|
|
||||||
|
this.loginResSubscription = this.store
|
||||||
|
.pipe(
|
||||||
|
select(AppStore.AccountSelector.AuthenticationSelector.loginRes),
|
||||||
|
tap(loginRes => {
|
||||||
|
this.loginRes = loginRes;
|
||||||
|
})
|
||||||
|
)
|
||||||
|
.subscribe();
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnDestroy(): void {}
|
ngOnDestroy(): void {}
|
||||||
|
@ -48,6 +63,6 @@ export class TopBarComponent implements OnInit, OnDestroy {
|
||||||
}
|
}
|
||||||
|
|
||||||
onClickLogout(): void {
|
onClickLogout(): void {
|
||||||
this.store.dispatch(AuthenticationStore.logout());
|
this.store.dispatch(AuthenticationStore.logoutConfirmation());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,6 +8,8 @@ import {
|
||||||
} from '@ucap-webmessenger/web-storage';
|
} from '@ucap-webmessenger/web-storage';
|
||||||
import { LocaleCode } from '@ucap-webmessenger/core';
|
import { LocaleCode } from '@ucap-webmessenger/core';
|
||||||
import { LoginInfo, KEY_LOGIN_INFO } from '../types';
|
import { LoginInfo, KEY_LOGIN_INFO } from '../types';
|
||||||
|
import { KEY_VER_INFO } from '@app/types/ver-info.type';
|
||||||
|
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||||
|
|
||||||
@Injectable({
|
@Injectable({
|
||||||
providedIn: 'root'
|
providedIn: 'root'
|
||||||
|
@ -44,6 +46,8 @@ export class AppAuthenticationService {
|
||||||
}
|
}
|
||||||
|
|
||||||
logout() {
|
logout() {
|
||||||
|
this.sessionStorageService.remove(KEY_LOGIN_RES_INFO);
|
||||||
|
this.sessionStorageService.remove(KEY_VER_INFO);
|
||||||
this.sessionStorageService.remove(KEY_LOGIN_INFO);
|
this.sessionStorageService.remove(KEY_LOGIN_INFO);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@ export class AppNativeService {
|
||||||
|
|
||||||
subscribe(): void {
|
subscribe(): void {
|
||||||
this.nativeService.logout().subscribe(() => {
|
this.nativeService.logout().subscribe(() => {
|
||||||
this.store.dispatch(AuthenticationStore.logout());
|
this.store.dispatch(AuthenticationStore.logoutConfirmation());
|
||||||
});
|
});
|
||||||
this.nativeService.changeStatus().subscribe(statusCode => {});
|
this.nativeService.changeStatus().subscribe(statusCode => {});
|
||||||
this.nativeService.showSetting().subscribe(() => {
|
this.nativeService.showSetting().subscribe(() => {
|
||||||
|
|
|
@ -53,7 +53,11 @@ import {
|
||||||
ServiceProtocolService,
|
ServiceProtocolService,
|
||||||
UserPasswordSetResponse
|
UserPasswordSetResponse
|
||||||
} from '@ucap-webmessenger/protocol-service';
|
} from '@ucap-webmessenger/protocol-service';
|
||||||
import { AuthenticationProtocolService } from '@ucap-webmessenger/protocol-authentication';
|
import {
|
||||||
|
AuthenticationProtocolService,
|
||||||
|
LoginResponse
|
||||||
|
} from '@ucap-webmessenger/protocol-authentication';
|
||||||
|
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class Effects {
|
export class Effects {
|
||||||
|
@ -157,19 +161,26 @@ export class Effects {
|
||||||
this.actions$.pipe(
|
this.actions$.pipe(
|
||||||
ofType(logoutConfirmation),
|
ofType(logoutConfirmation),
|
||||||
exhaustMap(async () => {
|
exhaustMap(async () => {
|
||||||
const result = await this.dialogService.open<
|
const loginRes = this.sessionStorageService.get<LoginResponse>(
|
||||||
ConfirmDialogComponent,
|
KEY_LOGIN_RES_INFO
|
||||||
ConfirmDialogData,
|
);
|
||||||
ConfirmDialogResult
|
|
||||||
>(ConfirmDialogComponent, {
|
|
||||||
width: '220px',
|
|
||||||
data: {
|
|
||||||
title: 'Logout',
|
|
||||||
message: 'Logout ?'
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
return result.choice;
|
if (!!loginRes && loginRes.userSeq) {
|
||||||
|
const result = await this.dialogService.open<
|
||||||
|
ConfirmDialogComponent,
|
||||||
|
ConfirmDialogData,
|
||||||
|
ConfirmDialogResult
|
||||||
|
>(ConfirmDialogComponent, {
|
||||||
|
data: {
|
||||||
|
title: 'Logout',
|
||||||
|
message: '로그아웃 하시겠습니까?'
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return result.choice;
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
}),
|
}),
|
||||||
map(result => (result ? logout() : logoutConfirmationDismiss()))
|
map(result => (result ? logout() : logoutConfirmationDismiss()))
|
||||||
)
|
)
|
||||||
|
|
|
@ -15,6 +15,9 @@ import {
|
||||||
MessengerSettingsDialogData,
|
MessengerSettingsDialogData,
|
||||||
MessengerSettingsDialogResult
|
MessengerSettingsDialogResult
|
||||||
} from '@app/layouts/messenger/dialogs/settings/messenger-settings.dialog.component';
|
} from '@app/layouts/messenger/dialogs/settings/messenger-settings.dialog.component';
|
||||||
|
import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
||||||
|
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||||
|
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class Effects {
|
export class Effects {
|
||||||
|
@ -23,18 +26,24 @@ export class Effects {
|
||||||
this.actions$.pipe(
|
this.actions$.pipe(
|
||||||
ofType(showDialog),
|
ofType(showDialog),
|
||||||
tap(async () => {
|
tap(async () => {
|
||||||
const result = await this.dialogService.open<
|
const loginRes = this.sessionStorageService.get<LoginResponse>(
|
||||||
MessengerSettingsDialogComponent,
|
KEY_LOGIN_RES_INFO
|
||||||
MessengerSettingsDialogData,
|
);
|
||||||
MessengerSettingsDialogResult
|
|
||||||
>(MessengerSettingsDialogComponent, {
|
if (!!loginRes && loginRes.userSeq) {
|
||||||
width: '800px',
|
const result = await this.dialogService.open<
|
||||||
maxWidth: '800px',
|
MessengerSettingsDialogComponent,
|
||||||
height: '800px',
|
MessengerSettingsDialogData,
|
||||||
minHeight: '800px',
|
MessengerSettingsDialogResult
|
||||||
disableClose: false,
|
>(MessengerSettingsDialogComponent, {
|
||||||
data: {}
|
width: '800px',
|
||||||
});
|
maxWidth: '800px',
|
||||||
|
height: '800px',
|
||||||
|
minHeight: '800px',
|
||||||
|
disableClose: false,
|
||||||
|
data: {}
|
||||||
|
});
|
||||||
|
}
|
||||||
})
|
})
|
||||||
),
|
),
|
||||||
{ dispatch: false }
|
{ dispatch: false }
|
||||||
|
@ -44,6 +53,7 @@ export class Effects {
|
||||||
private actions$: Actions,
|
private actions$: Actions,
|
||||||
private store: Store<any>,
|
private store: Store<any>,
|
||||||
private dialogService: DialogService,
|
private dialogService: DialogService,
|
||||||
private logger: NGXLogger
|
private logger: NGXLogger,
|
||||||
|
private sessionStorageService: SessionStorageService
|
||||||
) {}
|
) {}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user