메신저 기본값 environment 로 이동 수정.
This commit is contained in:
parent
568c0be6a5
commit
002ecf23dd
|
@ -186,7 +186,6 @@
|
|||
(fileDragOver)="onFileDragOver()"
|
||||
(fileDragLeave)="onFileDragLeave()"
|
||||
>
|
||||
|
||||
<!-- CHAT MESSAGES -->
|
||||
<perfect-scrollbar
|
||||
fxFlex="1 1 auto"
|
||||
|
@ -205,7 +204,9 @@
|
|||
[sessionVerInfo]="sessionVerInfo"
|
||||
[isShowUnreadCount]="getShowUnreadCount()"
|
||||
[clearReadHere]="clearReadHere"
|
||||
[minShowReadHere]="CONST.READ_HERE_MIN_EVENT_INFO_READ_COUNT"
|
||||
[minShowReadHere]="
|
||||
environment.productConfig.CommonSetting.readHereShowMinimumEventCount
|
||||
"
|
||||
(moreEvent)="onMoreEvent($event)"
|
||||
(massDetail)="onMassDetail($event)"
|
||||
(save)="onSave($event)"
|
||||
|
|
|
@ -83,7 +83,7 @@ import {
|
|||
FileViewerDialogData,
|
||||
FileViewerDialogResult
|
||||
} from '@app/layouts/common/dialogs/file-viewer.dialog.component';
|
||||
import { CONST, FileUtil, StickerFilesInfo } from '@ucap-webmessenger/core';
|
||||
import { FileUtil, StickerFilesInfo } from '@ucap-webmessenger/core';
|
||||
import { PerfectScrollbarComponent } from 'ngx-perfect-scrollbar';
|
||||
import { StatusCode } from '@ucap-webmessenger/api';
|
||||
import {
|
||||
|
@ -163,7 +163,7 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
|||
snackBarPreviewEvent: MatSnackBarRef<SimpleSnackBar>;
|
||||
|
||||
RoomType = RoomType;
|
||||
CONST = CONST;
|
||||
environment = environment;
|
||||
|
||||
constructor(
|
||||
private store: Store<any>,
|
||||
|
@ -540,7 +540,8 @@ export class MessagesComponent implements OnInit, OnDestroy, AfterViewInit {
|
|||
EventStore.info({
|
||||
roomSeq: this.roomInfo.roomSeq,
|
||||
baseSeq: seq,
|
||||
requestCount: CONST.EVENT_INFO_READ_COUNT
|
||||
requestCount:
|
||||
environment.productConfig.CommonSetting.eventRequestDefaultCount
|
||||
})
|
||||
);
|
||||
}
|
||||
|
|
|
@ -89,7 +89,6 @@ import { openSuccess, openFailure } from '../room';
|
|||
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||
import { KEY_LOGIN_RES_INFO } from '@app/types/login-res-info.type';
|
||||
import { StatusCode } from '@ucap-webmessenger/api';
|
||||
import { CONST } from '@ucap-webmessenger/core';
|
||||
import {
|
||||
FileProtocolService,
|
||||
SSVC_TYPE_FILE_INFO_DATA,
|
||||
|
@ -102,6 +101,7 @@ import {
|
|||
InfoResponse as FileInfoResponse,
|
||||
FileType
|
||||
} from '@ucap-webmessenger/protocol-file';
|
||||
import { environment } from '../../../../environments/environment';
|
||||
import { RoomUserData } from '@ucap-webmessenger/protocol-sync';
|
||||
|
||||
@Injectable()
|
||||
|
@ -113,7 +113,7 @@ export class Effects {
|
|||
// return info({
|
||||
// roomSeq: action.roomSeq,
|
||||
// baseSeq: 0,
|
||||
// requestCount: CONST.EVENT_INFO_READ_COUNT
|
||||
// requestCount: environment.productConfig.CommonSetting.eventRequestDefaultCount
|
||||
// });
|
||||
// })
|
||||
// )
|
||||
|
@ -131,12 +131,21 @@ export class Effects {
|
|||
requestCount = roomInfo.finalEventSeq - roomInfo.lastReadEventSeq;
|
||||
|
||||
// 기존 요청개수보다 요청할 갯수가 적을 경우 기본값.
|
||||
if (CONST.EVENT_INFO_READ_COUNT >= requestCount) {
|
||||
requestCount = CONST.EVENT_INFO_READ_COUNT;
|
||||
if (
|
||||
environment.productConfig.CommonSetting.eventRequestDefaultCount >=
|
||||
requestCount
|
||||
) {
|
||||
requestCount =
|
||||
environment.productConfig.CommonSetting.eventRequestDefaultCount;
|
||||
} else {
|
||||
// 여기까지 읽음 처리를 위한 최대 요청 개수 제한.
|
||||
if (CONST.READ_HERE_MAX_EVENT_INFO_READ_COUNT < requestCount) {
|
||||
requestCount = CONST.READ_HERE_MAX_EVENT_INFO_READ_REQUEST_COUNT;
|
||||
if (
|
||||
environment.productConfig.CommonSetting
|
||||
.readHereShowMaximumEventCount < requestCount
|
||||
) {
|
||||
requestCount =
|
||||
environment.productConfig.CommonSetting
|
||||
.readHereEventRequestCount;
|
||||
} else {
|
||||
requestCount = requestCount + 5;
|
||||
}
|
||||
|
|
|
@ -18,7 +18,6 @@ import {
|
|||
import * as AuthenticationStore from '@app/store/account/authentication';
|
||||
import * as ChatStore from '@app/store/messenger/chat';
|
||||
import { Info, EventType, EventJson } from '@ucap-webmessenger/protocol-event';
|
||||
import { CONST } from '@ucap-webmessenger/core';
|
||||
|
||||
export const reducer = createReducer(
|
||||
initialState,
|
||||
|
|
|
@ -105,7 +105,6 @@ import {
|
|||
|
||||
import * as ChatStore from '@app/store/messenger/chat';
|
||||
import * as RoomStore from '@app/store/messenger/room';
|
||||
import { CONST } from '@ucap-webmessenger/core';
|
||||
import {
|
||||
AlertDialogComponent,
|
||||
AlertDialogResult,
|
||||
|
@ -437,7 +436,9 @@ export class Effects {
|
|||
divCd: 'DivCodeT',
|
||||
roomName: '',
|
||||
isTimerRoom: true,
|
||||
timerRoomInterval: CONST.DEFAULT_TIMER_ROOM_INTERVAL, // 24h default
|
||||
timerRoomInterval:
|
||||
environment.productConfig.CommonSetting
|
||||
.timerRoomDefaultInterval, // 24h default
|
||||
userSeqs: userSeqList
|
||||
}
|
||||
})
|
||||
|
|
|
@ -55,8 +55,16 @@ export const environment: Environment = {
|
|||
editableProfileImage: false,
|
||||
|
||||
useTimerRoom: false,
|
||||
timerRoomDefaultInterval: 24 * 60 * 60,
|
||||
|
||||
maxChatRoomUser: 300,
|
||||
masstextLength: 800
|
||||
masstextLength: 800,
|
||||
|
||||
eventRequestDefaultCount: 50,
|
||||
|
||||
readHereShowMinimumEventCount: 10,
|
||||
readHereShowMaximumEventCount: 100,
|
||||
readHereEventRequestCount: 10
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
@ -55,8 +55,16 @@ export const environment: Environment = {
|
|||
editableProfileImage: false,
|
||||
|
||||
useTimerRoom: false,
|
||||
timerRoomDefaultInterval: 24 * 60 * 60,
|
||||
|
||||
maxChatRoomUser: 300,
|
||||
masstextLength: 800
|
||||
masstextLength: 800,
|
||||
|
||||
eventRequestDefaultCount: 50,
|
||||
|
||||
readHereShowMinimumEventCount: 10,
|
||||
readHereShowMaximumEventCount: 100,
|
||||
readHereEventRequestCount: 10
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
@ -55,8 +55,16 @@ export const environment: Environment = {
|
|||
editableProfileImage: true,
|
||||
|
||||
useTimerRoom: true,
|
||||
timerRoomDefaultInterval: 24 * 60 * 60,
|
||||
|
||||
maxChatRoomUser: 300,
|
||||
masstextLength: 800
|
||||
masstextLength: 800,
|
||||
|
||||
eventRequestDefaultCount: 50,
|
||||
|
||||
readHereShowMinimumEventCount: 10,
|
||||
readHereShowMaximumEventCount: 100,
|
||||
readHereEventRequestCount: 10
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
@ -55,8 +55,16 @@ export const environment: Environment = {
|
|||
editableProfileImage: true,
|
||||
|
||||
useTimerRoom: true,
|
||||
timerRoomDefaultInterval: 24 * 60 * 60,
|
||||
|
||||
maxChatRoomUser: 300,
|
||||
masstextLength: 800
|
||||
masstextLength: 800,
|
||||
|
||||
eventRequestDefaultCount: 50,
|
||||
|
||||
readHereShowMinimumEventCount: 10,
|
||||
readHereShowMaximumEventCount: 100,
|
||||
readHereEventRequestCount: 10
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
@ -66,9 +66,25 @@ export interface Environment {
|
|||
CommonSetting: {
|
||||
editableProfileImage: boolean;
|
||||
|
||||
/** 타이머대화방 사용유무 */
|
||||
useTimerRoom: boolean;
|
||||
/** 타이머대화방 기본 interval */
|
||||
timerRoomDefaultInterval: number;
|
||||
|
||||
/** 최대 대화방 참여인원 */
|
||||
maxChatRoomUser: number;
|
||||
/** 대용량대화 기준 */
|
||||
masstextLength: number;
|
||||
|
||||
/** 대화방 이벤트 조회 개수 */
|
||||
eventRequestDefaultCount: number;
|
||||
|
||||
/** 여기까지 읽음을 보여줄 최소 이벤트 개수 (show: over) */
|
||||
readHereShowMinimumEventCount: number;
|
||||
/** 여기까지 읽음을 보여줄 최대 이벤트 개수 (show: under) */
|
||||
readHereShowMaximumEventCount: number;
|
||||
/** 여기까지 읽음이 보려질때 대화방 이벤트 조회 개수. */
|
||||
readHereEventRequestCount: number;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -1,13 +0,0 @@
|
|||
export enum CONST {
|
||||
/** 대화방의 이벤트를 조회하는 갯수 */
|
||||
EVENT_INFO_READ_COUNT = 50,
|
||||
/** Timer Room 최초 오픈시 timer interval */
|
||||
DEFAULT_TIMER_ROOM_INTERVAL = 24 * 60 * 60,
|
||||
|
||||
/** 여기까지 읽음을 표시할때 조회할 최소 이벤트 갯수 */
|
||||
READ_HERE_MIN_EVENT_INFO_READ_COUNT = 10,
|
||||
/** 여기까지 읽음을 표시할때 조회할 최대 이벤트 갯수 */
|
||||
READ_HERE_MAX_EVENT_INFO_READ_COUNT = 100,
|
||||
/** 여기까지 읽음을 표시할때 조회할 최대 이벤트 갯수를 초과 했을 경우 요청할 최초 이벤트 갯수 */
|
||||
READ_HERE_MAX_EVENT_INFO_READ_REQUEST_COUNT = 10
|
||||
}
|
|
@ -7,7 +7,6 @@ export * from './lib/types/call-alarm.type';
|
|||
export * from './lib/types/call-forward.type';
|
||||
export * from './lib/types/call-mode.type';
|
||||
export * from './lib/types/caller-type.type';
|
||||
export * from './lib/types/const.type';
|
||||
export * from './lib/types/default-screen.type';
|
||||
export * from './lib/types/device-devision.type';
|
||||
export * from './lib/types/device-type.type';
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
import { CONST } from '@ucap-webmessenger/core';
|
||||
import { Component, OnInit, Input, EventEmitter, Output } from '@angular/core';
|
||||
|
||||
import {
|
||||
|
@ -69,7 +68,6 @@ export class MessagesComponent implements OnInit {
|
|||
messages: Info<EventJson>[];
|
||||
|
||||
EventType = EventType;
|
||||
CONST = CONST;
|
||||
profileImageRoot: string;
|
||||
moment = moment;
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user