Merge branch 'master' of https://git.loafle.net/ucap-web/next-ucap-messenger
This commit is contained in:
commit
12143b038f
@ -5,7 +5,6 @@ import {
|
||||
APIEncoder,
|
||||
APIDecoder,
|
||||
ParameterUtil,
|
||||
JsonAnalization,
|
||||
StatusCode
|
||||
} from '@ucap-webmessenger/api';
|
||||
|
||||
@ -51,20 +50,19 @@ export const decodeFileTalkShare: APIDecoder<FileTalkShareResponse> = (
|
||||
res: any
|
||||
) => {
|
||||
try {
|
||||
const json = JsonAnalization.receiveAnalization(res);
|
||||
return {
|
||||
statusCode: json.StatusCode,
|
||||
roomSeq: json.RoomID,
|
||||
fileName: json.FileName,
|
||||
fileExt: json.FileExt,
|
||||
fileType: json.FileType,
|
||||
thumbnailUrl: json.ThumbURL,
|
||||
attachmentSeq: json.AttSEQ,
|
||||
attachmentSize: json.AttSize,
|
||||
attachmentRegDate: json.AttRegDate,
|
||||
companyCode: json.CompanyCode,
|
||||
synapKey: json.SynapKey,
|
||||
returnJson: res
|
||||
statusCode: res.StatusCode,
|
||||
roomSeq: res.RoomID,
|
||||
fileName: res.FileName,
|
||||
fileExt: res.FileExt,
|
||||
fileType: res.FileType,
|
||||
thumbnailUrl: res.ThumbURL,
|
||||
attachmentSeq: res.AttSEQ,
|
||||
attachmentSize: res.AttSize,
|
||||
attachmentRegDate: res.AttRegDate,
|
||||
companyCode: res.CompanyCode,
|
||||
synapKey: res.SynapKey,
|
||||
returnJson: JSON.stringify(res)
|
||||
} as FileTalkShareResponse;
|
||||
} catch (e) {
|
||||
return {
|
||||
|
@ -5,9 +5,11 @@ export * from './lib/apis/del';
|
||||
export * from './lib/apis/detail';
|
||||
export * from './lib/apis/edit-reservation-ex';
|
||||
export * from './lib/apis/my-message';
|
||||
export * from './lib/apis/notice';
|
||||
export * from './lib/apis/retrieve';
|
||||
export * from './lib/apis/send-copy';
|
||||
export * from './lib/apis/send';
|
||||
export * from './lib/apis/unread-count';
|
||||
|
||||
export * from './lib/services/message-api.service';
|
||||
|
||||
|
@ -98,33 +98,33 @@ export class FileViewerDialogComponent implements OnInit, OnDestroy {
|
||||
.saveFile(buffer, this.fileInfo.fileName, mimeType)
|
||||
.then(result => {
|
||||
if (!!result) {
|
||||
this.translateService
|
||||
.get('common.file.results.savedToPath', {
|
||||
path: result
|
||||
})
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v, '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.results.savedToPath',
|
||||
{
|
||||
path: result
|
||||
}
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
} else {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
}
|
||||
})
|
||||
.catch(reason => {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
});
|
||||
})
|
||||
.catch(reason => {
|
||||
|
@ -166,78 +166,68 @@ export class LeftSideComponent implements OnInit, OnDestroy {
|
||||
this.logger.debug('-----------------------LeftSideComponent ngOnDestroy');
|
||||
}
|
||||
|
||||
onClickNewChat(type: string = 'NORMAL') {
|
||||
this.translateService
|
||||
.get(['chat.newTimerChat', 'chat.newChat'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.NewChat,
|
||||
title:
|
||||
type === 'TIMER' ? vs['chat.newTimerChat'] : vs['chat.newChat']
|
||||
}
|
||||
});
|
||||
async onClickNewChat(type: string = 'NORMAL') {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.NewChat,
|
||||
title:
|
||||
type === 'TIMER'
|
||||
? this.translateService.instant('chat.newTimerChat')
|
||||
: this.translateService.instant('chat.newChat')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (!!result.selectedUserList && result.selectedUserList.length > 0) {
|
||||
const userSeqs: number[] = [];
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (!!result.selectedUserList && result.selectedUserList.length > 0) {
|
||||
const userSeqs: number[] = [];
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
|
||||
if (type === 'NORMAL') {
|
||||
this.store.dispatch(
|
||||
ChatStore.openRoom({ userSeqList: userSeqs })
|
||||
);
|
||||
} else if (type === 'TIMER') {
|
||||
this.store.dispatch(
|
||||
ChatStore.openRoom({ userSeqList: userSeqs, isTimeRoom: true })
|
||||
);
|
||||
}
|
||||
}
|
||||
if (type === 'NORMAL') {
|
||||
this.store.dispatch(ChatStore.openRoom({ userSeqList: userSeqs }));
|
||||
} else if (type === 'TIMER') {
|
||||
this.store.dispatch(
|
||||
ChatStore.openRoom({ userSeqList: userSeqs, isTimeRoom: true })
|
||||
);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onClickNewGroupAndMember() {
|
||||
this.translateService
|
||||
.get(['group.addNew'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.NewGroup,
|
||||
title: vs['group.addNew']
|
||||
}
|
||||
});
|
||||
async onClickNewGroupAndMember() {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.NewGroup,
|
||||
title: this.translateService.instant('group.addNew')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (
|
||||
!!result.selectedUserList &&
|
||||
// result.selectedUserList.length > 0 &&
|
||||
result.groupName.trim().length > 0
|
||||
) {
|
||||
const userSeqs: number[] = [];
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (
|
||||
!!result.selectedUserList &&
|
||||
// result.selectedUserList.length > 0 &&
|
||||
result.groupName.trim().length > 0
|
||||
) {
|
||||
const userSeqs: number[] = [];
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
|
||||
this.store.dispatch(
|
||||
SyncStore.createGroupAndBuddy({
|
||||
groupName: result.groupName,
|
||||
trgtUserSeq: userSeqs
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
this.store.dispatch(
|
||||
SyncStore.createGroupAndBuddy({
|
||||
groupName: result.groupName,
|
||||
trgtUserSeq: userSeqs
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async onClickNewMessage() {
|
||||
@ -306,76 +296,66 @@ export class LeftSideComponent implements OnInit, OnDestroy {
|
||||
}
|
||||
|
||||
setFabInitial(type: string) {
|
||||
this.translateService
|
||||
.get([
|
||||
'group.addNew',
|
||||
'chat.newChat',
|
||||
'chat.newTimerChat',
|
||||
'message.newMessage'
|
||||
])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
switch (type) {
|
||||
case MainMenu.Group:
|
||||
switch (type) {
|
||||
case MainMenu.Group:
|
||||
{
|
||||
this.fabButtonShow = true;
|
||||
this.fabButtons = [
|
||||
{
|
||||
this.fabButtonShow = true;
|
||||
this.fabButtons = [
|
||||
{
|
||||
icon: 'add',
|
||||
tooltip: vs['group.addNew'],
|
||||
divisionType: 'GROUP_NEW_ADD'
|
||||
}
|
||||
];
|
||||
icon: 'add',
|
||||
tooltip: this.translateService.instant('group.addNew'),
|
||||
divisionType: 'GROUP_NEW_ADD'
|
||||
}
|
||||
break;
|
||||
case MainMenu.Chat:
|
||||
];
|
||||
}
|
||||
break;
|
||||
case MainMenu.Chat:
|
||||
{
|
||||
this.fabButtonShow = true;
|
||||
this.fabButtons = [
|
||||
{
|
||||
this.fabButtonShow = true;
|
||||
this.fabButtons = [
|
||||
{
|
||||
icon: 'chat',
|
||||
tooltip: vs['chat.newChat'],
|
||||
divisionType: 'CAHT_NEW_ADD'
|
||||
}
|
||||
];
|
||||
icon: 'chat',
|
||||
tooltip: this.translateService.instant('chat.newChat'),
|
||||
divisionType: 'CAHT_NEW_ADD'
|
||||
}
|
||||
];
|
||||
|
||||
if (environment.productConfig.CommonSetting.useTimerRoom) {
|
||||
this.fabButtons.push({
|
||||
icon: 'timer',
|
||||
tooltip: vs['chat.newTimerChat'],
|
||||
divisionType: 'CHAT_NEW_TIMER_ADD'
|
||||
});
|
||||
}
|
||||
}
|
||||
break;
|
||||
case MainMenu.Organization:
|
||||
{
|
||||
this.fabButtonShow = false;
|
||||
}
|
||||
break;
|
||||
case MainMenu.Message:
|
||||
{
|
||||
this.fabButtonShow = true;
|
||||
this.fabButtons = [
|
||||
{
|
||||
icon: 'add',
|
||||
tooltip: vs['message.newMessage'],
|
||||
divisionType: 'MESSAGE_NEW'
|
||||
}
|
||||
];
|
||||
}
|
||||
break;
|
||||
case MainMenu.Call:
|
||||
{
|
||||
this.fabButtonShow = false;
|
||||
}
|
||||
break;
|
||||
|
||||
default: {
|
||||
this.fabButtonShow = false;
|
||||
if (environment.productConfig.CommonSetting.useTimerRoom) {
|
||||
this.fabButtons.push({
|
||||
icon: 'timer',
|
||||
tooltip: this.translateService.instant('chat.newTimerChat'),
|
||||
divisionType: 'CHAT_NEW_TIMER_ADD'
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
break;
|
||||
case MainMenu.Organization:
|
||||
{
|
||||
this.fabButtonShow = false;
|
||||
}
|
||||
break;
|
||||
case MainMenu.Message:
|
||||
{
|
||||
this.fabButtonShow = true;
|
||||
this.fabButtons = [
|
||||
{
|
||||
icon: 'add',
|
||||
tooltip: this.translateService.instant('message.new'),
|
||||
divisionType: 'MESSAGE_NEW'
|
||||
}
|
||||
];
|
||||
}
|
||||
break;
|
||||
case MainMenu.Call:
|
||||
{
|
||||
this.fabButtonShow = false;
|
||||
}
|
||||
break;
|
||||
|
||||
default: {
|
||||
this.fabButtonShow = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onCheckAllUser(params: {
|
||||
|
@ -253,7 +253,7 @@ export class ChatComponent implements OnInit, OnDestroy, AfterViewChecked {
|
||||
this.chatContextMenuTrigger.openMenu();
|
||||
}
|
||||
|
||||
onClickContextMenu(type: string, roomInfo: RoomInfo) {
|
||||
async onClickContextMenu(type: string, roomInfo: RoomInfo) {
|
||||
switch (type) {
|
||||
case 'SELECT_ROOM':
|
||||
this.store.dispatch(
|
||||
@ -265,27 +265,20 @@ export class ChatComponent implements OnInit, OnDestroy, AfterViewChecked {
|
||||
break;
|
||||
case 'EXIT_ROOM':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.exitFromRoom', 'chat.confirmExitFromRoom'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async values => {
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: values['chat.exitFromRoom'],
|
||||
html: values['chat.confirmExitFromRoom']
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: this.translateService.instant('chat.exitFromRoom'),
|
||||
html: this.translateService.instant('chat.confirmExitFromRoom')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
RoomStore.exit({ roomSeq: roomInfo.roomSeq })
|
||||
);
|
||||
}
|
||||
});
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(RoomStore.exit({ roomSeq: roomInfo.roomSeq }));
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -56,7 +56,7 @@
|
||||
{{ 'common.searchResult' | translate
|
||||
}}<span class="text-accent-color"
|
||||
>({{ searchUserInfos.length
|
||||
}}{{ 'common.howManyPersons' | translate }})</span
|
||||
}}{{ 'common.units.persons' | translate }})</span
|
||||
>
|
||||
</div>
|
||||
<ucap-profile-user-list-item
|
||||
|
@ -144,7 +144,9 @@ export class GroupComponent implements OnInit, OnDestroy {
|
||||
.pipe(
|
||||
select(AppStore.AccountSelector.AuthenticationSelector.loginRes),
|
||||
tap(loginRes => {
|
||||
this.loginRes = loginRes;
|
||||
if (!!loginRes) {
|
||||
this.loginRes = loginRes;
|
||||
}
|
||||
})
|
||||
)
|
||||
.subscribe();
|
||||
|
@ -39,7 +39,7 @@
|
||||
{{ 'common.searchResult' | translate
|
||||
}}<span class="text-accent-color"
|
||||
>({{ searchUserInfos.length }}
|
||||
{{ 'common.howManyPersons' | translate }})</span
|
||||
{{ 'common.units.persons' | translate }})</span
|
||||
>
|
||||
</ng-container>
|
||||
</dt>
|
||||
|
@ -116,6 +116,8 @@ export class OrganizationComponent
|
||||
|
||||
@ViewChild('cvsvDeptUser', { static: false })
|
||||
cvsvDeptUser: CdkVirtualScrollViewport;
|
||||
@ViewChild('cvsvDeptSearchUser', { static: false })
|
||||
cvsvDeptSearchUser: CdkVirtualScrollViewport;
|
||||
|
||||
@ViewChild(PerfectScrollbarDirective, { static: false })
|
||||
psDirectiveRef?: PerfectScrollbarDirective;
|
||||
@ -290,15 +292,21 @@ export class OrganizationComponent
|
||||
this.selectedDepartmentProcessing = false;
|
||||
// 검색 결과에 따른 프레즌스 조회.
|
||||
const userSeqList: number[] = [];
|
||||
this.searchUserInfos.map(user => userSeqList.push(user.seq));
|
||||
if (userSeqList.length > 0) {
|
||||
this.store.dispatch(
|
||||
StatusStore.bulkInfo({
|
||||
divCd: 'orgSrch',
|
||||
userSeqs: userSeqList
|
||||
userSeqs: this.searchUserInfos.map(user => user.seq)
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
if (!!this.cvsvDeptSearchUser) {
|
||||
this.cvsvDeptSearchUser.scrollToOffset(0);
|
||||
}
|
||||
if (!!this.psDirectiveRef) {
|
||||
this.psDirectiveRef.update();
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -119,6 +119,8 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
openProfile = new EventEmitter<{
|
||||
userSeq: number;
|
||||
}>();
|
||||
@Output()
|
||||
closeRightDrawer = new EventEmitter();
|
||||
|
||||
@ViewChild('chatForm', { static: false })
|
||||
private chatForm: UCapUiChatFormComponent;
|
||||
@ -410,6 +412,9 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
* 채팅방의 여러 팝업들을 닫아준다.
|
||||
*/
|
||||
clearView() {
|
||||
// Right Drawer closed..
|
||||
this.closeRightDrawer.emit();
|
||||
|
||||
// Sticker Selector Clear..
|
||||
this.isShowStickerSelector = false;
|
||||
this.selectedSticker = undefined;
|
||||
@ -646,28 +651,24 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
}
|
||||
|
||||
/** Send Event */
|
||||
onSendMessage(message: string) {
|
||||
async onSendMessage(message: string) {
|
||||
this.setEventMoreInit();
|
||||
|
||||
if (!this.selectedSticker) {
|
||||
if (!message || message.trim().length === 0) {
|
||||
this.translateService
|
||||
.get(['chat.errors.label', 'chat.errors.inputChatMessage'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
AlertDialogComponent,
|
||||
AlertDialogData,
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: vs['chat.errors.label'],
|
||||
message: vs['chat.errors.inputChatMessage']
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
const result = await this.dialogService.open<
|
||||
AlertDialogComponent,
|
||||
AlertDialogData,
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: this.translateService.instant('chat.errors.label'),
|
||||
message: this.translateService.instant(
|
||||
'chat.errors.inputChatMessage'
|
||||
)
|
||||
}
|
||||
});
|
||||
return;
|
||||
}
|
||||
}
|
||||
@ -769,24 +770,23 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
message.trim().length >
|
||||
environment.productConfig.CommonSetting.masstextLength
|
||||
) {
|
||||
this.translateService
|
||||
.get(['chat.errors.label', 'chat.errors.maxLengthOfMassText'], {
|
||||
maxLength: environment.productConfig.CommonSetting.masstextLength
|
||||
})
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
AlertDialogComponent,
|
||||
AlertDialogData,
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: vs['chat.errors.label'],
|
||||
message: vs['chat.errors.maxLengthOfMassText']
|
||||
const result = await this.dialogService.open<
|
||||
AlertDialogComponent,
|
||||
AlertDialogData,
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: this.translateService.instant('chat.errors.label'),
|
||||
message: this.translateService.instant(
|
||||
'chat.errors.maxLengthOfMassText',
|
||||
{
|
||||
maxLength:
|
||||
environment.productConfig.CommonSetting.masstextLength
|
||||
}
|
||||
});
|
||||
});
|
||||
)
|
||||
}
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
@ -902,31 +902,27 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
}) {
|
||||
this.logger.debug('fileSave', value);
|
||||
if (value.type === 'saveAs') {
|
||||
this.translateService
|
||||
.get([
|
||||
'common.file.errors.label',
|
||||
'common.file.errors.failToSpecifyPath'
|
||||
])
|
||||
.pipe(take(1))
|
||||
.subscribe(vs => {
|
||||
this.nativeService
|
||||
.selectSaveFilePath(value.fileInfo.fileName)
|
||||
.then(result => {
|
||||
if (!!result && result.length > 0) {
|
||||
this.saveFile(value, result);
|
||||
} else {
|
||||
this.snackBarService.open(
|
||||
vs['common.file.errors.failToSpecifyPath'],
|
||||
vs['common.file.errors.label']
|
||||
);
|
||||
}
|
||||
})
|
||||
.catch(reason => {
|
||||
this.snackBarService.open(
|
||||
vs['common.file.errors.failToSpecifyPath'],
|
||||
vs['common.file.errors.label']
|
||||
);
|
||||
});
|
||||
this.nativeService
|
||||
.selectSaveFilePath(value.fileInfo.fileName)
|
||||
.then(result => {
|
||||
if (!!result && result.length > 0) {
|
||||
this.saveFile(value, result);
|
||||
} else {
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSpecifyPath'
|
||||
),
|
||||
this.translateService.instant('common.file.errors.label')
|
||||
);
|
||||
}
|
||||
})
|
||||
.catch(reason => {
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSpecifyPath'
|
||||
),
|
||||
this.translateService.instant('common.file.errors.label')
|
||||
);
|
||||
});
|
||||
} else {
|
||||
this.saveFile(value);
|
||||
@ -976,33 +972,33 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
.saveFile(buffer, value.fileInfo.fileName, mimeType, savePath)
|
||||
.then(result => {
|
||||
if (!!result) {
|
||||
this.translateService
|
||||
.get('common.file.results.savedToPath', {
|
||||
path: result
|
||||
})
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v, '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.results.savedToPath',
|
||||
{
|
||||
path: result
|
||||
}
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
} else {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
}
|
||||
})
|
||||
.catch(reason => {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
});
|
||||
})
|
||||
.catch(reason => {
|
||||
@ -1100,19 +1096,10 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
},
|
||||
error => {
|
||||
this.logger.debug('onFileSelected error', error);
|
||||
|
||||
this.translateService
|
||||
.get([
|
||||
'common.file.errors.label',
|
||||
'common.file.errors.failToUpload'
|
||||
])
|
||||
.pipe(take(1))
|
||||
.subscribe(vs => {
|
||||
this.snackBarService.open(
|
||||
vs['common.file.errors.failToUpload'],
|
||||
vs['common.file.errors.label']
|
||||
);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant('common.file.errors.failToUpload'),
|
||||
this.translateService.instant('common.file.errors.label')
|
||||
);
|
||||
},
|
||||
() => {
|
||||
this.fileUploadQueue.onUploadComplete();
|
||||
@ -1137,7 +1124,7 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
this.messageContextMenuTrigger.openMenu();
|
||||
}
|
||||
|
||||
onClickMessageContextMenu(menuType: string, message: Info<EventJson>) {
|
||||
async onClickMessageContextMenu(menuType: string, message: Info<EventJson>) {
|
||||
switch (menuType) {
|
||||
case 'COPY':
|
||||
{
|
||||
@ -1149,20 +1136,17 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
(message as Info<string>).sentMessage
|
||||
)
|
||||
) {
|
||||
this.translateService
|
||||
.get(['common.clipboard.results.copied'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
this.snackBarService.open(
|
||||
vs['common.clipboard.results.copied'],
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'top',
|
||||
horizontalPosition: 'center'
|
||||
}
|
||||
);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.clipboard.results.copied'
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'top',
|
||||
horizontalPosition: 'center'
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@ -1178,20 +1162,17 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
.pipe(take(1))
|
||||
.subscribe(res => {
|
||||
if (this.clipboardService.copyFromContent(res.content)) {
|
||||
this.translateService
|
||||
.get(['common.clipboard.results.copied'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
this.snackBarService.open(
|
||||
vs['common.clipboard.results.copied'],
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'top',
|
||||
horizontalPosition: 'center'
|
||||
}
|
||||
);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.clipboard.results.copied'
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'top',
|
||||
horizontalPosition: 'center'
|
||||
}
|
||||
);
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -1204,53 +1185,48 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
break;
|
||||
case 'REPLAY':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.forwardEventTo'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.MessageForward,
|
||||
title: vs['chat.forwardEventTo'],
|
||||
ignoreRoom: [this.roomInfo]
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.MessageForward,
|
||||
title: this.translateService.instant('chat.forwardEventTo'),
|
||||
ignoreRoom: [this.roomInfo]
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = [];
|
||||
let roomSeq = '';
|
||||
if (
|
||||
!!result.selectedUserList &&
|
||||
result.selectedUserList.length > 0
|
||||
) {
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
}
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = [];
|
||||
let roomSeq = '';
|
||||
if (
|
||||
!!result.selectedUserList &&
|
||||
result.selectedUserList.length > 0
|
||||
) {
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
}
|
||||
|
||||
if (!!result.selectedRoom) {
|
||||
roomSeq = result.selectedRoom.roomSeq;
|
||||
}
|
||||
if (!!result.selectedRoom) {
|
||||
roomSeq = result.selectedRoom.roomSeq;
|
||||
}
|
||||
|
||||
if (userSeqs.length > 0 || roomSeq.trim().length > 0) {
|
||||
this.store.dispatch(
|
||||
EventStore.forward({
|
||||
senderSeq: this.loginRes.userSeq,
|
||||
req: {
|
||||
roomSeq: '-999',
|
||||
eventType: message.type,
|
||||
sentMessage: message.sentMessage
|
||||
},
|
||||
trgtUserSeqs: userSeqs,
|
||||
trgtRoomSeq: roomSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
if (userSeqs.length > 0 || roomSeq.trim().length > 0) {
|
||||
this.store.dispatch(
|
||||
EventStore.forward({
|
||||
senderSeq: this.loginRes.userSeq,
|
||||
req: {
|
||||
roomSeq: '-999',
|
||||
eventType: message.type,
|
||||
sentMessage: message.sentMessage
|
||||
},
|
||||
trgtUserSeqs: userSeqs,
|
||||
trgtRoomSeq: roomSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'REPLAY_TO_ME':
|
||||
@ -1272,61 +1248,51 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
break;
|
||||
case 'DELETE':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.removeEvent', 'chat.confirmRemoveEvent'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: vs['chat.removeEvent'],
|
||||
html: vs['chat.confirmRemoveEvent']
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: this.translateService.instant('chat.removeEvent'),
|
||||
html: this.translateService.instant('chat.confirmRemoveEvent')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
EventStore.del({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
eventSeq: message.seq
|
||||
})
|
||||
);
|
||||
}
|
||||
});
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
EventStore.del({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
eventSeq: message.seq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'RECALL':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.recallEvent', 'chat.confirmRecallEvent'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: vs['chat.recallEvent'],
|
||||
html: vs['chat.confirmRecallEvent']
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: this.translateService.instant('chat.recallEvent'),
|
||||
html: this.translateService.instant('chat.confirmRecallEvent')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
EventStore.cancel({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
eventSeq: message.seq,
|
||||
deviceType: this.environmentsInfo.deviceType
|
||||
})
|
||||
);
|
||||
}
|
||||
});
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
EventStore.cancel({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
eventSeq: message.seq,
|
||||
deviceType: this.environmentsInfo.deviceType
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
@ -1334,7 +1300,7 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
}
|
||||
}
|
||||
|
||||
onClickContextMenu(menuType: string) {
|
||||
async onClickContextMenu(menuType: string) {
|
||||
switch (menuType) {
|
||||
case 'OPEN_ALBUM_LIST':
|
||||
{
|
||||
@ -1370,153 +1336,134 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
break;
|
||||
case 'ADD_MEMBER':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.modifyRoomMember'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.EditChatMember,
|
||||
title: vs['chat.modifyRoomMember'],
|
||||
curRoomUser: this.userInfoList.filter(
|
||||
user =>
|
||||
user.seq !== this.loginRes.userSeq && user.isJoinRoom
|
||||
)
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.EditChatMember,
|
||||
title: this.translateService.instant('chat.modifyRoomMember'),
|
||||
curRoomUser: this.userInfoList.filter(
|
||||
user => user.seq !== this.loginRes.userSeq && user.isJoinRoom
|
||||
)
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = this.userInfoList.map(userInfo => {
|
||||
if (userInfo.isJoinRoom) {
|
||||
return userInfo.seq;
|
||||
}
|
||||
});
|
||||
if (
|
||||
!!result.selectedUserList &&
|
||||
result.selectedUserList.length > 0
|
||||
) {
|
||||
result.selectedUserList.forEach(user => {
|
||||
if (userSeqs.indexOf(user.seq) < 0) {
|
||||
userSeqs.push(user.seq);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (userSeqs.length > 0) {
|
||||
// include me
|
||||
userSeqs.push(this.loginRes.userSeq);
|
||||
|
||||
this.store.dispatch(
|
||||
RoomStore.inviteOrOpen({
|
||||
req: {
|
||||
divCd: 'Invite',
|
||||
userSeqs
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = this.userInfoList.map(userInfo => {
|
||||
if (userInfo.isJoinRoom) {
|
||||
return userInfo.seq;
|
||||
}
|
||||
});
|
||||
if (
|
||||
!!result.selectedUserList &&
|
||||
result.selectedUserList.length > 0
|
||||
) {
|
||||
result.selectedUserList.forEach(user => {
|
||||
if (userSeqs.indexOf(user.seq) < 0) {
|
||||
userSeqs.push(user.seq);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (userSeqs.length > 0) {
|
||||
// include me
|
||||
userSeqs.push(this.loginRes.userSeq);
|
||||
|
||||
this.store.dispatch(
|
||||
RoomStore.inviteOrOpen({
|
||||
req: {
|
||||
divCd: 'Invite',
|
||||
userSeqs
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'ADD_GROUP':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.addMemberToGroup'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
SelectGroupDialogComponent,
|
||||
SelectGroupDialogData,
|
||||
SelectGroupDialogResult
|
||||
>(SelectGroupDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: vs['chat.addMemberToGroup']
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
SelectGroupDialogComponent,
|
||||
SelectGroupDialogData,
|
||||
SelectGroupDialogResult
|
||||
>(SelectGroupDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: this.translateService.instant('chat.addMemberToGroup')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (!!result.group) {
|
||||
const oldGroup: GroupDetailData = result.group;
|
||||
const trgtUserSeq: number[] = [];
|
||||
result.group.userSeqs.map(seq => trgtUserSeq.push(seq));
|
||||
this.userInfoList
|
||||
.filter(v => result.group.userSeqs.indexOf(v.seq) < 0)
|
||||
.forEach(user => {
|
||||
trgtUserSeq.push(user.seq);
|
||||
});
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (!!result.group) {
|
||||
const oldGroup: GroupDetailData = result.group;
|
||||
const trgtUserSeq: number[] = [];
|
||||
result.group.userSeqs.map(seq => trgtUserSeq.push(seq));
|
||||
this.userInfoList
|
||||
.filter(v => result.group.userSeqs.indexOf(v.seq) < 0)
|
||||
.forEach(user => {
|
||||
trgtUserSeq.push(user.seq);
|
||||
});
|
||||
|
||||
this.store.dispatch(
|
||||
SyncStore.updateGroupMember({
|
||||
oldGroup,
|
||||
trgtUserSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
this.store.dispatch(
|
||||
SyncStore.updateGroupMember({
|
||||
oldGroup,
|
||||
trgtUserSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'EDIT_ROOM':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.settingsOfRoom'])
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
EditChatRoomDialogComponent,
|
||||
EditChatRoomDialogData,
|
||||
EditChatRoomDialogResult
|
||||
>(EditChatRoomDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: vs['chat.settingsOfRoom'],
|
||||
roomInfo: this.roomInfo
|
||||
const result = await this.dialogService.open<
|
||||
EditChatRoomDialogComponent,
|
||||
EditChatRoomDialogData,
|
||||
EditChatRoomDialogResult
|
||||
>(EditChatRoomDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: this.translateService.instant('chat.settingsOfRoom'),
|
||||
roomInfo: this.roomInfo
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const roomName: string = result.roomName;
|
||||
const roomNameChangeTarget: string = result.roomNameChangeTarget;
|
||||
const timeRoomInterval: number = result.timeRoomInterval;
|
||||
const roomInfo: RoomInfo = result.roomInfo;
|
||||
|
||||
// 방제목 업데이트.
|
||||
this.store.dispatch(
|
||||
RoomStore.update({
|
||||
req: {
|
||||
roomSeq: roomInfo.roomSeq,
|
||||
roomName,
|
||||
receiveAlarm: roomInfo.receiveAlarm,
|
||||
syncAll:
|
||||
roomNameChangeTarget.toUpperCase() === 'ALL' ? true : false
|
||||
}
|
||||
});
|
||||
})
|
||||
);
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const roomName: string = result.roomName;
|
||||
const roomNameChangeTarget: string =
|
||||
result.roomNameChangeTarget;
|
||||
const timeRoomInterval: number = result.timeRoomInterval;
|
||||
const roomInfo: RoomInfo = result.roomInfo;
|
||||
|
||||
// 방제목 업데이트.
|
||||
this.store.dispatch(
|
||||
RoomStore.update({
|
||||
req: {
|
||||
roomSeq: roomInfo.roomSeq,
|
||||
roomName,
|
||||
receiveAlarm: roomInfo.receiveAlarm,
|
||||
syncAll:
|
||||
roomNameChangeTarget.toUpperCase() === 'ALL'
|
||||
? true
|
||||
: false
|
||||
}
|
||||
})
|
||||
);
|
||||
|
||||
if (
|
||||
roomInfo.isTimeRoom &&
|
||||
timeRoomInterval > 0 &&
|
||||
roomInfo.timeRoomInterval !== timeRoomInterval
|
||||
) {
|
||||
this.store.dispatch(
|
||||
RoomStore.updateTimeRoomInterval({
|
||||
roomSeq: roomInfo.roomSeq,
|
||||
timerInterval: timeRoomInterval
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
if (
|
||||
roomInfo.isTimeRoom &&
|
||||
timeRoomInterval > 0 &&
|
||||
roomInfo.timeRoomInterval !== timeRoomInterval
|
||||
) {
|
||||
this.store.dispatch(
|
||||
RoomStore.updateTimeRoomInterval({
|
||||
roomSeq: roomInfo.roomSeq,
|
||||
timerInterval: timeRoomInterval
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'CLOSE_ROOM':
|
||||
|
@ -100,6 +100,7 @@ export class AlbumBoxComponent implements OnInit, OnDestroy {
|
||||
tap(([roomInfo, fileInfoList, fileInfoCheckList]) => {
|
||||
this.fileInfoList = fileInfoList.filter(fileInfo => {
|
||||
if (
|
||||
!!roomInfo &&
|
||||
fileInfo.roomSeq === roomInfo.roomSeq &&
|
||||
(fileInfo.type === FileType.Image ||
|
||||
fileInfo.type === FileType.Video)
|
||||
@ -232,33 +233,33 @@ export class AlbumBoxComponent implements OnInit, OnDestroy {
|
||||
.saveFile(buffer, fileInfo.info.name, mimeType)
|
||||
.then(result => {
|
||||
if (!!result) {
|
||||
this.translateService
|
||||
.get('common.file.results.savedToPath', {
|
||||
path: result
|
||||
})
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v, '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.results.savedToPath',
|
||||
{
|
||||
path: result
|
||||
}
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
} else {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
}
|
||||
})
|
||||
.catch(reason => {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
});
|
||||
})
|
||||
.catch(reason => {
|
||||
|
@ -109,6 +109,7 @@ export class FileBoxComponent implements OnInit, OnDestroy {
|
||||
|
||||
this.fileInfoList = fileInfoList.filter(fileInfo => {
|
||||
if (
|
||||
!!roomInfo &&
|
||||
fileInfo.roomSeq === roomInfo.roomSeq &&
|
||||
(fileInfo.type === FileType.File ||
|
||||
fileInfo.type === FileType.Sound)
|
||||
@ -276,33 +277,33 @@ export class FileBoxComponent implements OnInit, OnDestroy {
|
||||
.saveFile(buffer, fileInfo.info.name, mimeType)
|
||||
.then(result => {
|
||||
if (!!result) {
|
||||
this.translateService
|
||||
.get('common.file.results.savedToPath', {
|
||||
path: result
|
||||
})
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v, '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.results.savedToPath',
|
||||
{
|
||||
path: result
|
||||
}
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
} else {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
}
|
||||
})
|
||||
.catch(reason => {
|
||||
this.translateService
|
||||
.get('common.file.errors.failToSave')
|
||||
.pipe(take(1))
|
||||
.subscribe(v => {
|
||||
this.snackBarService.open(v);
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
)
|
||||
);
|
||||
});
|
||||
})
|
||||
.catch(reason => {
|
||||
@ -352,84 +353,74 @@ export class FileBoxComponent implements OnInit, OnDestroy {
|
||||
);
|
||||
}
|
||||
|
||||
onClickForward(fileInfo: FileInfoTotal) {
|
||||
this.translateService
|
||||
.get('chat.forwardFileTo')
|
||||
.pipe(take(1))
|
||||
.subscribe(async v => {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.MessageForward,
|
||||
title: v,
|
||||
ignoreRoom: [this.roomInfo]
|
||||
}
|
||||
});
|
||||
async onClickForward(fileInfo: FileInfoTotal) {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.MessageForward,
|
||||
title: this.translateService.instant('chat.forwardFileTo'),
|
||||
ignoreRoom: [this.roomInfo]
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = [];
|
||||
let roomSeq = '';
|
||||
if (!!result.selectedUserList && result.selectedUserList.length > 0) {
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
}
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = [];
|
||||
let roomSeq = '';
|
||||
if (!!result.selectedUserList && result.selectedUserList.length > 0) {
|
||||
result.selectedUserList.map(user => userSeqs.push(user.seq));
|
||||
}
|
||||
|
||||
if (!!result.selectedRoom) {
|
||||
roomSeq = result.selectedRoom.roomSeq;
|
||||
}
|
||||
if (!!result.selectedRoom) {
|
||||
roomSeq = result.selectedRoom.roomSeq;
|
||||
}
|
||||
|
||||
if (userSeqs.length > 0 || roomSeq.trim().length > 0) {
|
||||
this.store.dispatch(
|
||||
EventStore.forward({
|
||||
senderSeq: this.loginRes.userSeq,
|
||||
req: {
|
||||
roomSeq: '-999',
|
||||
eventType: EventType.File,
|
||||
sentMessage: fileInfo.info.sentMessage
|
||||
},
|
||||
trgtUserSeqs: userSeqs,
|
||||
trgtRoomSeq: roomSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
if (userSeqs.length > 0 || roomSeq.trim().length > 0) {
|
||||
this.store.dispatch(
|
||||
EventStore.forward({
|
||||
senderSeq: this.loginRes.userSeq,
|
||||
req: {
|
||||
roomSeq: '-999',
|
||||
eventType: EventType.File,
|
||||
sentMessage: fileInfo.info.sentMessage
|
||||
},
|
||||
trgtUserSeqs: userSeqs,
|
||||
trgtRoomSeq: roomSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onClickDelete(fileInfo: FileInfoTotal) {
|
||||
this.translateService
|
||||
.get('chat.confirmDeleteFile')
|
||||
.pipe(take(1))
|
||||
.subscribe(async v => {
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: 'Delete',
|
||||
html: v
|
||||
}
|
||||
});
|
||||
async onClickDelete(fileInfo: FileInfoTotal) {
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: 'Delete',
|
||||
html: this.translateService.instant('chat.confirmDeleteFile')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
EventStore.del({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
eventSeq: fileInfo.info.eventSeq
|
||||
})
|
||||
);
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
EventStore.del({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
eventSeq: fileInfo.info.eventSeq
|
||||
})
|
||||
);
|
||||
|
||||
this.fileInfoTotal = this.fileInfoTotal.filter(
|
||||
fInfo => fInfo.info.seq !== fileInfo.info.seq
|
||||
);
|
||||
this.onSelectedIndexChange(this.currentTabIndex);
|
||||
}
|
||||
});
|
||||
this.fileInfoTotal = this.fileInfoTotal.filter(
|
||||
fInfo => fInfo.info.seq !== fileInfo.info.seq
|
||||
);
|
||||
this.onSelectedIndexChange(this.currentTabIndex);
|
||||
}
|
||||
}
|
||||
|
||||
get fileRetentionPeriodOptions(): DateOptions {
|
||||
|
@ -13,8 +13,11 @@ import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
||||
import { DialogService } from '@ucap-webmessenger/ui';
|
||||
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||
import { MessageApiService, NoticeList } from '@ucap-webmessenger/api-message';
|
||||
import { RetrieveNoticeRequest } from 'projects/ucap-webmessenger-api-message/src/lib/apis/notice';
|
||||
import {
|
||||
MessageApiService,
|
||||
NoticeList,
|
||||
RetrieveNoticeRequest
|
||||
} from '@ucap-webmessenger/api-message';
|
||||
import { NGXLogger } from 'ngx-logger';
|
||||
import { MatPaginator } from '@angular/material';
|
||||
import {
|
||||
|
@ -137,93 +137,83 @@ export class RoomUserListComponent implements OnInit, OnDestroy {
|
||||
this.openProfile.emit(userSeq);
|
||||
}
|
||||
|
||||
onClickAddMember() {
|
||||
this.translateService
|
||||
.get('chat.modifyRoomMember')
|
||||
.pipe(take(1))
|
||||
.subscribe(async v => {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.EditChatMember,
|
||||
title: v,
|
||||
curRoomUser: this.userInfoList.filter(
|
||||
user => user.seq !== this.loginRes.userSeq && user.isJoinRoom
|
||||
)
|
||||
}
|
||||
});
|
||||
async onClickAddMember() {
|
||||
const result = await this.dialogService.open<
|
||||
CreateChatDialogComponent,
|
||||
CreateChatDialogData,
|
||||
CreateChatDialogResult
|
||||
>(CreateChatDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.EditChatMember,
|
||||
title: this.translateService.instant('chat.modifyRoomMember'),
|
||||
curRoomUser: this.userInfoList.filter(
|
||||
user => user.seq !== this.loginRes.userSeq && user.isJoinRoom
|
||||
)
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = this.userInfoList.map(userInfo => {
|
||||
if (userInfo.isJoinRoom) {
|
||||
return userInfo.seq;
|
||||
}
|
||||
});
|
||||
if (!!result.selectedUserList && result.selectedUserList.length > 0) {
|
||||
result.selectedUserList.forEach(user => {
|
||||
if (userSeqs.indexOf(user.seq) < 0) {
|
||||
userSeqs.push(user.seq);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (userSeqs.length > 0) {
|
||||
// include me
|
||||
userSeqs.push(this.loginRes.userSeq);
|
||||
|
||||
this.store.dispatch(
|
||||
RoomStore.inviteOrOpen({
|
||||
req: {
|
||||
divCd: 'Invite',
|
||||
userSeqs
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
const userSeqs: number[] = this.userInfoList.map(userInfo => {
|
||||
if (userInfo.isJoinRoom) {
|
||||
return userInfo.seq;
|
||||
}
|
||||
});
|
||||
if (!!result.selectedUserList && result.selectedUserList.length > 0) {
|
||||
result.selectedUserList.forEach(user => {
|
||||
if (userSeqs.indexOf(user.seq) < 0) {
|
||||
userSeqs.push(user.seq);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (userSeqs.length > 0) {
|
||||
// include me
|
||||
userSeqs.push(this.loginRes.userSeq);
|
||||
|
||||
this.store.dispatch(
|
||||
RoomStore.inviteOrOpen({
|
||||
req: {
|
||||
divCd: 'Invite',
|
||||
userSeqs
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onClickAddGroup() {
|
||||
this.translateService
|
||||
.get('group.selectTargetGroup')
|
||||
.pipe(take(1))
|
||||
.subscribe(async v => {
|
||||
const result = await this.dialogService.open<
|
||||
SelectGroupDialogComponent,
|
||||
SelectGroupDialogData,
|
||||
SelectGroupDialogResult
|
||||
>(SelectGroupDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: v
|
||||
}
|
||||
});
|
||||
async onClickAddGroup() {
|
||||
const result = await this.dialogService.open<
|
||||
SelectGroupDialogComponent,
|
||||
SelectGroupDialogData,
|
||||
SelectGroupDialogResult
|
||||
>(SelectGroupDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: this.translateService.instant('group.selectTargetGroup')
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (!!result.group) {
|
||||
const oldGroup: GroupDetailData = result.group;
|
||||
const trgtUserSeq: number[] = [];
|
||||
result.group.userSeqs.map(seq => trgtUserSeq.push(seq));
|
||||
this.userInfoList
|
||||
.filter(v => result.group.userSeqs.indexOf(v.seq) < 0)
|
||||
.forEach(user => {
|
||||
trgtUserSeq.push(user.seq);
|
||||
});
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
if (!!result.group) {
|
||||
const oldGroup: GroupDetailData = result.group;
|
||||
const trgtUserSeq: number[] = [];
|
||||
result.group.userSeqs.map(seq => trgtUserSeq.push(seq));
|
||||
this.userInfoList
|
||||
.filter(v => result.group.userSeqs.indexOf(v.seq) < 0)
|
||||
.forEach(user => {
|
||||
trgtUserSeq.push(user.seq);
|
||||
});
|
||||
|
||||
this.store.dispatch(
|
||||
SyncStore.updateGroupMember({
|
||||
oldGroup,
|
||||
trgtUserSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
this.store.dispatch(
|
||||
SyncStore.updateGroupMember({
|
||||
oldGroup,
|
||||
trgtUserSeq
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onContextMenuRoomUser(event: MouseEvent, buddy: UserInfo) {
|
||||
@ -241,40 +231,35 @@ export class RoomUserListComponent implements OnInit, OnDestroy {
|
||||
this.roomUserContextMenuTrigger.openMenu();
|
||||
}
|
||||
|
||||
onClickContextMenu(type: string, buddy: UserInfo) {
|
||||
async onClickContextMenu(type: string, buddy: UserInfo) {
|
||||
switch (type) {
|
||||
case 'FORCING_EXIT':
|
||||
{
|
||||
this.translateService
|
||||
.get(['chat.ejectFromRoom', 'chat.confirmEjectFromRoom'], {
|
||||
targetMember: buddy.name
|
||||
})
|
||||
.pipe(take(1))
|
||||
.subscribe(async vs => {
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: vs['chat.ejectFromRoom'],
|
||||
html: vs['chat.confirmEjectFromRoom']
|
||||
}
|
||||
});
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
ConfirmDialogData,
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: this.translateService.instant('chat.ejectFromRoom'),
|
||||
html: this.translateService.instant('chat.confirmEjectFromRoom', {
|
||||
targetMember: buddy.name
|
||||
})
|
||||
}
|
||||
});
|
||||
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
RoomStore.exitForcing({
|
||||
req: {
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
senderSeq: this.loginRes.userSeq,
|
||||
type: 'A',
|
||||
userSeqs: [buddy.seq]
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
});
|
||||
if (!!result && !!result.choice && result.choice) {
|
||||
this.store.dispatch(
|
||||
RoomStore.exitForcing({
|
||||
req: {
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
senderSeq: this.loginRes.userSeq,
|
||||
type: 'A',
|
||||
userSeqs: [buddy.seq]
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
<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-title>{{ 'accounts.changePassword' | translate }}</mat-card-title>
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
<div fxFlex class="setting-tab">
|
||||
@ -18,7 +18,7 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
취소
|
||||
{{ 'common.messages.cancel' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -10,7 +10,7 @@
|
||||
</mat-card-content>
|
||||
<mat-card-actions class="button-farm flex-row">
|
||||
<button mat-stroked-button (click)="onClickConfirm()" class="mat-primary">
|
||||
Confirm
|
||||
{{ 'common.messages.confirm' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -113,7 +113,7 @@
|
||||
{{ 'common.searchResult' | translate }}
|
||||
<span class="text-accent-color">
|
||||
({{ searchUserInfos.length
|
||||
}}{{ 'common.howManyPersons' | translate }})
|
||||
}}{{ 'common.units.persons' | translate }})
|
||||
</span>
|
||||
</div>
|
||||
<ucap-profile-user-list-item
|
||||
@ -196,7 +196,7 @@
|
||||
</div>
|
||||
<span *ngIf="isShowSelectedUserList"
|
||||
>{{ selectedUserList.length }}
|
||||
{{ 'common.howManyPersons' | translate }}</span
|
||||
{{ 'common.units.persons' | translate }}</span
|
||||
>
|
||||
</div>
|
||||
</mat-card-content>
|
||||
@ -206,7 +206,7 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
No
|
||||
{{ 'common.messages.no' | translate }}
|
||||
</button>
|
||||
<button
|
||||
mat-flat-button
|
||||
@ -214,7 +214,7 @@
|
||||
(click)="onClickChoice(true)"
|
||||
class="mat-primary"
|
||||
>
|
||||
Yes
|
||||
{{ 'common.messages.yes' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -15,7 +15,7 @@ import {
|
||||
} from '@angular/material';
|
||||
import { NGXLogger } from 'ngx-logger';
|
||||
import { Observable, combineLatest, Subscription, of } from 'rxjs';
|
||||
import { map, tap, catchError } from 'rxjs/operators';
|
||||
import { map, tap, catchError, take } from 'rxjs/operators';
|
||||
|
||||
import { Store, select } from '@ngrx/store';
|
||||
import * as AppStore from '@app/store';
|
||||
@ -46,7 +46,8 @@ import {
|
||||
import {
|
||||
RoomInfo,
|
||||
UserInfoShort,
|
||||
UserInfo as RoomUserInfo
|
||||
UserInfo as RoomUserInfo,
|
||||
RoomType
|
||||
} from '@ucap-webmessenger/protocol-room';
|
||||
import {
|
||||
ConfirmDialogComponent,
|
||||
@ -57,6 +58,7 @@ import {
|
||||
AlertDialogResult,
|
||||
AlertDialogData
|
||||
} from '@ucap-webmessenger/ui';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
export interface CreateChatDialogData {
|
||||
type?: string;
|
||||
@ -107,6 +109,7 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
private formBuilder: FormBuilder,
|
||||
private logger: NGXLogger,
|
||||
private dialogService: DialogService,
|
||||
private translateService: TranslateService,
|
||||
private changeDetectorRef: ChangeDetectorRef
|
||||
) {
|
||||
this.sessionVerinfo = this.sessionStorageService.get<VersionInfo2Response>(
|
||||
@ -545,6 +548,10 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
}
|
||||
}
|
||||
onToggleRoom(roomInfo: RoomInfo) {
|
||||
if (!this.getCheckableRoom(roomInfo)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!!this.selectedRoom) {
|
||||
if (this.selectedRoom.roomSeq === roomInfo.roomSeq) {
|
||||
this.selectedRoom = null;
|
||||
@ -589,6 +596,16 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
// .length > 0
|
||||
// );
|
||||
// }
|
||||
if (
|
||||
roomInfo.roomType === RoomType.Bot ||
|
||||
roomInfo.roomType === RoomType.Allim ||
|
||||
roomInfo.roomType === RoomType.Link ||
|
||||
roomInfo.roomType === RoomType.Allim_Elephant ||
|
||||
roomInfo.roomType === RoomType.Allim_TMS
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
getCheckedRoom(roomInfo: RoomInfo) {
|
||||
@ -609,6 +626,12 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
getBtnValid() {
|
||||
if (this.data.type === UserSelectDialogType.NewGroup) {
|
||||
return this.inputForm.invalid;
|
||||
} else if (this.data.type === UserSelectDialogType.MessageForward) {
|
||||
if (this.selectedUserList.length === 0 && !this.selectedRoom) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
@ -629,8 +652,8 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `그룹명은 필수입력입니다.`
|
||||
title: this.translateService.instant('group.errors.label'),
|
||||
html: this.translateService.instant('group.errors.requireName')
|
||||
}
|
||||
});
|
||||
|
||||
@ -638,9 +661,11 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
return;
|
||||
}
|
||||
|
||||
let cfmMsg = `새로운 그룹을 추가하시겠습니까?`;
|
||||
let cfmMsg: string;
|
||||
if (this.selectedUserList.length === 0) {
|
||||
cfmMsg += `<br/>빈 그룹으로 생성됩니다.`;
|
||||
cfmMsg = this.translateService.instant('group.confirmAddNewWithout');
|
||||
} else {
|
||||
cfmMsg = this.translateService.instant('group.confirmAddNew');
|
||||
}
|
||||
const result = await this.dialogService.open<
|
||||
ConfirmDialogComponent,
|
||||
@ -649,7 +674,7 @@ export class CreateChatDialogComponent implements OnInit, OnDestroy {
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '400px',
|
||||
data: {
|
||||
title: 'Confirm',
|
||||
title: this.translateService.instant('group.addNew'),
|
||||
html: cfmMsg
|
||||
}
|
||||
});
|
||||
|
@ -10,26 +10,30 @@
|
||||
matInput
|
||||
#input
|
||||
maxlength="20"
|
||||
placeholder="대화방이름"
|
||||
placeholder="{{ 'chat.nameOfRoom' | translate }}"
|
||||
formControlName="roomName"
|
||||
/>
|
||||
<mat-hint align="end">{{ input.value?.length || 0 }}/20</mat-hint>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="targetSelect">
|
||||
<span>변경 대상자</span>
|
||||
<span>{{ 'chat.scopeOfChangeNameOfRoom' | translate }}</span>
|
||||
<mat-radio-group
|
||||
aria-label="Select an option"
|
||||
value="me"
|
||||
formControlName="changeTarget"
|
||||
>
|
||||
<mat-radio-button value="me">나</mat-radio-button>
|
||||
<mat-radio-button value="all">전체</mat-radio-button>
|
||||
<mat-radio-button value="me">{{
|
||||
'common.pronoun.me' | translate
|
||||
}}</mat-radio-button>
|
||||
<mat-radio-button value="all">{{
|
||||
'common.pronoun.all' | translate
|
||||
}}</mat-radio-button>
|
||||
</mat-radio-group>
|
||||
</div>
|
||||
<div *ngIf="data.roomInfo.isTimeRoom">
|
||||
<mat-form-field>
|
||||
<mat-label>Setting Timer</mat-label>
|
||||
<mat-label>{{ 'chat.setTimer' | translate }}</mat-label>
|
||||
<mat-select formControlName="timerInterval">
|
||||
<mat-option *ngFor="let timer of timerArray" [value]="timer.value">
|
||||
{{ timer.text }}
|
||||
@ -45,7 +49,7 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
No
|
||||
{{ 'common.messages.no' | translate }}
|
||||
</button>
|
||||
<button
|
||||
mat-flat-button
|
||||
@ -53,7 +57,7 @@
|
||||
(click)="onClickChoice(true)"
|
||||
class="mat-primary"
|
||||
>
|
||||
Yes
|
||||
{{ 'common.messages.yes' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -1,7 +1,10 @@
|
||||
import { RoomInfo } from '@ucap-webmessenger/protocol-room';
|
||||
import { Component, OnInit, Inject } from '@angular/core';
|
||||
import { Component, OnInit, Inject, OnDestroy } from '@angular/core';
|
||||
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
|
||||
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
import { take } from 'rxjs/operators';
|
||||
import { Subscription } from 'rxjs';
|
||||
|
||||
export interface EditChatRoomDialogData {
|
||||
title: string;
|
||||
@ -21,23 +24,13 @@ export interface EditChatRoomDialogResult {
|
||||
templateUrl: './edit-chat-room.dialog.component.html',
|
||||
styleUrls: ['./edit-chat-room.dialog.component.scss']
|
||||
})
|
||||
export class EditChatRoomDialogComponent implements OnInit {
|
||||
export class EditChatRoomDialogComponent implements OnInit, OnDestroy {
|
||||
roomName: string;
|
||||
inputForm: FormGroup;
|
||||
|
||||
timerArray: { value: number; text: string }[] = [
|
||||
{ value: 5, text: '5 초' },
|
||||
{ value: 10, text: '10 초' },
|
||||
{ value: 30, text: '30 초' },
|
||||
{ value: 60, text: '1 분' },
|
||||
{ value: 300, text: '5 분' },
|
||||
{ value: 600, text: '10 분' },
|
||||
{ value: 1800, text: '30 분' },
|
||||
{ value: 3600, text: '1 시간' },
|
||||
{ value: 21600, text: '6 시간' },
|
||||
{ value: 43200, text: '12 시간' },
|
||||
{ value: 86400, text: '24 시간' }
|
||||
];
|
||||
timerArray: { value: number; text: string }[];
|
||||
|
||||
unitsI18nSubscription: Subscription;
|
||||
|
||||
constructor(
|
||||
public dialogRef: MatDialogRef<
|
||||
@ -45,7 +38,8 @@ export class EditChatRoomDialogComponent implements OnInit {
|
||||
EditChatRoomDialogResult
|
||||
>,
|
||||
@Inject(MAT_DIALOG_DATA) public data: EditChatRoomDialogData,
|
||||
private formBuilder: FormBuilder
|
||||
private formBuilder: FormBuilder,
|
||||
private translateService: TranslateService
|
||||
) {}
|
||||
|
||||
ngOnInit(): void {
|
||||
@ -57,6 +51,35 @@ export class EditChatRoomDialogComponent implements OnInit {
|
||||
changeTarget: ['me'],
|
||||
timerInterval: [this.data.roomInfo.timeRoomInterval]
|
||||
});
|
||||
|
||||
this.unitsI18nSubscription = this.translateService
|
||||
.get([
|
||||
'common.units.hourFrom',
|
||||
'common.units.minute',
|
||||
'common.units.second'
|
||||
])
|
||||
.pipe(take(1))
|
||||
.subscribe(vs => {
|
||||
this.timerArray = [
|
||||
{ value: 5, text: `5 ${vs['common.units.second']}` },
|
||||
{ value: 10, text: `10 ${vs['common.units.second']}` },
|
||||
{ value: 30, text: `30 ${vs['common.units.second']}` },
|
||||
{ value: 60, text: `1 ${vs['common.units.minute']}` },
|
||||
{ value: 300, text: `5 ${vs['common.units.minute']}` },
|
||||
{ value: 600, text: `10 ${vs['common.units.minute']}` },
|
||||
{ value: 1800, text: `30 ${vs['common.units.minute']}` },
|
||||
{ value: 3600, text: `1 ${vs['common.units.hourFrom']}` },
|
||||
{ value: 21600, text: `6 ${vs['common.units.hourFrom']}` },
|
||||
{ value: 43200, text: `12 ${vs['common.units.hourFrom']}` },
|
||||
{ value: 86400, text: `24 ${vs['common.units.hourFrom']}` }
|
||||
];
|
||||
});
|
||||
}
|
||||
|
||||
ngOnDestroy(): void {
|
||||
if (!!this.unitsI18nSubscription) {
|
||||
this.unitsI18nSubscription.unsubscribe();
|
||||
}
|
||||
}
|
||||
|
||||
onClickChoice(choice: boolean): void {
|
||||
|
@ -9,7 +9,7 @@
|
||||
</mat-card-content>
|
||||
<mat-card-actions class="button-farm flex-row">
|
||||
<button mat-stroked-button (click)="onClickConfirm()" class="mat-primary">
|
||||
confirm
|
||||
{{ 'common.messages.confirm' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -4,12 +4,17 @@
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
<form name="inputForm" [formGroup]="inputForm" novalidate>
|
||||
<mat-form-field hintLabel="특수문자는 '-,_'만 사용할 수 있습니다.">
|
||||
<mat-form-field
|
||||
hintLabel="{{
|
||||
'common.useOnlyForSpecialCharacter'
|
||||
| translate: { specialCharacter: '-,_' }
|
||||
}}"
|
||||
>
|
||||
<input
|
||||
matInput
|
||||
#input
|
||||
maxlength="20"
|
||||
placeholder="그룹이름"
|
||||
placeholder="{{ 'group.name' | translate }}"
|
||||
formControlName="groupName"
|
||||
/>
|
||||
<mat-hint align="end">{{ input.value?.length || 0 }}/20</mat-hint>
|
||||
@ -22,10 +27,10 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
No
|
||||
{{ 'common.messages.no' | translate }}
|
||||
</button>
|
||||
<button mat-flat-button (click)="onClickChoice(true)" class="mat-primary">
|
||||
Yes
|
||||
{{ 'common.messages.yes' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
</mat-card>
|
||||
|
@ -14,13 +14,18 @@
|
||||
<span class="mat-fab__label">{{ 'group.addNew' | translate }}</span>
|
||||
</button>
|
||||
<div *ngIf="isShowAddGroupField" class="input-groupname-box">
|
||||
<mat-form-field hintLabel="특수문자는 '-,_'만 사용할 수 있습니다.">
|
||||
<mat-form-field
|
||||
hintLabel="{{
|
||||
'common.useOnlyForSpecialCharacter'
|
||||
| translate: { specialCharacter: '-,_' }
|
||||
}}"
|
||||
>
|
||||
<input
|
||||
matInput
|
||||
#inputGroupName
|
||||
type="text"
|
||||
maxlength="20"
|
||||
placeholder="그룹이름"
|
||||
placeholder="{{ 'group.name' | translate }}"
|
||||
value=""
|
||||
/>
|
||||
|
||||
@ -41,7 +46,7 @@
|
||||
|
||||
<div class="btn-box">
|
||||
<button mat-stroked-button (click)="onClickAddGroupCancel()">
|
||||
닫기
|
||||
{{ 'common.messages.close' | translate }}
|
||||
</button>
|
||||
<button
|
||||
mat-stroked-button
|
||||
@ -49,7 +54,7 @@
|
||||
(click)="onClickAddGroup(inputGroupName.value)"
|
||||
class="mat-accent"
|
||||
>
|
||||
그룹명 추가
|
||||
{{ 'group.addNew' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
@ -61,7 +66,8 @@
|
||||
>
|
||||
<span class="title-name ellipsis"> {{ groupBuddy.group.name }} </span>
|
||||
<span class="text-accent-color number"
|
||||
>({{ groupBuddy.buddyList.length }}명)</span
|
||||
>({{ groupBuddy.buddyList.length
|
||||
}}{{ 'common.units.persons' | translate }})</span
|
||||
>
|
||||
</mat-list-option>
|
||||
</mat-selection-list>
|
||||
@ -80,10 +86,10 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
No
|
||||
{{ 'common.messages.no' | translate }}
|
||||
</button>
|
||||
<button mat-flat-button (click)="onClickChoice(true)" class="mat-primary">
|
||||
Yes
|
||||
{{ 'common.messages.yes' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -7,7 +7,7 @@ import {
|
||||
} from '@angular/material';
|
||||
import { Observable, combineLatest } from 'rxjs';
|
||||
import { Store, select } from '@ngrx/store';
|
||||
import { map } from 'rxjs/operators';
|
||||
import { map, take } from 'rxjs/operators';
|
||||
|
||||
import * as AppStore from '@app/store';
|
||||
import * as SyncStore from '@app/store/messenger/sync';
|
||||
@ -20,6 +20,7 @@ import {
|
||||
} from '@ucap-webmessenger/ui';
|
||||
import { GroupDetailData, UserInfo } from '@ucap-webmessenger/protocol-sync';
|
||||
import { environment } from '../../../../../environments/environment';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
export interface SelectGroupDialogData {
|
||||
title: string;
|
||||
@ -43,7 +44,8 @@ export class SelectGroupDialogComponent implements OnInit {
|
||||
>,
|
||||
@Inject(MAT_DIALOG_DATA) public data: SelectGroupDialogData,
|
||||
private store: Store<any>,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
private translateService: TranslateService
|
||||
) {}
|
||||
|
||||
@ViewChild('groups', { static: true }) groups: MatSelectionList;
|
||||
@ -109,8 +111,10 @@ export class SelectGroupDialogComponent implements OnInit {
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '300px',
|
||||
data: {
|
||||
title: 'Add group',
|
||||
html: `그룹(${groupName})을 추가하시겠습니까?`
|
||||
title: this.translateService.instant('group.addNew'),
|
||||
html: this.translateService.instant('group.confirmAddNewWith', {
|
||||
nameOfGroup: groupName
|
||||
})
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -2,9 +2,15 @@
|
||||
<mat-card-header>
|
||||
<mat-card-title>
|
||||
<ng-container [ngSwitch]="messageInfo.type">
|
||||
<span *ngSwitchCase="MessageType.Receive">받은 쪽지</span>
|
||||
<span *ngSwitchCase="MessageType.Send">보낸 쪽지</span>
|
||||
<span *ngSwitchCase="MessageType.Reservation">예약 쪽지</span>
|
||||
<span *ngSwitchCase="MessageType.Receive">{{
|
||||
'message.messageTypeReceiving' | translate
|
||||
}}</span>
|
||||
<span *ngSwitchCase="MessageType.Send">{{
|
||||
'message.messageTypeOutgoing' | translate
|
||||
}}</span>
|
||||
<span *ngSwitchCase="MessageType.Reservation">{{
|
||||
'message.messageTypeReservation' | translate
|
||||
}}</span>
|
||||
</ng-container>
|
||||
</mat-card-title>
|
||||
</mat-card-header>
|
||||
@ -27,7 +33,6 @@
|
||||
<span
|
||||
*ngIf="messageInfo.type === MessageType.Receive"
|
||||
class="people sender bg-accent-color"
|
||||
alt="보낸사람"
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
@ -47,7 +52,6 @@
|
||||
<span
|
||||
*ngIf="messageInfo.type !== MessageType.Receive"
|
||||
class="people receiver bg-accent-color"
|
||||
alt="받는사람"
|
||||
>
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
@ -85,17 +89,17 @@
|
||||
<span
|
||||
*ngIf="messageInfo.type === MessageType.Receive"
|
||||
class="label bg-warn-color "
|
||||
>받은시간</span
|
||||
>{{ 'message.receivedTime' | translate }}</span
|
||||
>
|
||||
<span
|
||||
*ngIf="messageInfo.type === MessageType.Send"
|
||||
class="label bg-warn-color "
|
||||
>보낸시간</span
|
||||
>{{ 'message.sendingTime' | translate }}</span
|
||||
>
|
||||
<span
|
||||
*ngIf="messageInfo.type === MessageType.Reservation"
|
||||
class="label bg-warn-color "
|
||||
>발송예정시간</span
|
||||
>{{ 'message.reservationTime' | translate }}</span
|
||||
>
|
||||
<span *ngIf="messageInfo.type !== MessageType.Reservation">{{
|
||||
messageInfo.regDate | ucapDate: 'YYYY.MM.DD (ddd) a hh:mm'
|
||||
@ -123,13 +127,15 @@
|
||||
<div *ngIf="attachFile && attachFile.length > 0" class="attachFile">
|
||||
<div>
|
||||
<div class="title">
|
||||
<span *ngIf="isExpiredAttachFile">기간이 만료된 파일입니다</span>
|
||||
<span *ngIf="isExpiredAttachFile">{{
|
||||
'common.file.errors.expired' | translate
|
||||
}}</span>
|
||||
<button
|
||||
mat-stroked-button
|
||||
class="mat-primary"
|
||||
(click)="downloadAttachFileAll()"
|
||||
>
|
||||
모두저장
|
||||
{{ 'common.file.saveAll' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@ -161,7 +167,8 @@
|
||||
>
|
||||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
읽은 사람 {{ getReadUserCount(true) }}
|
||||
{{ 'message.countOfReadUser' | translate }}
|
||||
{{ getReadUserCount(true) }}
|
||||
</ng-template>
|
||||
<mat-list>
|
||||
<ng-container *ngFor="let user of receivers">
|
||||
@ -176,11 +183,12 @@
|
||||
</mat-tab>
|
||||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
읽지 않은 사람 {{ getReadUserCount(true) }}
|
||||
{{ 'message.countOfUnreadUser' | translate }}
|
||||
{{ getReadUserCount(true) }}
|
||||
</ng-template>
|
||||
<ul>
|
||||
<div>
|
||||
전체선택
|
||||
{{ 'common.messages.selectAll' | translate }}
|
||||
<mat-checkbox
|
||||
#checkbox
|
||||
(change)="
|
||||
@ -210,7 +218,7 @@
|
||||
"
|
||||
class="mat-primary"
|
||||
>
|
||||
발송취소
|
||||
{{ 'message.cancelReservation' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
</ul>
|
||||
@ -237,21 +245,21 @@
|
||||
*ngIf="messageInfo.type === MessageType.Send"
|
||||
(click)="onClickMessageMenu('MESSAGE_READ')"
|
||||
>
|
||||
<span>읽음확인</span>
|
||||
<span>{{ 'message.detailOfViewers' | translate }}</span>
|
||||
</button>
|
||||
<button
|
||||
mat-menu-item
|
||||
*ngIf="messageInfo.type === MessageType.Reservation"
|
||||
(click)="onClickMessageMenu('MESSAGE_CANCEL')"
|
||||
>
|
||||
<span>발송취소</span>
|
||||
<span>{{ 'message.cancelReservation' | translate }}</span>
|
||||
</button>
|
||||
<button
|
||||
mat-menu-item
|
||||
*ngIf="messageInfo.type === MessageType.Reservation"
|
||||
(click)="onClickMessageMenu('MESSAGE_UPDATE')"
|
||||
>
|
||||
<span>수정</span>
|
||||
<span>{{ 'common.messages.modify' | translate }}</span>
|
||||
</button>
|
||||
<button
|
||||
mat-menu-item
|
||||
@ -261,6 +269,6 @@
|
||||
"
|
||||
(click)="onClickMessageMenu('MESSAGE_DEL')"
|
||||
>
|
||||
<span>삭제</span>
|
||||
<span>{{ 'common.messages.remove' | translate }}</span>
|
||||
</button>
|
||||
</mat-menu>
|
||||
|
@ -40,6 +40,7 @@ import {
|
||||
MessageWriteDialogData
|
||||
} from './message-write.dialog.component';
|
||||
import { EnvironmentsInfo } from '@app/types';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
export interface MessageDetailDialogData {
|
||||
detail: DetailResponse;
|
||||
@ -91,7 +92,8 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
private messageApiService: MessageApiService,
|
||||
private snackBarService: SnackBarService,
|
||||
private logger: NGXLogger,
|
||||
private dialogService: DialogService
|
||||
private dialogService: DialogService,
|
||||
private translateService: TranslateService
|
||||
) {}
|
||||
|
||||
ngOnInit(): void {
|
||||
@ -300,7 +302,9 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `다운로드가 진행중입니다.`
|
||||
html: this.translateService.instant(
|
||||
'common.file.results.downloadInProgress'
|
||||
)
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -378,12 +382,16 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
attachFile.downloadType === 'SINGLE'
|
||||
) {
|
||||
// single :: fail
|
||||
errMsg = '파일 저장에 실패하였습니다.';
|
||||
errMsg = this.translateService.instant(
|
||||
'common.file.errors.failToSave'
|
||||
);
|
||||
} else {
|
||||
// all
|
||||
errMsg = '일부 저장중 오류가 발생하였습니다.';
|
||||
errMsg = this.translateService.instant(
|
||||
'common.file.errors.failToSaveSomeOfAll'
|
||||
);
|
||||
}
|
||||
this.snackBarService.open(errMsg, '확인', {
|
||||
this.snackBarService.open(errMsg, '', {
|
||||
duration: 8000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
@ -395,7 +403,10 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
) {
|
||||
// single :: success
|
||||
this.snackBarService.open(
|
||||
`파일이 경로[${attachFile.downloadType}]에 저장되었습니다.`,
|
||||
this.translateService.instant(
|
||||
'common.file.errors.savedToPath',
|
||||
{ path: attachFile.downloadType }
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
@ -404,10 +415,16 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
);
|
||||
} else {
|
||||
// all
|
||||
this.snackBarService.open('모두 저장하였습니다.', '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'common.file.errors.savedAll'
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
this.downloadProgress = false;
|
||||
@ -433,8 +450,10 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: '발송취소',
|
||||
html: `예약발송을 취소 하시겠습니까?<br/>취소하면 목록에서도 영구 삭제됩니다.`
|
||||
title: this.translateService.instant('message.cancelReservation'),
|
||||
html: this.translateService.instant(
|
||||
'message.confirmCancelReservation'
|
||||
)
|
||||
}
|
||||
});
|
||||
|
||||
@ -454,8 +473,8 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: '삭제',
|
||||
message: '선택한 쪽지를 삭제하시겠습니까?'
|
||||
title: this.translateService.instant('message.remove'),
|
||||
message: this.translateService.instant('message.confirmRemove')
|
||||
}
|
||||
});
|
||||
|
||||
@ -524,9 +543,8 @@ export class MessageDetailDialogComponent implements OnInit {
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: '발송 취소',
|
||||
message:
|
||||
'발송 취소를 하시면 받는 사람의 쪽지함에서 쪽지가 삭제됩니다.'
|
||||
title: this.translateService.instant('message.cancelSending'),
|
||||
message: this.translateService.instant('message.confirmCancelSending')
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -1,6 +1,8 @@
|
||||
<mat-card class="confirm-card mat-elevation-z">
|
||||
<mat-card-header>
|
||||
<mat-card-title> 쪽지 {{ isModify ? '수정' : '보내기' }} </mat-card-title>
|
||||
<mat-card-title>
|
||||
{{ (isModify ? 'message.modify' : 'message.sendTo') | translate }}
|
||||
</mat-card-title>
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
<ucap-message-write
|
||||
|
@ -28,6 +28,7 @@ import {
|
||||
import { UserSelectDialogType, EnvironmentsInfo } from '@app/types';
|
||||
import { take } from 'rxjs/operators';
|
||||
import { UserInfoSS } from '@ucap-webmessenger/protocol-query';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
export interface MessageWriteDialogData {
|
||||
loginRes: LoginResponse;
|
||||
@ -66,6 +67,7 @@ export class MessageWriteDialogComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public data: MessageWriteDialogData,
|
||||
private messageApiService: MessageApiService,
|
||||
private snackBarService: SnackBarService,
|
||||
private translateService: TranslateService,
|
||||
private logger: NGXLogger,
|
||||
private dialogService: DialogService
|
||||
) {}
|
||||
@ -85,7 +87,7 @@ export class MessageWriteDialogComponent implements OnInit {
|
||||
width: '600px',
|
||||
data: {
|
||||
type: UserSelectDialogType.EditChatMember,
|
||||
title: '쪽지 수신자 선택',
|
||||
title: this.translateService.instant('message.selectRecipient'),
|
||||
curRoomUser: receiverList
|
||||
}
|
||||
});
|
||||
@ -122,9 +124,13 @@ export class MessageWriteDialogComponent implements OnInit {
|
||||
res => {
|
||||
let msg = '';
|
||||
if (!!message.reservationTime) {
|
||||
msg = `쪽지 전송을 예약 하였습니다.`;
|
||||
msg = this.translateService.instant(
|
||||
'message.results.successForReservation'
|
||||
);
|
||||
} else {
|
||||
msg = `쪽지를 전송하였습니다.`;
|
||||
msg = this.translateService.instant(
|
||||
'message.results.successForSending'
|
||||
);
|
||||
}
|
||||
|
||||
this.snackBarService.open(msg, '', {
|
||||
@ -135,10 +141,15 @@ export class MessageWriteDialogComponent implements OnInit {
|
||||
this.dialogRef.close({ sendFlag: true, sendType: message.type });
|
||||
},
|
||||
error => {
|
||||
this.snackBarService.open(`쪽지를 전송에 실패 하였습니다.`, '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant('message.errors.failToSending'),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
|
||||
// this.dialogRef.close({});
|
||||
}
|
||||
);
|
||||
@ -155,18 +166,29 @@ export class MessageWriteDialogComponent implements OnInit {
|
||||
.pipe(take(1))
|
||||
.subscribe(
|
||||
res => {
|
||||
this.snackBarService.open('쪽지를 수정하였습니다.', '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant(
|
||||
'message.results.successForModifying'
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
|
||||
this.dialogRef.close({ sendFlag: true, sendType: message.type });
|
||||
},
|
||||
error => {
|
||||
this.snackBarService.open(`쪽지 수정에 실패 하였습니다.`, '', {
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
});
|
||||
this.snackBarService.open(
|
||||
this.translateService.instant('message.errors.failToModify'),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
verticalPosition: 'bottom'
|
||||
}
|
||||
);
|
||||
|
||||
// this.dialogRef.close({});
|
||||
}
|
||||
);
|
||||
|
@ -1,7 +1,9 @@
|
||||
<mat-card class="confirm-card mat-elevation-z">
|
||||
<mat-card-header>
|
||||
<mat-card-title class="title">
|
||||
<span *ngIf="data.notice.topYn"> [중요] </span>
|
||||
<span *ngIf="data.notice.topYn">
|
||||
[{{ 'notice.important' | translate }}]
|
||||
</span>
|
||||
{{ data.notice.title }}
|
||||
</mat-card-title>
|
||||
</mat-card-header>
|
||||
@ -15,7 +17,7 @@
|
||||
</mat-card-content>
|
||||
<mat-card-actions class="button-farm flex-row">
|
||||
<button mat-stroked-button (click)="onClickConfirm()" class="mat-primary">
|
||||
confirm
|
||||
{{ 'common.messages.confirm' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -15,7 +15,7 @@
|
||||
(change)="onCheckAllUser(checkbox.checked)"
|
||||
(click)="$event.stopPropagation()"
|
||||
>
|
||||
전체선택
|
||||
{{ 'common.messages.selectAll' | translate }}
|
||||
</mat-checkbox>
|
||||
</mat-card-title>
|
||||
</mat-card-header>
|
||||
@ -57,10 +57,10 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
취소
|
||||
{{ 'common.messages.cancel' | translate }}
|
||||
</button>
|
||||
<button mat-flat-button (click)="onClickChoice(true)" class="mat-primary">
|
||||
적용
|
||||
{{ 'common.messages.apply' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -52,6 +52,7 @@ import { NGXLogger } from 'ngx-logger';
|
||||
import { SmsUtils } from '@ucap-webmessenger/daesang';
|
||||
import { NativeService, UCAP_NATIVE_SERVICE } from '@ucap-webmessenger/native';
|
||||
import { environment } from '../../../../../environments/environment';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
export interface ProfileDialogData {
|
||||
userInfo: UserInfo | UserInfoSS | UserInfoF | UserInfoDN;
|
||||
@ -87,6 +88,7 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
private commonApiService: CommonApiService,
|
||||
private callService: CallService,
|
||||
private snackBarService: SnackBarService,
|
||||
private translateService: TranslateService,
|
||||
private store: Store<any>,
|
||||
private logger: NGXLogger
|
||||
) {
|
||||
@ -174,10 +176,11 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `전화를 걸 수 없는 사용자 입니다.`
|
||||
title: this.translateService.instant('call.errors.label'),
|
||||
html: this.translateService.instant('call.errors.cannotCallToUser')
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -191,8 +194,10 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: '전화 걸기',
|
||||
html: `${calleeNumber}로 전화를 거시겠습니까?`
|
||||
title: this.translateService.instant('call.callTo'),
|
||||
html: this.translateService.instant('call.callWithNumber', {
|
||||
phoneNumber: calleeNumber
|
||||
})
|
||||
}
|
||||
});
|
||||
|
||||
@ -225,8 +230,10 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `상대방 번호가 없어 전화를 걸 수 없습니다.`
|
||||
title: this.translateService.instant('call.errors.label'),
|
||||
html: this.translateService.instant(
|
||||
'call.errors.cannotCallToUserWithoutPhomeNumber'
|
||||
)
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -244,8 +251,8 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `SMS 사용 권한이 없습니다.`
|
||||
title: this.translateService.instant('sms.errors.label'),
|
||||
html: this.translateService.instant('sms.errors.haveNoPermission')
|
||||
}
|
||||
});
|
||||
return false;
|
||||
@ -287,7 +294,7 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
>(SelectGroupDialogComponent, {
|
||||
width: '600px',
|
||||
data: {
|
||||
title: 'Group Select'
|
||||
title: this.translateService.instant('group.selectTargetGroup')
|
||||
}
|
||||
});
|
||||
|
||||
@ -315,8 +322,11 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: 'Delete Buddy',
|
||||
html: `[${param.userInfo.name} ${param.userInfo.grade}]를 그룹에서 삭제하시겠습니까?<br/>프로필에서 삭제하면 모든 그룹에서 삭제됩니다.`
|
||||
title: this.translateService.instant('group.removeBuddyFromGroup'),
|
||||
html: this.translateService.instant(
|
||||
'group.confirmRemoveBuddyFromGroup',
|
||||
{ target: `${param.userInfo.name} ${param.userInfo.grade}` }
|
||||
)
|
||||
}
|
||||
});
|
||||
|
||||
@ -378,7 +388,9 @@ export class ProfileDialogComponent implements OnInit, OnDestroy {
|
||||
},
|
||||
error => {
|
||||
this.snackBarService.open(
|
||||
`프로필 이미지 변경중에 문제가 발생하였습니다.`,
|
||||
this.translateService.instant(
|
||||
'profile.errors.failToChangeProfileImage'
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
|
@ -1,6 +1,6 @@
|
||||
<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-title>{{ 'settings.label' | translate }}</mat-card-title>
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
<div fxFlex class="setting-tab">
|
||||
@ -8,7 +8,7 @@
|
||||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
<span class="mdi mdi-settings"></span>
|
||||
일반
|
||||
{{ 'settings.typeGenernal' | translate }}
|
||||
</ng-template>
|
||||
|
||||
<ucap-settings-general
|
||||
@ -29,7 +29,7 @@
|
||||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
<span class="mdi mdi-bell"></span>
|
||||
알림
|
||||
{{ 'settings.typeNotification' | translate }}
|
||||
</ng-template>
|
||||
<ucap-settings-notification
|
||||
[setting]="appUserInfo.settings.notification"
|
||||
@ -63,7 +63,7 @@
|
||||
<mat-tab>
|
||||
<ng-template mat-tab-label>
|
||||
<span class="mdi mdi-chat"></span>
|
||||
대화
|
||||
{{ 'settings.typeChat' | translate }}
|
||||
</ng-template>
|
||||
<ucap-settings-chat
|
||||
[setting]="appUserInfo.settings.chat"
|
||||
@ -115,10 +115,10 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
No
|
||||
{{ 'common.messages.no' | translate }}
|
||||
</button>
|
||||
<button mat-flat-button (click)="onClickChoice(true)" class="mat-primary">
|
||||
Yes
|
||||
{{ 'common.messages.yes' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -242,7 +242,6 @@
|
||||
stroke-width="2"
|
||||
stroke-linecap="butt"
|
||||
stroke-linejoin="round"
|
||||
alt="창 최소화"
|
||||
>
|
||||
<line x1="5" y1="18" x2="19" y2="18"></line>
|
||||
</svg>
|
||||
@ -265,7 +264,6 @@
|
||||
stroke-linecap="butt"
|
||||
stroke-linejoin="round"
|
||||
*ngSwitchCase="WindowState.Maximized"
|
||||
alt="창 이전크기"
|
||||
>
|
||||
<path
|
||||
class="st0"
|
||||
@ -289,7 +287,6 @@
|
||||
stroke-linecap="butt"
|
||||
stroke-linejoin="round"
|
||||
*ngSwitchDefault
|
||||
alt="창크기 최대"
|
||||
>
|
||||
<rect x="5" y="5" width="12" height="12" rx="2" ry="2"></rect>
|
||||
</svg>
|
||||
@ -311,7 +308,6 @@
|
||||
stroke-width="2"
|
||||
stroke-linecap="butt"
|
||||
stroke-linejoin="round"
|
||||
alt="창닫기"
|
||||
>
|
||||
<line x1="18" y1="6" x2="6" y2="18"></line>
|
||||
<line x1="6" y1="6" x2="18" y2="18"></line>
|
||||
@ -332,7 +328,7 @@
|
||||
</div>
|
||||
<div class="setting">
|
||||
<button mat-menu-item (click)="onClickOpenProfile($event)">
|
||||
프로필 보기
|
||||
{{ 'profile.open' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<!-- <div class="setting">
|
||||
@ -352,23 +348,33 @@
|
||||
</button>
|
||||
</div> -->
|
||||
<div class="setting">
|
||||
<button mat-menu-item (click)="onClickNotice()">공지사항</button>
|
||||
<button mat-menu-item (click)="onClickNotice()">
|
||||
{{ 'notice.label' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<div class="setting">
|
||||
<button mat-menu-item (click)="onClickSettings()">설정</button>
|
||||
<button mat-menu-item (click)="onClickSettings()">
|
||||
{{ 'settings.label' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<mat-divider></mat-divider>
|
||||
<div class="setting">
|
||||
<button mat-menu-item (click)="onClickLogout()">로그아웃</button>
|
||||
<button mat-menu-item (click)="onClickLogout()">
|
||||
{{ 'accounts.logout' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
</mat-menu>
|
||||
|
||||
<mat-menu #presenseMenu="matMenu" class="status-pc-set">
|
||||
<div class="setting">
|
||||
<button mat-menu-item><span class="presence pcOn"> </span>온라인</button>
|
||||
<button mat-menu-item>
|
||||
<span class="presence pcOn"> </span>{{ 'presence.online' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
<div class="setting">
|
||||
<button mat-menu-item><span class="presence pcOut"> </span>부재중</button
|
||||
<button mat-menu-item>
|
||||
<span class="presence pcOut"> </span
|
||||
>{{ 'presence.offline' | translate }}</button
|
||||
><button mat-menu-item class="clock"></button>
|
||||
</div>
|
||||
<div class="setting">
|
||||
|
@ -113,9 +113,7 @@ export class TopBarComponent implements OnInit, OnDestroy {
|
||||
>(KEY_VER_INFO);
|
||||
|
||||
// WebLink init..
|
||||
if (!this.weblink || this.weblink.length === 0) {
|
||||
this.initWebLink();
|
||||
}
|
||||
this.initWebLink();
|
||||
})
|
||||
)
|
||||
.subscribe();
|
||||
|
@ -8,6 +8,8 @@ import { MatIconModule } from '@angular/material/icon';
|
||||
import { MatMenuModule } from '@angular/material/menu';
|
||||
import { MatToolbarModule } from '@angular/material/toolbar';
|
||||
|
||||
import { TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
import { UCapUiModule } from '@ucap-webmessenger/ui';
|
||||
import { UCapUiProfileModule } from '@ucap-webmessenger/ui-profile';
|
||||
|
||||
@ -25,6 +27,8 @@ import { MatTooltipModule, MatBadgeModule } from '@angular/material';
|
||||
MatMenuModule,
|
||||
MatBadgeModule,
|
||||
|
||||
TranslateModule,
|
||||
|
||||
UCapUiModule,
|
||||
UCapUiProfileModule
|
||||
],
|
||||
|
@ -37,6 +37,7 @@
|
||||
<app-layout-messenger-messages
|
||||
*ngIf="!!(this.selectedChat$ | async)"
|
||||
(openProfile)="onClickOpenProfile($event)"
|
||||
(closeRightDrawer)="onCloseRightDrawer()"
|
||||
></app-layout-messenger-messages>
|
||||
</div>
|
||||
<mat-drawer
|
||||
|
@ -46,6 +46,7 @@ import {
|
||||
import { MessageType } from '@ucap-webmessenger/api-message';
|
||||
import { AppUserInfo, KEY_APP_USER_INFO } from '@app/types/app-user-info.type';
|
||||
import { environment } from '../../../../environments/environment';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Component({
|
||||
selector: 'app-page-messenger-main',
|
||||
@ -77,6 +78,7 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
||||
private callService: CallService,
|
||||
private localStorageService: LocalStorageService,
|
||||
private sessionStorageService: SessionStorageService,
|
||||
private translateService: TranslateService,
|
||||
private dialogService: DialogService,
|
||||
private logger: NGXLogger
|
||||
) {
|
||||
@ -274,10 +276,11 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `전화를 걸 수 없는 사용자 입니다.`
|
||||
title: this.translateService.instant('call.errors.label'),
|
||||
html: this.translateService.instant('call.errors.cannotCallToUser')
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -291,8 +294,10 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
||||
>(ConfirmDialogComponent, {
|
||||
width: '360px',
|
||||
data: {
|
||||
title: '전화 걸기',
|
||||
html: `${calleeNumber}로 전화를 거시겠습니까?`
|
||||
title: this.translateService.instant('call.callTo'),
|
||||
html: this.translateService.instant('call.callWithNumber', {
|
||||
phoneNumber: calleeNumber
|
||||
})
|
||||
}
|
||||
});
|
||||
|
||||
@ -320,8 +325,10 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `상대방 번호가 없어 전화를 걸 수 없습니다.`
|
||||
title: this.translateService.instant('call.errors.label'),
|
||||
html: this.translateService.instant(
|
||||
'call.errors.cannotCallToUserWithoutPhomeNumber'
|
||||
)
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -339,10 +346,11 @@ export class MainPageComponent implements OnInit, OnDestroy {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `SMS 사용 권한이 없습니다.`
|
||||
title: this.translateService.instant('sms.errors.label'),
|
||||
html: this.translateService.instant('sms.errors.haveNoPermission')
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { delGroupSuccess, buddy2 } from './../store/messenger/sync/actions';
|
||||
import { Injectable, Inject } from '@angular/core';
|
||||
|
||||
import { tap, withLatestFrom } from 'rxjs/operators';
|
||||
import { tap, withLatestFrom, take } from 'rxjs/operators';
|
||||
|
||||
import { Store, select } from '@ngrx/store';
|
||||
|
||||
@ -109,6 +109,7 @@ import { NotificationMethod } from '@ucap-webmessenger/core';
|
||||
import { Dictionary } from '@ngrx/entity';
|
||||
import { MessageType } from '@ucap-webmessenger/api-message';
|
||||
import { LogoutInfo, KEY_LOGOUT_INFO } from '@app/types';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Injectable()
|
||||
export class AppNotificationService {
|
||||
@ -120,6 +121,7 @@ export class AppNotificationService {
|
||||
private groupProtocolService: GroupProtocolService,
|
||||
private buddyProtocolService: BuddyProtocolService,
|
||||
private statusProtocolService: StatusProtocolService,
|
||||
private translateService: TranslateService,
|
||||
private umgProtocolService: UmgProtocolService,
|
||||
private localStorageService: LocalStorageService,
|
||||
private sessionStorageService: SessionStorageService,
|
||||
@ -235,7 +237,9 @@ export class AppNotificationService {
|
||||
const notiReq: NotificationRequest = {
|
||||
type: NotificationType.Event,
|
||||
seq: noti.roomSeq,
|
||||
title: '메세지가 도착했습니다.',
|
||||
title: this.translateService.instant(
|
||||
'notification.titleChatEventArrived'
|
||||
),
|
||||
contents: StringUtil.convertFinalEventMessage(
|
||||
noti.eventType,
|
||||
noti.info.sentMessageJson
|
||||
@ -611,7 +615,9 @@ export class AppNotificationService {
|
||||
const notiReq: NotificationRequest = {
|
||||
type: NotificationType.Message,
|
||||
seq: noti.keyId,
|
||||
title: '쪽지가 도착했습니다.',
|
||||
title: this.translateService.instant(
|
||||
'notification.titleMessageArrived'
|
||||
),
|
||||
contents: noti.text,
|
||||
image: noti.senderInfo.profileImageFile,
|
||||
useSound: [
|
||||
|
@ -68,11 +68,7 @@ import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||
import { ProtocolService } from '@ucap-webmessenger/protocol';
|
||||
|
||||
import { environment } from '../../../../environments/environment';
|
||||
import {
|
||||
ChangePasswordDialogComponent,
|
||||
ChangePasswordDialogData,
|
||||
ChangePasswordDialogResult
|
||||
} from '@app/layouts/messenger/dialogs/account/change-password.dialog.component';
|
||||
|
||||
import {
|
||||
ServiceProtocolService,
|
||||
UserPasswordSetResponse
|
||||
@ -80,6 +76,7 @@ import {
|
||||
import { DaesangUrlInfoResponse } from '@ucap-webmessenger/api-external';
|
||||
import { AppUserInfo, KEY_APP_USER_INFO } from '@app/types/app-user-info.type';
|
||||
import { DaesangCipherService, WebLinkType } from '@ucap-webmessenger/daesang';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Injectable()
|
||||
export class Effects {
|
||||
@ -205,8 +202,8 @@ export class Effects {
|
||||
ConfirmDialogResult
|
||||
>(ConfirmDialogComponent, {
|
||||
data: {
|
||||
title: 'Logout',
|
||||
message: '로그아웃 하시겠습니까?'
|
||||
title: this.translateService.instant('accounts.logout'),
|
||||
message: this.translateService.instant('accounts.confirmLogout')
|
||||
}
|
||||
});
|
||||
|
||||
@ -259,7 +256,9 @@ export class Effects {
|
||||
height: '500px',
|
||||
disableClose: true,
|
||||
data: {
|
||||
title: '개인정보 동의',
|
||||
title: this.translateService.instant(
|
||||
'accounts.consentOfPrivacy'
|
||||
),
|
||||
html: `<iframe id="ifm_privacy" src="${privacyTotalUrl}" style="width: 100%;height: 300px;" />`
|
||||
}
|
||||
});
|
||||
@ -288,7 +287,7 @@ export class Effects {
|
||||
height: '500px',
|
||||
disableClose: true,
|
||||
data: {
|
||||
title: '패스워드 초기화',
|
||||
title: this.translateService.instant('accounts.resetPassword'),
|
||||
html: `<iframe id="ifm_privacy" src="${passwordInitStep1Url}" style="width: 100%;height: 300px;" />`
|
||||
}
|
||||
});
|
||||
@ -311,8 +310,12 @@ export class Effects {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '비밀번호 만기',
|
||||
html: `비밀번호가 만료되었습니다.<br/>비밀번호 변경 후 다시 로그인 하세요.`
|
||||
title: this.translateService.instant(
|
||||
'accounts.passwordExpired'
|
||||
),
|
||||
html: this.translateService.instant(
|
||||
'accounts.descriptionOfPasswordExpired'
|
||||
)
|
||||
}
|
||||
});
|
||||
|
||||
@ -444,8 +447,10 @@ export class Effects {
|
||||
width: '360px',
|
||||
disableClose: true,
|
||||
data: {
|
||||
title: '비밀번호 변경',
|
||||
message: '비밀번호가 변경되었습니다. 다시 로그인하여 주십시오'
|
||||
title: this.translateService.instant('accounts.changePassword'),
|
||||
message: this.translateService.instant(
|
||||
'accounts.results.changedPassword'
|
||||
)
|
||||
}
|
||||
});
|
||||
|
||||
@ -462,7 +467,9 @@ export class Effects {
|
||||
ofType(userPasswordSetFailure),
|
||||
tap(action => {
|
||||
this.snackBarService.open(
|
||||
`비밀번호 변경 중에 문제가 발생하였습니다.`,
|
||||
this.translateService.instant(
|
||||
'accounts.errors.failToChangePassword'
|
||||
),
|
||||
'',
|
||||
{
|
||||
duration: 3000,
|
||||
@ -487,6 +494,7 @@ export class Effects {
|
||||
private protocolService: ProtocolService,
|
||||
private authenticationProtocolService: AuthenticationProtocolService,
|
||||
private serviceProtocolService: ServiceProtocolService,
|
||||
private translateService: TranslateService,
|
||||
private dialogService: DialogService,
|
||||
private snackBarService: SnackBarService,
|
||||
@Inject(UCAP_NATIVE_SERVICE) private nativeService: NativeService,
|
||||
|
@ -1,17 +1,16 @@
|
||||
import { Injectable, Inject } from '@angular/core';
|
||||
import { Injectable } from '@angular/core';
|
||||
|
||||
import { Actions, ofType, createEffect } from '@ngrx/effects';
|
||||
|
||||
import { Store } from '@ngrx/store';
|
||||
|
||||
import { NGXLogger } from 'ngx-logger';
|
||||
import { catchError, exhaustMap, map, tap, switchMap } from 'rxjs/operators';
|
||||
import { catchError, exhaustMap, map } from 'rxjs/operators';
|
||||
import {
|
||||
selectedMassDetail,
|
||||
massTalkDownload,
|
||||
massTalkDownloadFailure,
|
||||
massTalkDownloadSuccess,
|
||||
clearSelectedRoom
|
||||
massTalkDownloadSuccess
|
||||
} from './actions';
|
||||
import { of } from 'rxjs';
|
||||
import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
||||
@ -20,16 +19,12 @@ import { CommonApiService } from '@ucap-webmessenger/api-common';
|
||||
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||
import { EnvironmentsInfo, KEY_ENVIRONMENTS_INFO } from '@app/types';
|
||||
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||
import {
|
||||
DialogService,
|
||||
AlertDialogComponent,
|
||||
AlertDialogData
|
||||
} from '@ucap-webmessenger/ui';
|
||||
import { initialState } from '../event';
|
||||
import { DialogService } from '@ucap-webmessenger/ui';
|
||||
import {
|
||||
MassDetailComponent,
|
||||
MassDetailDialogData
|
||||
} from '@app/layouts/messenger/dialogs/chat/mass-detail.component';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Injectable()
|
||||
export class Effects {
|
||||
@ -73,7 +68,7 @@ export class Effects {
|
||||
disableClose: false,
|
||||
width: '550px',
|
||||
data: {
|
||||
title: 'Detail View',
|
||||
title: this.translateService.instant('chat.detailView'),
|
||||
contents: res.content
|
||||
}
|
||||
});
|
||||
@ -94,6 +89,7 @@ export class Effects {
|
||||
private commonApiService: CommonApiService,
|
||||
private sessionStorageService: SessionStorageService,
|
||||
private dialogService: DialogService,
|
||||
private translateService: TranslateService,
|
||||
private store: Store<any>,
|
||||
private logger: NGXLogger
|
||||
) {}
|
||||
|
@ -1,6 +1,7 @@
|
||||
import {
|
||||
CommonApiService,
|
||||
MassTalkSaveRequest
|
||||
MassTalkSaveRequest,
|
||||
FileTalkShareRequest
|
||||
} from '@ucap-webmessenger/api-common';
|
||||
import { KEY_ENVIRONMENTS_INFO } from './../../../types/environment.type';
|
||||
import { Injectable } from '@angular/core';
|
||||
@ -19,7 +20,8 @@ import {
|
||||
catchError,
|
||||
exhaustMap,
|
||||
withLatestFrom,
|
||||
concatMap
|
||||
concatMap,
|
||||
take
|
||||
} from 'rxjs/operators';
|
||||
import moment from 'moment';
|
||||
import {
|
||||
@ -43,7 +45,8 @@ import {
|
||||
FileEventJson,
|
||||
MassTextEventJson,
|
||||
TranslationEventJson,
|
||||
MassTranslationEventJson
|
||||
MassTranslationEventJson,
|
||||
decodeFileEventJson
|
||||
} from '@ucap-webmessenger/protocol-event';
|
||||
|
||||
import * as ChatStore from '@app/store/messenger/chat';
|
||||
@ -83,7 +86,8 @@ import {
|
||||
roomOpenAfterForward,
|
||||
infoForSearch,
|
||||
infoForSearchEnd,
|
||||
infoAll
|
||||
infoAll,
|
||||
forwardFailure
|
||||
} from './actions';
|
||||
import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
||||
import {
|
||||
@ -110,13 +114,13 @@ import {
|
||||
FileType
|
||||
} from '@ucap-webmessenger/protocol-file';
|
||||
import { environment } from '../../../../environments/environment';
|
||||
import { RoomUserData } from '@ucap-webmessenger/protocol-sync';
|
||||
import {
|
||||
AlertDialogComponent,
|
||||
AlertDialogResult,
|
||||
AlertDialogData,
|
||||
DialogService
|
||||
} from '@ucap-webmessenger/ui';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Injectable()
|
||||
export class Effects {
|
||||
@ -371,7 +375,9 @@ export class Effects {
|
||||
disableClose: true,
|
||||
data: {
|
||||
title: '',
|
||||
message: '더이상 검색할 내용이 없습니다.'
|
||||
message: this.translateService.instant(
|
||||
'chat.noMoreEvents'
|
||||
)
|
||||
}
|
||||
});
|
||||
}
|
||||
@ -661,8 +667,52 @@ export class Effects {
|
||||
ofType(forward),
|
||||
tap(action => {
|
||||
if (!!action.trgtRoomSeq) {
|
||||
// 대화전달 후 방오픈.
|
||||
this.store.dispatch(roomOpenAfterForward(action));
|
||||
// 대화전달 후 방오픈. Exist roomSeq.
|
||||
if (action.req.eventType === EventType.File) {
|
||||
const loginResInfo: LoginResponse = this.sessionStorageService.get<
|
||||
LoginResponse
|
||||
>(KEY_LOGIN_RES_INFO);
|
||||
|
||||
const environmentsInfo = this.sessionStorageService.get<
|
||||
EnvironmentsInfo
|
||||
>(KEY_ENVIRONMENTS_INFO);
|
||||
|
||||
const fileEventJson: FileEventJson = decodeFileEventJson(
|
||||
action.req.sentMessage
|
||||
);
|
||||
const req: FileTalkShareRequest = {
|
||||
userSeq: loginResInfo.userSeq,
|
||||
deviceType: environmentsInfo.deviceType,
|
||||
token: loginResInfo.tokenString,
|
||||
attachmentsSeq: fileEventJson.attachmentSeq.toString(),
|
||||
roomSeq: action.trgtRoomSeq,
|
||||
synapKey: ''
|
||||
};
|
||||
this.commonApiService
|
||||
.fileTalkShare(req)
|
||||
.pipe(
|
||||
take(1),
|
||||
map(res => {
|
||||
if (res.statusCode === StatusCode.Success) {
|
||||
action = {
|
||||
...action,
|
||||
req: {
|
||||
...action.req,
|
||||
sentMessage: res.returnJson
|
||||
}
|
||||
};
|
||||
|
||||
this.store.dispatch(roomOpenAfterForward(action));
|
||||
} else {
|
||||
this.store.dispatch(forwardFailure({ error: res }));
|
||||
}
|
||||
}),
|
||||
catchError(error => of(forwardFailure({ error })))
|
||||
)
|
||||
.subscribe();
|
||||
} else {
|
||||
this.store.dispatch(roomOpenAfterForward(action));
|
||||
}
|
||||
} else if (!!action.trgtUserSeqs && action.trgtUserSeqs.length > 0) {
|
||||
// 방오픈 후 대화전달.
|
||||
this.store.dispatch(forwardAfterRoomOpen(action));
|
||||
@ -687,16 +737,70 @@ export class Effects {
|
||||
return openSuccess({ res });
|
||||
}),
|
||||
map(res => {
|
||||
this.store.dispatch(
|
||||
send({
|
||||
senderSeq: action.senderSeq,
|
||||
req: {
|
||||
roomSeq: res.res.roomSeq,
|
||||
eventType: action.req.eventType,
|
||||
sentMessage: action.req.sentMessage
|
||||
}
|
||||
})
|
||||
);
|
||||
if (action.req.eventType === EventType.File) {
|
||||
const loginResInfo: LoginResponse = this.sessionStorageService.get<
|
||||
LoginResponse
|
||||
>(KEY_LOGIN_RES_INFO);
|
||||
|
||||
const environmentsInfo = this.sessionStorageService.get<
|
||||
EnvironmentsInfo
|
||||
>(KEY_ENVIRONMENTS_INFO);
|
||||
|
||||
const fileEventJson: FileEventJson = decodeFileEventJson(
|
||||
action.req.sentMessage
|
||||
);
|
||||
const req: FileTalkShareRequest = {
|
||||
userSeq: loginResInfo.userSeq,
|
||||
deviceType: environmentsInfo.deviceType,
|
||||
token: loginResInfo.tokenString,
|
||||
attachmentsSeq: fileEventJson.attachmentSeq.toString(),
|
||||
roomSeq: action.trgtRoomSeq,
|
||||
synapKey: ''
|
||||
};
|
||||
this.commonApiService
|
||||
.fileTalkShare(req)
|
||||
.pipe(
|
||||
take(1),
|
||||
map(resFileShare => {
|
||||
if (resFileShare.statusCode === StatusCode.Success) {
|
||||
action = {
|
||||
...action,
|
||||
req: {
|
||||
...action.req,
|
||||
sentMessage: resFileShare.returnJson
|
||||
}
|
||||
};
|
||||
|
||||
this.store.dispatch(
|
||||
send({
|
||||
senderSeq: action.senderSeq,
|
||||
req: {
|
||||
roomSeq: res.res.roomSeq,
|
||||
eventType: action.req.eventType,
|
||||
sentMessage: action.req.sentMessage
|
||||
}
|
||||
})
|
||||
);
|
||||
} else {
|
||||
this.store.dispatch(forwardFailure({ error: res }));
|
||||
}
|
||||
}),
|
||||
catchError(error => of(forwardFailure({ error })))
|
||||
)
|
||||
.subscribe();
|
||||
} else {
|
||||
this.store.dispatch(
|
||||
send({
|
||||
senderSeq: action.senderSeq,
|
||||
req: {
|
||||
roomSeq: res.res.roomSeq,
|
||||
eventType: action.req.eventType,
|
||||
sentMessage: action.req.sentMessage
|
||||
}
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
return res;
|
||||
}),
|
||||
catchError(error => of(openFailure({ error })))
|
||||
@ -958,6 +1062,7 @@ export class Effects {
|
||||
private fileProtocolService: FileProtocolService,
|
||||
private roomProtocolService: RoomProtocolService,
|
||||
private sessionStorageService: SessionStorageService,
|
||||
private translateService: TranslateService,
|
||||
private dialogService: DialogService,
|
||||
private logger: NGXLogger
|
||||
) {}
|
||||
|
@ -7,36 +7,14 @@ import { Store, select } from '@ngrx/store';
|
||||
import { NGXLogger } from 'ngx-logger';
|
||||
|
||||
import { of } from 'rxjs';
|
||||
import {
|
||||
tap,
|
||||
switchMap,
|
||||
map,
|
||||
catchError,
|
||||
exhaustMap,
|
||||
withLatestFrom,
|
||||
concatMap,
|
||||
take
|
||||
} from 'rxjs/operators';
|
||||
import moment from 'moment';
|
||||
|
||||
import * as ChatStore from '@app/store/messenger/chat';
|
||||
import * as RoomStore from '@app/store/messenger/room';
|
||||
import * as SyncStore from '@app/store/messenger/sync';
|
||||
import { switchMap, map, catchError, withLatestFrom } from 'rxjs/operators';
|
||||
|
||||
import { SessionStorageService } from '@ucap-webmessenger/web-storage';
|
||||
import { KEY_ENVIRONMENTS_INFO } from './../../../types/environment.type';
|
||||
import { LoginInfo, KEY_LOGIN_INFO, EnvironmentsInfo } from '@app/types';
|
||||
import { Dictionary } from '@ngrx/entity';
|
||||
import { EnvironmentsInfo } from '@app/types';
|
||||
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||
import { MessageStatusCode } from '@ucap-webmessenger/api';
|
||||
import { environment } from '../../../../environments/environment';
|
||||
import {
|
||||
AlertDialogComponent,
|
||||
AlertDialogResult,
|
||||
AlertDialogData,
|
||||
DialogService
|
||||
} from '@ucap-webmessenger/ui';
|
||||
import { DialogService } from '@ucap-webmessenger/ui';
|
||||
import {
|
||||
retrieveMessage,
|
||||
retrieveMessageFailure,
|
||||
@ -65,14 +43,9 @@ import {
|
||||
MessageSearchType,
|
||||
DelRequest,
|
||||
CancelReservationRequest,
|
||||
DetailRequest
|
||||
DetailRequest,
|
||||
UnreadCountRequest
|
||||
} from '@ucap-webmessenger/api-message';
|
||||
import { UnreadCountRequest } from 'projects/ucap-webmessenger-api-message/src/lib/apis/unread-count';
|
||||
import {
|
||||
MessageDetailDialogComponent,
|
||||
MessageDetailDialogResult,
|
||||
MessageDetailDialogData
|
||||
} from '@app/layouts/messenger/dialogs/message/message-detail.dialog.component';
|
||||
|
||||
@Injectable()
|
||||
export class Effects {
|
||||
|
@ -112,6 +112,7 @@ import {
|
||||
AlertDialogData
|
||||
} from '@ucap-webmessenger/ui';
|
||||
import { UserInfoSS } from '@ucap-webmessenger/protocol-query';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Injectable()
|
||||
export class Effects {
|
||||
@ -422,8 +423,14 @@ export class Effects {
|
||||
AlertDialogResult
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: '',
|
||||
html: `${environment.productConfig.CommonSetting.maxChatRoomUser}명 이상 대화할 수 없습니다.`
|
||||
title: this.translateService.instant('chat.errors.label'),
|
||||
html: this.translateService.instant(
|
||||
'chat.errors.maxCountOfRoomMemberWith',
|
||||
{
|
||||
maxCount:
|
||||
environment.productConfig.CommonSetting.maxChatRoomUser
|
||||
}
|
||||
)
|
||||
}
|
||||
});
|
||||
return;
|
||||
@ -1095,6 +1102,7 @@ export class Effects {
|
||||
private groupProtocolService: GroupProtocolService,
|
||||
private buddyProtocolService: BuddyProtocolService,
|
||||
private sessionStorageService: SessionStorageService,
|
||||
private translateService: TranslateService,
|
||||
private dialogService: DialogService,
|
||||
private logger: NGXLogger
|
||||
) {}
|
||||
|
@ -1,6 +1,62 @@
|
||||
{
|
||||
"accounts": {
|
||||
"instructionsOfLogin": "LOGIN TO YOUR ACCOUNT",
|
||||
"login": "Login",
|
||||
"logout": "Logout",
|
||||
"fieldCompany": "Company",
|
||||
"fieldLoginId": "Login ID",
|
||||
"fieldLoginPw": "Login password",
|
||||
"fieldPassword": "Password",
|
||||
"fieldCurrentPassword": "Current password",
|
||||
"fieldNewPassword": "New password",
|
||||
"fieldNewPasswordConfirm": "New password confirm",
|
||||
"rememberMe": "Remember me",
|
||||
"autoLogin": "Auto login",
|
||||
"consentOfPrivacy": "Agreement of ",
|
||||
"changePassword": "Change password",
|
||||
"resetPassword": "Reset password",
|
||||
"passwordExpired": "Password expired",
|
||||
"descriptionOfPasswordExpired": "Password has expired.<br/>Please change your password and log in again.",
|
||||
"confirmLogout": "Do you want to log out?",
|
||||
"results": {
|
||||
"changedPassword": "Password changed. Please log in again."
|
||||
},
|
||||
"errors": {
|
||||
"requireLoginId": "Login ID is required.",
|
||||
"requireLoginPw": "Login password is required.",
|
||||
"requireCompany": "Company is required.",
|
||||
"requireCurrentPassword": "Current password is required.",
|
||||
"notSameWithCurrentPassword": "Does not match current password",
|
||||
"sameWithCurrentPassword": "Same as current password",
|
||||
"requireNewPassword": "New password is required.",
|
||||
"requireNewPasswordConfirm": "New password confirm is required.",
|
||||
"notSameWithNewPassword": "Does not match new password and new password confirm.",
|
||||
"notContainSpacesForPassword": "Passwords cannot contain spaces",
|
||||
"notContainUseridForPassword": "User ID cannot be included in the password",
|
||||
"notContainPhonenumberForPassword": "Your mobile phone number cannot be included in your password",
|
||||
"notAllowedAlphaNumOver3TimesForPassword": "You can't use numbers or letters over 3 times.",
|
||||
"notAllowedConsecutiveAlphaNumOver3TimesForPassword": "You cannot use consecutive numbers or letters more than 3 times.",
|
||||
"notSatisfiedCombineForPassword": "Combination of two or more kinds of letters, numbers and special characters.",
|
||||
"minLengthCombineForPassword": "Password must be {{lengthOfPassword}} characters if {{countOfCombine}} combination.",
|
||||
"failToChangePassword": "Failed to change password."
|
||||
}
|
||||
},
|
||||
"profile": {
|
||||
"open": "Open profile"
|
||||
"open": "Open profile",
|
||||
"errors": {
|
||||
"label": "Profile error",
|
||||
"failToChangeProfileImage": "Failed to change profile image."
|
||||
}
|
||||
},
|
||||
"settings": {
|
||||
"label": "Settings",
|
||||
"typeGenernal": "Genernal",
|
||||
"typeNotification": "Notification",
|
||||
"typeChat": "Chat"
|
||||
},
|
||||
"presence": {
|
||||
"online": "Online",
|
||||
"offline": "Offline"
|
||||
},
|
||||
"group": {
|
||||
"label": "Group",
|
||||
@ -21,13 +77,24 @@
|
||||
"removeGroup": "Remove group",
|
||||
"startChatWithGroup": "Chat with group",
|
||||
"sendMessageToGroup": "Send message to group",
|
||||
"selectTargetGroup": "Select target group"
|
||||
"selectTargetGroup": "Select target group",
|
||||
"confirmAddNew": "Do you want to add a new group?",
|
||||
"confirmAddNewWith": "Do you want to add a new ({{nameOfGroup}}) group?",
|
||||
"confirmAddNewWithout": "Do you want to add a new group?<br/>Created as an empty group.",
|
||||
"confirmRemoveBuddyFromGroup": "Do you want to remove [{{target}}] from group?<br/>Deleting it from your profile will remove it from all groups.",
|
||||
"errors": {
|
||||
"label": "Group errors",
|
||||
"requireName": "Group name is required."
|
||||
}
|
||||
},
|
||||
"chat": {
|
||||
"label": "Chat",
|
||||
"room": "Chat room",
|
||||
"send": "Send",
|
||||
"searchRoomByName": "Search by room name",
|
||||
"searchEventByText": "Search by chat",
|
||||
"nameOfRoom": "Name of chat room",
|
||||
"scopeOfChangeNameOfRoom": "Scope of Changing",
|
||||
"newTimerChat": "New Timer Chat",
|
||||
"newChat": "New Chat",
|
||||
"startChat": "Chat",
|
||||
@ -68,9 +135,12 @@
|
||||
"errors": {
|
||||
"label": "Chat erros",
|
||||
"inputChatMessage": "Please enter a chat message",
|
||||
"maxLengthOfMassText": "If you include a sticker, you can't send more than {{maxLength}} characters."
|
||||
"maxLengthOfMassText": "If you include a sticker, you can't send more than {{maxLength}} characters.",
|
||||
"maxCountOfRoomMemberWith": "you can't open room with more than {{maxCount}} peoples."
|
||||
},
|
||||
"detailView": "Detail View"
|
||||
"noMoreEvents": "There is no more messages",
|
||||
"detailView": "Detail View",
|
||||
"setTimer": "Set timer"
|
||||
},
|
||||
"organization": {
|
||||
"chart": "Organization chart",
|
||||
@ -84,7 +154,9 @@
|
||||
},
|
||||
"message": {
|
||||
"label": "Message",
|
||||
"newMessage": "New message",
|
||||
"new": "New message",
|
||||
"remove": "Remove message",
|
||||
"modify": "Modify message",
|
||||
"sendTo": "Send message",
|
||||
"placeholderForSearch": "search for name, title, content",
|
||||
"messageTypeAll": "All",
|
||||
@ -94,26 +166,80 @@
|
||||
"searchTypeName": "Name",
|
||||
"searchTypeTitle": "Title",
|
||||
"searchTypeContent": "Content",
|
||||
"badgeDescriptionForUnread": "There is an unconfirmed message."
|
||||
"sender": "Sender",
|
||||
"receiver": "Receiver",
|
||||
"receivedTime": "Received Time",
|
||||
"sendingTime": "Sending Time",
|
||||
"reservationTime": "Reservation Time",
|
||||
"countOfReadUser": "count of read",
|
||||
"countOfUnreadUser": "count of unread",
|
||||
"badgeDescriptionForUnread": "There is an unconfirmed message.",
|
||||
"cancelReservation": "Cancel reservation",
|
||||
"cancelSending": "Cancel sending",
|
||||
"confirmCancelReservation": "Do you want to cancel reservation?<br/>Canceling will also permanently remove you from the list.",
|
||||
"confirmCancelSending": "If you cancel the shipment, the message will be deleted from the recipient's message box.",
|
||||
"confirmRemove": "Do you want to delete selected message(s)?",
|
||||
"detailOfViewers": "Detail of viewers",
|
||||
"selectRecipient": "Select recipient",
|
||||
"results": {
|
||||
"successForSending": "Your message has been sent.",
|
||||
"successForReservation": "You have scheduled a message transfer.",
|
||||
"successForModifying": "Your message has been modified."
|
||||
},
|
||||
"errors": {
|
||||
"label": "Message error",
|
||||
"failToSending": "The message failed to send.",
|
||||
"failToModify": "The message failed to modify."
|
||||
}
|
||||
},
|
||||
"notice": {
|
||||
"label": "Notice",
|
||||
"fieldTitle": "Title",
|
||||
"fieldPostDate": "Post date"
|
||||
"fieldPostDate": "Post date",
|
||||
"important": "Important"
|
||||
},
|
||||
"call": {
|
||||
"callTo": "Make a call",
|
||||
"callWithNumber": "Do you want to call {{phoneNumber}}?",
|
||||
"errors": {
|
||||
"label": "Call error",
|
||||
"cannotCallToUser": "You cannot call that user.",
|
||||
"cannotCallToUserWithoutPhomeNumber": "You cannot call because you do not have a contact number."
|
||||
}
|
||||
},
|
||||
"sms": {
|
||||
"errors": {
|
||||
"label": "SMS error",
|
||||
"haveNoPermission": "You do not have SMS permissions."
|
||||
}
|
||||
},
|
||||
"notification": {
|
||||
"titleChatEventArrived": "A message of chat has arrived.",
|
||||
"titleMessageArrived": "A message has arrived."
|
||||
},
|
||||
"common": {
|
||||
"search": "Search",
|
||||
"searchWord": "Search word",
|
||||
"searchResult": "Search result",
|
||||
"useOnlyForSpecialCharacter": "Can only use Special characters: {{v}}",
|
||||
"howManyPersons": "person(s)",
|
||||
"units": {
|
||||
"hour": "hour",
|
||||
"hourFrom": "hour",
|
||||
"minute": "minute",
|
||||
"second": "second",
|
||||
"persons": "person(s)"
|
||||
},
|
||||
"file": {
|
||||
"name": "Name of file",
|
||||
"size": "Size of file",
|
||||
"download": "Download",
|
||||
"delete": "Delete",
|
||||
"save": "Save",
|
||||
"saveAll": "Save all",
|
||||
"downloadSelected": "Download selected",
|
||||
"openDownloadFolder": "Open download folder",
|
||||
"selectFiles": "Select files",
|
||||
"dropZoneForUpload": "Drop files here to upload.",
|
||||
"type": {
|
||||
"label": "Type of file",
|
||||
"images": "Images",
|
||||
@ -121,13 +247,19 @@
|
||||
},
|
||||
"results": {
|
||||
"saved": "The file has been saved.",
|
||||
"savedToPath": "The file has been saved to path[{{path}}]."
|
||||
"savedAll": "All file(s) have(has) been saved.",
|
||||
"savedToPath": "The file has been saved to path[{{path}}].",
|
||||
"downloadInProgress": "Download is in progress."
|
||||
},
|
||||
"errors": {
|
||||
"label": "File errors",
|
||||
"failToUpload": "File upload failed.",
|
||||
"failToSave": "File save failed.",
|
||||
"failToSpecifyPath": "Specifing of save path failed."
|
||||
"failToSaveSomeOfAll": "Some of file(s) save failed",
|
||||
"failToSpecifyPath": "Specifing of save path failed.",
|
||||
"expired": "This file has expired",
|
||||
"noPreview": "This file does not support preview.",
|
||||
"notSupporedType": "File format is not supported."
|
||||
}
|
||||
},
|
||||
"clipboard": {
|
||||
@ -140,8 +272,21 @@
|
||||
"no": "No",
|
||||
"confirm": "Confirm",
|
||||
"select": "Select",
|
||||
"selectAll": "Select all",
|
||||
"unselect": "Unselect",
|
||||
"searching": "Searching"
|
||||
"searching": "Searching",
|
||||
"cancel": "Cancel",
|
||||
"close": "Close",
|
||||
"modify": "Modify",
|
||||
"remove": "Remove",
|
||||
"apply": "Apply",
|
||||
"minimizeWindow": "Minimize window",
|
||||
"maxmizeWindow": "Maxmize window",
|
||||
"restoreWindow": "Restore window",
|
||||
"Close window": "Close window",
|
||||
"zoomOut": "Zoom out",
|
||||
"zoomIn": "Zoom in",
|
||||
"zoomReset": "Zoom reset"
|
||||
},
|
||||
"paginator": {
|
||||
"itemsPerPage": "Items per page",
|
||||
@ -150,6 +295,20 @@
|
||||
"firstPage": "First page",
|
||||
"lastPage": "Last page"
|
||||
},
|
||||
"player": {
|
||||
"play": "Play",
|
||||
"stop": "Stop"
|
||||
},
|
||||
"pronoun": {
|
||||
"me": "Me",
|
||||
"all": "All"
|
||||
},
|
||||
"translations": {
|
||||
"targetLanguage": "Traget language",
|
||||
"noTranslation": "No translation",
|
||||
"simpleView": "Simple View",
|
||||
"preview": "Preview"
|
||||
},
|
||||
"timezone": {
|
||||
"Africa/Abidjan": "Africa/Abidjan",
|
||||
"Africa/Accra": "Africa/Accra",
|
||||
|
@ -1,6 +1,62 @@
|
||||
{
|
||||
"accounts": {
|
||||
"instructionsOfLogin": "계정에 로그인 하세요.",
|
||||
"login": "로그인",
|
||||
"logout": "로그아웃",
|
||||
"fieldCompany": "회사",
|
||||
"fieldLoginId": "로그인 아이디",
|
||||
"fieldLoginPw": "로그인 비밀번호",
|
||||
"fieldPassword": "비밀번호",
|
||||
"fieldCurrentPassword": "현재 비밀번호",
|
||||
"fieldNewPassword": "신규 비밀번호",
|
||||
"fieldNewPasswordConfirm": "신규 비밀번호 확인",
|
||||
"rememberMe": "아이디 저장",
|
||||
"autoLogin": "자동 로그인",
|
||||
"consentOfPrivacy": "개인정보 동의",
|
||||
"changePassword": "비밀번호 변경",
|
||||
"resetPassword": "비밀번호 초기화",
|
||||
"passwordExpired": "비밀번호 만기",
|
||||
"descriptionOfPasswordExpired": "비밀번호가 만료되었습니다.<br/>비밀번호 변경 후 다시 로그인 하세요.",
|
||||
"confirmLogout": "로그아웃 하시겠습니까?",
|
||||
"results": {
|
||||
"changedPassword": "비밀번호가 변경되었습니다. 다시 로그인하여 주십시오"
|
||||
},
|
||||
"errors": {
|
||||
"requireLoginId": "로그인 아이디를 입력해 주세요.",
|
||||
"requireLoginPw": "로그인 비밀번호를 입력해 주세요.",
|
||||
"requireCompany": "회사를 입력해 주세요.",
|
||||
"requireCurrentPassword": "현재 비밀번호를 입력해 주세요",
|
||||
"notSameWithCurrentPassword": "현재 비밀번호와 일치하지 않습니다",
|
||||
"sameWithCurrentPassword": "현재 비밀번호와 동일합니다",
|
||||
"requireNewPassword": "신규 비밀번호를 입력해 주세요",
|
||||
"requireNewPasswordConfirm": "신규 비밀번호 확인을 입력해 주세요",
|
||||
"notSameWithNewPassword": "신규 비밀번호와 신규 비밀번호 확인이 다릅니다",
|
||||
"notContainSpacesForPassword": "비밀번호에는 공백을 입력할 수 없습니다",
|
||||
"notContainUseridForPassword": "사용자 ID를 비밀번호에 포함할 수 없습니다",
|
||||
"notContainPhonenumberForPassword": "사용자 휴대폰번호를 비밀번호에 포함할 수 없습니다",
|
||||
"notAllowedAlphaNumOver3TimesForPassword": "숫자나 문자를 3번이상 반복적으로 사용할 수 없습니다",
|
||||
"notAllowedConsecutiveAlphaNumOver3TimesForPassword": "연속되는 숫자나 문자를 3번이상 사용할 수 없습니다",
|
||||
"notSatisfiedCombineForPassword": "문자, 숫자, 특수문자 중 2종류 이상 조합을 해야 합니다",
|
||||
"minLengthCombineForPassword": "비밀번호는 {{countOfCombine}}가지가 조합된 경우 {{lengthOfPassword}}자를 넘어야 합니다",
|
||||
"failToChangePassword": "비밀번호 변경에 실패하였습니다."
|
||||
}
|
||||
},
|
||||
"profile": {
|
||||
"open": "프로필 보기"
|
||||
"open": "프로필 보기",
|
||||
"errors": {
|
||||
"label": "프로필 에러",
|
||||
"failToChangeProfileImage": "프로필 이미지 변경에 실패 하였습니다."
|
||||
}
|
||||
},
|
||||
"settings": {
|
||||
"label": "설정",
|
||||
"typeGenernal": "일반",
|
||||
"typeNotification": "알림",
|
||||
"typeChat": "대화"
|
||||
},
|
||||
"presence": {
|
||||
"online": "온라인",
|
||||
"offline": "부재중"
|
||||
},
|
||||
"group": {
|
||||
"label": "그룹",
|
||||
@ -13,7 +69,7 @@
|
||||
"nameDefault": "기본",
|
||||
"favorite": "즐겨찾기 등록",
|
||||
"unfavorite": "즐겨찾기 해제",
|
||||
"removeBuddyFromGroup": "이 그룹에서 삭제",
|
||||
"removeBuddyFromGroup": "그룹에서 삭제",
|
||||
"copyBuddyToGroup": "대화 상대 복사",
|
||||
"moveBuddyToGroup": "대화 상대 이동",
|
||||
"changeGroupName": "그룹 이름 바꾸기",
|
||||
@ -21,13 +77,24 @@
|
||||
"removeGroup": "그룹 삭제",
|
||||
"startChatWithGroup": "그룹 대화하기",
|
||||
"sendMessageToGroup": "그룹 쪽지 보내기",
|
||||
"selectTargetGroup": "대상 그룹 선택"
|
||||
"selectTargetGroup": "대상 그룹 선택",
|
||||
"confirmAddNew": "새로운 그룹을 추가하시겠습니까?",
|
||||
"confirmAddNewWith": "새로운 그룹({{nameOfGroup}})을 추가하시겠습니까?",
|
||||
"confirmAddNewWithout": "새로운 그룹을 추가하시겠습니까?<br/>빈 그룹으로 생성됩니다.",
|
||||
"confirmRemoveBuddyFromGroup": "[{{target}}]를 그룹에서 삭제하시겠습니까?<br/>프로필에서 삭제하면 모든 그룹에서 삭제됩니다.",
|
||||
"errors": {
|
||||
"label": "그룹 에러",
|
||||
"requireName": "그룹명은 필수입력입니다."
|
||||
}
|
||||
},
|
||||
"chat": {
|
||||
"label": "대화",
|
||||
"room": "대화방",
|
||||
"send": "보내기",
|
||||
"searchRoomByName": "대화방 이름 검색",
|
||||
"searchEventByText": "대화 내용 검색",
|
||||
"nameOfRoom": "대화방 이름",
|
||||
"scopeOfChangeNameOfRoom": "변경 범위",
|
||||
"newTimerChat": "새로운 타이머 대화",
|
||||
"newChat": "새로운 대화",
|
||||
"startChat": "대화하기",
|
||||
@ -68,9 +135,12 @@
|
||||
"errors": {
|
||||
"label": "대화 에러",
|
||||
"inputChatMessage": "대화 내용을 입력해 주세요.",
|
||||
"maxLengthOfMassText": "스티커를 포함할 경우 {{maxLength}}자 이상 보낼 수 없습니다."
|
||||
"maxLengthOfMassText": "스티커를 포함할 경우 {{maxLength}}자 이상 보낼 수 없습니다.",
|
||||
"maxCountOfRoomMemberWith": "{{maxCount}}명 이상 대화할 수 없습니다."
|
||||
},
|
||||
"detailView": "상세 보기"
|
||||
"noMoreEvents": "더이상 검색할 내용이 없습니다.",
|
||||
"detailView": "상세 보기",
|
||||
"setTimer": "타이머 설정"
|
||||
},
|
||||
"organization": {
|
||||
"chart": "조직도",
|
||||
@ -84,7 +154,9 @@
|
||||
},
|
||||
"message": {
|
||||
"label": "쪽지",
|
||||
"newMessage": "새로운 쪽지",
|
||||
"new": "새로운 쪽지",
|
||||
"remove": "쪽지 삭제",
|
||||
"modify": "쪽지 수정",
|
||||
"sendTo": "쪽지 보내기",
|
||||
"placeholderForSearch": "이름, 제목, 내용 검색",
|
||||
"messageTypeAll": "전체",
|
||||
@ -94,26 +166,80 @@
|
||||
"searchTypeName": "이름",
|
||||
"searchTypeTitle": "제목",
|
||||
"searchTypeContent": "내용",
|
||||
"badgeDescriptionForUnread": "확인하지 않은 쪽지가 있습니다."
|
||||
"sender": "보낸 사람",
|
||||
"receiver": "받는 사람",
|
||||
"receivedTime": "받은 시간",
|
||||
"sendingTime": "보낸 시간",
|
||||
"reservationTime": "발송 예정 시간",
|
||||
"countOfReadUser": "읽은 사람",
|
||||
"countOfUnreadUser": "읽은 않은 사람",
|
||||
"badgeDescriptionForUnread": "확인하지 않은 쪽지가 있습니다.",
|
||||
"cancelReservation": "예약 발송 취소",
|
||||
"cancelSending": "발송 취소",
|
||||
"confirmCancelReservation": "예약발송을 취소 하시겠습니까?<br/>취소하면 목록에서도 영구 삭제됩니다.",
|
||||
"confirmCancelSending": "발송 취소를 하시면 받는 사람의 쪽지함에서 쪽지가 삭제됩니다.",
|
||||
"confirmRemove": "선택한 쪽지를 삭제하시겠습니까?",
|
||||
"detailOfViewers": "읽음 확인",
|
||||
"selectRecipient": "수신자 선택",
|
||||
"results": {
|
||||
"successForSending": "쪽지를 전송하였습니다.",
|
||||
"successForReservation": "쪽지 전송을 예약 하였습니다.",
|
||||
"successForModifying": "쪽지를 수정하였습니다."
|
||||
},
|
||||
"errors": {
|
||||
"label": "쪽지 에러",
|
||||
"failToSending": "쪽지를 전송에 실패 하였습니다.",
|
||||
"failToModify": "쪽지 수정에 실패 하였습니다."
|
||||
}
|
||||
},
|
||||
"notice": {
|
||||
"label": "공지사항",
|
||||
"fieldTitle": "제목",
|
||||
"fieldPostDate": "게시일"
|
||||
"fieldPostDate": "게시일",
|
||||
"important": "중요"
|
||||
},
|
||||
"call": {
|
||||
"callTo": "전화 걸기",
|
||||
"callWithNumber": "{{phoneNumber}}로 전화를 거시겠습니까?",
|
||||
"errors": {
|
||||
"label": "전화 에러",
|
||||
"cannotCallToUser": "전화를 걸 수 없는 사용자 입니다.",
|
||||
"cannotCallToUserWithoutPhomeNumber": "상대방 번호가 없어 전화를 걸 수 없습니다."
|
||||
}
|
||||
},
|
||||
"sms": {
|
||||
"errors": {
|
||||
"label": "SMS 에러",
|
||||
"haveNoPermission": "SMS 사용 권한이 없습니다."
|
||||
}
|
||||
},
|
||||
"notification": {
|
||||
"titleChatEventArrived": "메세지가 도착했습니다.",
|
||||
"titleMessageArrived": "쪽지가 도착했습니다."
|
||||
},
|
||||
"common": {
|
||||
"search": "검색",
|
||||
"searchWord": "검색어",
|
||||
"searchResult": "검색 결과",
|
||||
"useOnlyForSpecialCharacter": "특수문자는 {{specialCharacter}}만 사용할 수 있습니다.",
|
||||
"howManyPersons": "명",
|
||||
"units": {
|
||||
"hour": "시",
|
||||
"hourFrom": "시간",
|
||||
"minute": "분",
|
||||
"second": "초",
|
||||
"persons": "명"
|
||||
},
|
||||
"file": {
|
||||
"name": "파일 이름",
|
||||
"size": "파일 크기",
|
||||
"download": "파일 다운로드",
|
||||
"delete": "파일 삭제",
|
||||
"save": "파일 저장",
|
||||
"saveAll": "파일 모두 저장",
|
||||
"downloadSelected": "선택된 파일 다운로드",
|
||||
"openDownloadFolder": "다운로드 폴더 열기",
|
||||
"selectFiles": "파일을 선택하세요",
|
||||
"dropZoneForUpload": "여기에 파일을 Drop하시면 업로드 됩니다.",
|
||||
"type": {
|
||||
"label": "파일 종류",
|
||||
"images": "이미지",
|
||||
@ -121,13 +247,19 @@
|
||||
},
|
||||
"results": {
|
||||
"saved": "파일이 저장되었습니다.",
|
||||
"savedToPath": "파일이 경로[{{path}}]에 저장되었습니다."
|
||||
"savedAll": "모든 파일이 저장되었습니다.",
|
||||
"savedToPath": "파일이 경로[{{path}}]에 저장되었습니다.",
|
||||
"downloadInProgress": "다운로드가 진행중입니다."
|
||||
},
|
||||
"errors": {
|
||||
"label": "파일 에러",
|
||||
"failToUpload": "파일 업로드에 실패하였습니다.",
|
||||
"failToSave": "파일 저장에 실패하였습니다.",
|
||||
"failToSpecifyPath": "저장경로 지정에 실패하였습니다."
|
||||
"failToSaveSomeOfAll": "파일 저장 중 일부 파일이 실패하였습니다.",
|
||||
"failToSpecifyPath": "저장경로 지정에 실패하였습니다.",
|
||||
"expired": "기간이 만료된 파일입니다",
|
||||
"noPreview": "미리보기를 지원하지 않는 파일입니다.",
|
||||
"notSupporedType": "지원하지 않는 파일형식입니다."
|
||||
}
|
||||
},
|
||||
"clipboard": {
|
||||
@ -136,12 +268,25 @@
|
||||
}
|
||||
},
|
||||
"messages": {
|
||||
"yes": "네",
|
||||
"yes": "예",
|
||||
"no": "아니오",
|
||||
"confirm": "확인",
|
||||
"select": "선택",
|
||||
"selectAll": "전체 선택",
|
||||
"unselect": "선택 해제",
|
||||
"searching": "검색중"
|
||||
"searching": "검색중",
|
||||
"cancel": "취소",
|
||||
"close": "닫기",
|
||||
"modify": "수정",
|
||||
"remove": "삭제",
|
||||
"apply": "적용",
|
||||
"minimizeWindow": "창 최소화",
|
||||
"maxmizeWindow": "창 최대화",
|
||||
"restoreWindow": "창 이전 크기",
|
||||
"closeWindow": "창 닫기",
|
||||
"zoomOut": "축소",
|
||||
"zoomIn": "확대",
|
||||
"zoomReset": "원본 비율"
|
||||
},
|
||||
"paginator": {
|
||||
"itemsPerPage": "페이지별 갯수",
|
||||
@ -150,6 +295,20 @@
|
||||
"firstPage": "처음 페이지",
|
||||
"lastPage": "마지막 페이지"
|
||||
},
|
||||
"player": {
|
||||
"play": "재생",
|
||||
"stop": "멈춤"
|
||||
},
|
||||
"pronoun": {
|
||||
"me": "나",
|
||||
"all": "전체"
|
||||
},
|
||||
"translations": {
|
||||
"targetLanguage": "대상 언어",
|
||||
"noTranslation": "번역 없음",
|
||||
"simpleView": "간략 보기",
|
||||
"preview": "미리 보기"
|
||||
},
|
||||
"timezone": {
|
||||
"Africa/Abidjan": "아프리카/아비 장",
|
||||
"Africa/Accra": "아프리카/아크라",
|
||||
|
@ -1,7 +1,7 @@
|
||||
<div class="change-password-form">
|
||||
<form name="changePasswordForm" [formGroup]="changePasswordForm" novalidate>
|
||||
<mat-form-field>
|
||||
<mat-label>현재 패스워드</mat-label>
|
||||
<mat-label>{{ 'accounts.fieldCurrentPassword' | translate }}</mat-label>
|
||||
<input
|
||||
matInput
|
||||
type="password"
|
||||
@ -9,11 +9,13 @@
|
||||
/>
|
||||
</mat-form-field>
|
||||
<mat-form-field>
|
||||
<mat-label>신규 패스워드</mat-label>
|
||||
<mat-label>{{ 'accounts.fieldNewPassword' | translate }}</mat-label>
|
||||
<input matInput type="password" [formControl]="newLoginPwFormControl" />
|
||||
</mat-form-field>
|
||||
<mat-form-field>
|
||||
<mat-label>신규 패스워드 확인</mat-label>
|
||||
<mat-label>{{
|
||||
'accounts.fieldNewPasswordConfirm' | translate
|
||||
}}</mat-label>
|
||||
<input
|
||||
matInput
|
||||
type="password"
|
||||
@ -28,7 +30,7 @@
|
||||
currentLoginPwFormControl.hasError('required')
|
||||
"
|
||||
>
|
||||
현재 비밀번호를 입력해 주세요
|
||||
{{ 'accounts.errors.requireCurrentPassword' | translate }}
|
||||
</mat-error>
|
||||
<mat-error
|
||||
*ngIf="
|
||||
@ -36,7 +38,7 @@
|
||||
currentLoginPwFormControl.hasError('ucapPasswordSame')
|
||||
"
|
||||
>
|
||||
현재 비밀번호와 일치하지 않습니다
|
||||
{{ 'accounts.errors.notSameWithCurrentPassword' | translate }}
|
||||
</mat-error>
|
||||
|
||||
<mat-error
|
||||
@ -45,7 +47,7 @@
|
||||
newLoginPwFormControl.hasError('required')
|
||||
"
|
||||
>
|
||||
신규 비밀번호를 입력해 주세요
|
||||
{{ 'accounts.errors.requireNewPassword' | translate }}
|
||||
</mat-error>
|
||||
<mat-error
|
||||
*ngIf="
|
||||
@ -53,7 +55,7 @@
|
||||
newLoginPwFormControl.hasError('ucapNotSameWith')
|
||||
"
|
||||
>
|
||||
현재 비밀번호와 동일합니다
|
||||
{{ 'accounts.errors.sameWithCurrentPassword' | translate }}
|
||||
</mat-error>
|
||||
<mat-error
|
||||
*ngIf="
|
||||
@ -67,46 +69,60 @@
|
||||
"
|
||||
>
|
||||
<ng-container *ngSwitchCase="PasswordValidationResult.IncludeSpace">
|
||||
비밀번호에는 공백을 입력할 수 없습니다
|
||||
{{ 'accounts.errors.notContainSpacesForPassword' | translate }}
|
||||
</ng-container>
|
||||
<ng-container *ngSwitchCase="PasswordValidationResult.IncludeUserId">
|
||||
사용자 ID를 비밀번호에 포함할 수 없습니다
|
||||
{{ 'accounts.errors.notContainUseridForPassword' | translate }}
|
||||
</ng-container>
|
||||
<ng-container
|
||||
*ngSwitchCase="PasswordValidationResult.IncludePhoneNumber"
|
||||
>
|
||||
사용자 휴대폰번호를 비밀번호에 포함할 수 없습니다
|
||||
{{ 'accounts.errors.notContainPhonenumberForPassword' | translate }}
|
||||
</ng-container>
|
||||
<ng-container
|
||||
*ngSwitchCase="PasswordValidationResult.IncludeRepeated"
|
||||
>
|
||||
숫자나 문자를 3번이상 반복적으로 사용할 수 없습니다
|
||||
{{
|
||||
'accounts.errors.notAllowedAlphaNumOver3TimesForPassword'
|
||||
| translate
|
||||
}}
|
||||
</ng-container>
|
||||
<ng-container
|
||||
*ngSwitchCase="PasswordValidationResult.IncludeIncrements"
|
||||
>
|
||||
연속되는 숫자나 문자를 3번이상 사용할 수 없습니다
|
||||
{{
|
||||
'accounts.errors.notAllowedConsecutiveAlphaNumOver3TimesForPassword'
|
||||
| translate
|
||||
}}
|
||||
</ng-container>
|
||||
<ng-container
|
||||
*ngSwitchCase="PasswordValidationResult.IncludeDecrements"
|
||||
>
|
||||
연속되는 숫자나 문자를 3번이상 사용할 수 없습니다
|
||||
{{
|
||||
'accounts.errors.notAllowedConsecutiveAlphaNumOver3TimesForPassword'
|
||||
| translate
|
||||
}}
|
||||
</ng-container>
|
||||
<ng-container
|
||||
*ngSwitchCase="PasswordValidationResult.LackOfCombination"
|
||||
>
|
||||
문자, 숫자, 특수문자 중 2종류 이상 조합을 해야 합니다
|
||||
{{ 'accounts.errors.notSatisfiedCombineForPassword' | translate }}
|
||||
</ng-container>
|
||||
<ng-container
|
||||
*ngSwitchCase="PasswordValidationResult.TooShortCombinationLength"
|
||||
>
|
||||
비밀번호는{{
|
||||
newLoginPwFormControl.getError('ucapPassword').result.extra
|
||||
.combinationCount
|
||||
}}가지가 조합된 경우{{
|
||||
newLoginPwFormControl.getError('ucapPassword').result.extra
|
||||
.minPwLen
|
||||
}}자를 넘어야 합니다
|
||||
{{
|
||||
'accounts.errors.minLengthCombineForPassword'
|
||||
| translate
|
||||
: {
|
||||
countOfCombine: newLoginPwFormControl.getError(
|
||||
'ucapPassword'
|
||||
).result.extra.combinationCount,
|
||||
lengthOfPassword: newLoginPwFormControl.getError(
|
||||
'ucapPassword'
|
||||
).result.extra.minPwLen
|
||||
}
|
||||
}}
|
||||
</ng-container>
|
||||
</ng-container>
|
||||
</mat-error>
|
||||
@ -116,7 +132,7 @@
|
||||
newConfirmLoginPwFormControl.hasError('required')
|
||||
"
|
||||
>
|
||||
신규 비밀번호 확인을 입력해 주세요
|
||||
{{ 'accounts.errors.requireNewPassword' | translate }}
|
||||
</mat-error>
|
||||
<mat-error
|
||||
*ngIf="
|
||||
@ -124,7 +140,7 @@
|
||||
newConfirmLoginPwFormControl.hasError('ucapSameWith')
|
||||
"
|
||||
>
|
||||
신규 비밀번호와 신규 비밀번호 확인이 다릅니다
|
||||
{{ 'accounts.errors.notSameWithNewPassword' | translate }}
|
||||
</mat-error>
|
||||
</div>
|
||||
|
||||
@ -135,7 +151,7 @@
|
||||
[disabled]="changePasswordForm.invalid"
|
||||
(click)="onClickChangePassword()"
|
||||
>
|
||||
패스워드 변경
|
||||
{{ 'accounts.changePassword' | translate }}
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
|
@ -3,12 +3,12 @@
|
||||
class="mat-title"
|
||||
style="background-image: url(./assets/images/logo/bg_login_w160.png);"
|
||||
>
|
||||
LOGIN TO YOUR ACCOUNT
|
||||
{{ 'accounts.instructionsOfLogin' | translate }}
|
||||
</div>
|
||||
|
||||
<form name="loginForm" [formGroup]="loginForm" novalidate>
|
||||
<mat-form-field [style.display]="!!curCompanyCode ? 'none' : 'block'">
|
||||
<mat-label>Company</mat-label>
|
||||
<mat-label>{{ 'accounts.fieldCompany' | translate }}</mat-label>
|
||||
<mat-select formControlName="companyCode" required>
|
||||
<mat-option
|
||||
*ngFor="let company of companyList"
|
||||
@ -17,26 +17,23 @@
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
<mat-error *ngIf="loginForm.get('companyCode').hasError('required')">
|
||||
Company is required
|
||||
{{ 'accounts.errors.requireCompany' | translate }}
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Login ID</mat-label>
|
||||
<mat-label>{{ 'accounts.fieldLoginId' | translate }}</mat-label>
|
||||
<input matInput formControlName="loginId" />
|
||||
<mat-error *ngIf="loginForm.get('loginId').hasError('required')">
|
||||
Login ID is required
|
||||
</mat-error>
|
||||
<mat-error *ngIf="!loginForm.get('loginId').hasError('required')">
|
||||
Please enter a valid login id
|
||||
{{ 'accounts.errors.requireLoginId' | translate }}
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field>
|
||||
<mat-label>Password</mat-label>
|
||||
<mat-label>{{ 'accounts.fieldLoginPw' | translate }}</mat-label>
|
||||
<input matInput type="password" formControlName="loginPw" #loginPw />
|
||||
<mat-error>
|
||||
Password is required
|
||||
{{ 'accounts.errors.requireLoginPw' | translate }}
|
||||
</mat-error>
|
||||
</mat-form-field>
|
||||
|
||||
@ -62,7 +59,7 @@
|
||||
formControlName="rememberMe"
|
||||
aria-label="Remember Me"
|
||||
>
|
||||
아이디 저장
|
||||
{{ 'accounts.rememberMe' | translate }}
|
||||
</mat-checkbox>
|
||||
|
||||
<mat-checkbox
|
||||
@ -71,7 +68,7 @@
|
||||
formControlName="autoLogin"
|
||||
aria-label="Auto Login"
|
||||
>
|
||||
자동 로그인
|
||||
{{ 'accounts.autoLogin' | translate }}
|
||||
</mat-checkbox>
|
||||
</div>
|
||||
</form>
|
||||
|
@ -15,6 +15,7 @@ import { ChangePasswordComponent } from './components/change-password.component'
|
||||
import { LoginComponent } from './components/login.component';
|
||||
|
||||
import { AccountService } from './services/account.service';
|
||||
import { TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
const COMPONENTS = [ChangePasswordComponent, LoginComponent];
|
||||
const SERVICES = [AccountService];
|
||||
@ -31,7 +32,9 @@ const SERVICES = [AccountService];
|
||||
MatFormFieldModule,
|
||||
MatIconModule,
|
||||
MatInputModule,
|
||||
MatSelectModule
|
||||
MatSelectModule,
|
||||
|
||||
TranslateModule
|
||||
],
|
||||
exports: [...COMPONENTS],
|
||||
declarations: [...COMPONENTS]
|
||||
|
@ -72,8 +72,6 @@
|
||||
</div>
|
||||
|
||||
<div class="date">
|
||||
<!-- {{ roomInfo.finalEventDate | dateToStringChatList }}
|
||||
.. -->
|
||||
{{ roomInfo.finalEventDate | ucapDate: 'C' }}
|
||||
</div>
|
||||
</dd>
|
||||
|
@ -3,11 +3,20 @@
|
||||
<div fxLayout="row" class="file-upload-info">
|
||||
<!--<mat-icon>image</mat-icon>-->
|
||||
<!--파일이미지 svg-->
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none"
|
||||
stroke="currentColor" stroke-width="1.5" stroke-linecap="butt" stroke-linejoin="round">
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
width="16"
|
||||
height="16"
|
||||
viewBox="0 0 24 24"
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
stroke-width="1.5"
|
||||
stroke-linecap="butt"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path
|
||||
d="M21.44 11.05l-9.19 9.19a6 6 0 0 1-8.49-8.49l9.19-9.19a4 4 0 0 1 5.66 5.66l-9.2 9.19a2 2 0 0 1-2.83-2.83l8.49-8.48">
|
||||
</path>
|
||||
d="M21.44 11.05l-9.19 9.19a6 6 0 0 1-8.49-8.49l9.19-9.19a4 4 0 0 1 5.66 5.66l-9.2 9.19a2 2 0 0 1-2.83-2.83l8.49-8.48"
|
||||
></path>
|
||||
</svg>
|
||||
|
||||
<div class="file-upload-name">{{ fileUploadItem.file.name }}</div>
|
||||
@ -17,13 +26,16 @@
|
||||
</div>
|
||||
|
||||
<div fxLayout="row" class="file-upload-progress">
|
||||
<mat-progress-bar mode="determinate" [value]="fileUploadItem.uploadingProgress$ | async">
|
||||
<mat-progress-bar
|
||||
mode="determinate"
|
||||
[value]="fileUploadItem.uploadingProgress$ | async"
|
||||
>
|
||||
</mat-progress-bar>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div *ngIf="uploadItems" fxLayout="column">
|
||||
<div>여기에 파일을 Drop하시면 업로드 됩니다.</div>
|
||||
<div>{{ 'common.file.dropZoneForUpload' | translate }}</div>
|
||||
<div></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-binary-viewer-action"
|
||||
matTooltip="다운로드"
|
||||
matTooltip="{{ 'common.file.download' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
(click)="onClickDownload()"
|
||||
@ -92,7 +92,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="guide-msg">
|
||||
미리보기를 지원하지 않는 파일입니다.
|
||||
{{ 'common.file.errors.noPreview' | translate }}
|
||||
</div>
|
||||
<div>
|
||||
<button
|
||||
@ -101,7 +101,7 @@
|
||||
aria-label=""
|
||||
(click)="onClickDownload()"
|
||||
>
|
||||
Download
|
||||
{{ 'common.file.download' | translate }}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -23,7 +23,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-image-viewer-action"
|
||||
matTooltip="이미지 크기 재설정"
|
||||
matTooltip="{{ 'common.messages.zoomReset' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
>
|
||||
@ -48,7 +48,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-image-viewer-action"
|
||||
matTooltip="축소"
|
||||
matTooltip="{{ 'common.messages.zoomOut' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
>
|
||||
@ -72,7 +72,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-image-viewer-action"
|
||||
matTooltip="확대"
|
||||
matTooltip="{{ 'common.messages.zoomIn' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
>
|
||||
@ -97,7 +97,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-image-viewer-action"
|
||||
matTooltip="다운로드"
|
||||
matTooltip="{{ 'common.file.download' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
(click)="onClickDownload()"
|
||||
@ -124,7 +124,7 @@
|
||||
mat-icon-button
|
||||
color="warn"
|
||||
class="ucap-image-viewer-action btn-close"
|
||||
matTooltip="뷰어닫기"
|
||||
matTooltip="{{ 'common.messages.close' | translate }}"
|
||||
(click)="onClickClose()"
|
||||
>
|
||||
<svg
|
||||
|
@ -6,7 +6,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-image-viewer-action"
|
||||
matTooltip="다운로드"
|
||||
matTooltip="{{ 'common.file.download' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
(click)="onClickDownload()"
|
||||
@ -33,6 +33,7 @@
|
||||
mat-icon-button
|
||||
color="warn"
|
||||
class="ucap-image-viewer-action btn-close"
|
||||
matTooltip="{{ 'common.messages.close' | translate }}"
|
||||
(click)="onClickClose()"
|
||||
>
|
||||
<svg
|
||||
@ -125,7 +126,9 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-sound-viewer-action"
|
||||
[matTooltip]="playing ? '멈춤' : '재생'"
|
||||
matTooltip="{{
|
||||
(playing ? 'common.player.stop' : 'common.player.play') | translate
|
||||
}}"
|
||||
aria-label=""
|
||||
(click)="onClickPlayOrPause()"
|
||||
>
|
||||
|
@ -27,7 +27,7 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-video-viewer-action"
|
||||
matTooltip="다운로드"
|
||||
matTooltip="{{ 'common.file.download' | translate }}"
|
||||
matTooltipPosition="below"
|
||||
aria-label=""
|
||||
(click)="onClickDownload()"
|
||||
@ -54,7 +54,7 @@
|
||||
mat-icon-button
|
||||
color="warn"
|
||||
class="ucap-image-viewer-action btn-close"
|
||||
matTooltip="뷰어닫기"
|
||||
matTooltip="{{ 'common.messages.close' | translate }}"
|
||||
(click)="onClickClose()"
|
||||
>
|
||||
<svg
|
||||
@ -130,7 +130,9 @@
|
||||
<button
|
||||
mat-icon-button
|
||||
class="ucap-video-viewer-action"
|
||||
[matTooltip]="playing ? '멈춤' : '재생'"
|
||||
matTooltip="{{
|
||||
(playing ? 'common.player.stop' : 'common.player.play') | translate
|
||||
}}"
|
||||
aria-label=""
|
||||
(click)="onClickPlayOrPause()"
|
||||
>
|
||||
|
@ -15,7 +15,7 @@
|
||||
mat-stroked-button
|
||||
(click)="onClickSendTranslationMessage(translationPreviewInfo)"
|
||||
>
|
||||
Send
|
||||
{{ 'chat.send' | translate }}
|
||||
</button>
|
||||
<span class="btn-close">
|
||||
<button
|
||||
@ -32,12 +32,16 @@
|
||||
<div>
|
||||
<form name="translationForm" [formGroup]="translationForm">
|
||||
<mat-form-field>
|
||||
<mat-label>Dest Type</mat-label>
|
||||
<mat-label>{{
|
||||
'common.translations.targetLanguage' | translate
|
||||
}}</mat-label>
|
||||
<mat-select
|
||||
formControlName="destType"
|
||||
(selectionChange)="onChangeSelection($event)"
|
||||
>
|
||||
<mat-option value="">번역없음</mat-option>
|
||||
<mat-option value="">{{
|
||||
'common.translations.noTranslation' | translate
|
||||
}}</mat-option>
|
||||
<mat-option *ngFor="let dest of translationDestList" [value]="dest.key"
|
||||
>{{ dest.text }}
|
||||
</mat-option>
|
||||
@ -47,13 +51,13 @@
|
||||
labelPosition="before"
|
||||
[checked]="simpleView"
|
||||
(change)="onChangToggleSimpleview($event)"
|
||||
>Simple View</mat-slide-toggle
|
||||
>{{ 'common.translations.simpleView' | translate }}</mat-slide-toggle
|
||||
>
|
||||
<mat-slide-toggle
|
||||
labelPosition="before"
|
||||
[checked]="preView"
|
||||
(change)="onChangTogglePreview($event)"
|
||||
>Preview</mat-slide-toggle
|
||||
>{{ 'common.translations.preview' | translate }}</mat-slide-toggle
|
||||
>
|
||||
</form>
|
||||
</div>
|
||||
|
@ -10,7 +10,7 @@
|
||||
</mat-card-content>
|
||||
<mat-card-actions class="button-farm flex-row">
|
||||
<button mat-stroked-button (click)="onClickConfirm()" class="mat-primary">
|
||||
Confirm
|
||||
{{ 'common.messages.confirm' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -1,6 +1,11 @@
|
||||
<mat-card class="confirm-card mat-elevation-z">
|
||||
<mat-card-header cdkDrag cdkDragRootElement=".cdk-overlay-pane" cdkDragHandle class="card-header">
|
||||
<mat-card-title >{{ data.title }}</mat-card-title>
|
||||
<mat-card-header
|
||||
cdkDrag
|
||||
cdkDragRootElement=".cdk-overlay-pane"
|
||||
cdkDragHandle
|
||||
class="card-header"
|
||||
>
|
||||
<mat-card-title>{{ data.title }}</mat-card-title>
|
||||
<!-- <mat-card-subtitle>Confirm</mat-card-subtitle> -->
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
@ -14,10 +19,10 @@
|
||||
(click)="onClickChoice(false)"
|
||||
class="mat-primary"
|
||||
>
|
||||
No
|
||||
{{ 'common.messages.no' | translate }}
|
||||
</button>
|
||||
<button mat-flat-button (click)="onClickChoice(true)" class="mat-primary">
|
||||
Yes
|
||||
{{ 'common.messages.yes' | translate }}
|
||||
</button>
|
||||
</mat-card-actions>
|
||||
</mat-card>
|
||||
|
@ -32,7 +32,7 @@ export class ClickDebounceDirective implements OnInit, OnDestroy {
|
||||
}
|
||||
|
||||
@HostListener('click', ['$event'])
|
||||
clickEvent(event) {
|
||||
clickEvent(event: Event) {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
this.clicks.next(event);
|
||||
|
@ -19,6 +19,7 @@ import {
|
||||
AlertDialogResult,
|
||||
AlertDialogData
|
||||
} from '../dialogs/alert.dialog.component';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Directive({
|
||||
selector: 'input[ucapFileUploadFor], div[ucapFileUploadFor]'
|
||||
@ -45,6 +46,7 @@ export class FileUploadForDirective implements AfterViewInit {
|
||||
private commonApiService: CommonApiService,
|
||||
private elementRef: ElementRef,
|
||||
private logger: NGXLogger,
|
||||
private translateService: TranslateService,
|
||||
private dialogService: DialogService
|
||||
) {}
|
||||
|
||||
@ -126,7 +128,9 @@ export class FileUploadForDirective implements AfterViewInit {
|
||||
>(AlertDialogComponent, {
|
||||
data: {
|
||||
title: 'Alert',
|
||||
html: `지원하지 않는 파일형식입니다.${
|
||||
html: `${this.translateService.instant(
|
||||
'common.file.errors.notSupporedType'
|
||||
)} ${
|
||||
checkExt.reject.length > 0
|
||||
? '<br/>(' + checkExt.reject.join(',') + ')'
|
||||
: ''
|
||||
|
@ -1,66 +0,0 @@
|
||||
import { Pipe, PipeTransform } from '@angular/core';
|
||||
import { StringUtil } from '../utils/string.util';
|
||||
import moment from 'moment';
|
||||
|
||||
@Pipe({
|
||||
name: 'dateToStringChatList'
|
||||
})
|
||||
export class DateToStringForChatRoomListPipe implements PipeTransform {
|
||||
transform(value: any): string {
|
||||
const curDate = new Date();
|
||||
const yesterDate = new Date(curDate.getTime() - 1 * 24 * 60 * 60 * 1000);
|
||||
let date: Date;
|
||||
if (typeof value === 'string') {
|
||||
date = moment(value.toString()).toDate();
|
||||
} else if (value instanceof Date) {
|
||||
date = value;
|
||||
} else {
|
||||
return value;
|
||||
}
|
||||
|
||||
if (
|
||||
curDate.getFullYear() === date.getFullYear() &&
|
||||
curDate.getMonth() === date.getMonth() &&
|
||||
curDate.getDate() === date.getDate()
|
||||
) {
|
||||
// 당일
|
||||
return StringUtil.dateFormat(date, 'a/p HH:mm');
|
||||
} else if (
|
||||
yesterDate.getFullYear() === date.getFullYear() &&
|
||||
yesterDate.getMonth() === date.getMonth() &&
|
||||
yesterDate.getDate() === date.getDate()
|
||||
) {
|
||||
// 어제
|
||||
return '어제';
|
||||
} else {
|
||||
return StringUtil.dateFormat(date, 'MM.dd');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Pipe({
|
||||
name: 'dateToStringFormat'
|
||||
})
|
||||
export class DateToStringFormatPipe implements PipeTransform {
|
||||
transform(value: any, format?: string): string {
|
||||
const date = moment(value.toString()).toDate();
|
||||
|
||||
if (!!format) {
|
||||
return StringUtil.dateFormat(date, format);
|
||||
} else {
|
||||
return StringUtil.dateFormat(date, 'YYYY.MM.DD');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Pipe({
|
||||
name: 'dateDistanceToDay'
|
||||
})
|
||||
export class DateDistanceToDatePipe implements PipeTransform {
|
||||
transform(value: any, distanceDay?: number): Date {
|
||||
distanceDay = distanceDay || 0;
|
||||
const date: Date = moment(value.toString()).toDate();
|
||||
date.setDate(date.getDate() + distanceDay);
|
||||
return date;
|
||||
}
|
||||
}
|
@ -27,6 +27,8 @@ import {
|
||||
|
||||
import { DragDropModule } from '@angular/cdk/drag-drop';
|
||||
|
||||
import { TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
import { FileUploadQueueComponent } from './components/file-upload-queue.component';
|
||||
import { FloatActionButtonComponent } from './components/float-action-button.component';
|
||||
import { FileViewerComponent } from './components/file-viewer.component';
|
||||
@ -62,11 +64,6 @@ import { ConfirmDialogComponent } from './dialogs/confirm.dialog.component';
|
||||
|
||||
import { BytesPipe } from './pipes/bytes.pipe';
|
||||
import { LinefeedToHtmlPipe, HtmlToLinefeedPipe } from './pipes/linefeed.pipe';
|
||||
import {
|
||||
DateToStringForChatRoomListPipe,
|
||||
DateToStringFormatPipe,
|
||||
DateDistanceToDatePipe
|
||||
} from './pipes/dates.pipe';
|
||||
import { SecondsToMinutesPipe } from './pipes/seconds-to-minutes.pipe';
|
||||
import { LinkyPipe } from './pipes/linky.pipe';
|
||||
import { TranslatePipe } from './pipes/translate.pipe';
|
||||
@ -109,9 +106,6 @@ const PIPES = [
|
||||
BytesPipe,
|
||||
LinefeedToHtmlPipe,
|
||||
HtmlToLinefeedPipe,
|
||||
DateToStringForChatRoomListPipe,
|
||||
DateToStringFormatPipe,
|
||||
DateDistanceToDatePipe,
|
||||
SecondsToMinutesPipe,
|
||||
LinkyPipe,
|
||||
TranslatePipe,
|
||||
@ -152,7 +146,8 @@ const SERVICES = [
|
||||
MatDatepickerModule,
|
||||
MatSelectModule,
|
||||
MatSlideToggleModule,
|
||||
DragDropModule
|
||||
DragDropModule,
|
||||
TranslateModule
|
||||
],
|
||||
exports: [...COMPONENTS, ...DIRECTIVES, ...PIPES],
|
||||
declarations: [...COMPONENTS, ...DIALOGS, ...DIRECTIVES, ...PIPES],
|
||||
|
Loading…
x
Reference in New Issue
Block a user