config of acceptable file extension is added

This commit is contained in:
병준 박 2019-11-01 13:43:03 +09:00
parent 0f4c612de5
commit 772d038d22
4 changed files with 116 additions and 1 deletions

View File

@ -134,6 +134,10 @@ export class CommonApiService {
); );
} }
public acceptableExtensionForFileTalk(extension: string): boolean {
return -1 !== this.moduleConfig.acceptableFileExtensions.indexOf(extension);
}
public fileTalkShare( public fileTalkShare(
req: FileTalkShareRequest req: FileTalkShareRequest
): Observable<FileTalkShareResponse> { ): Observable<FileTalkShareResponse> {

View File

@ -11,4 +11,5 @@ export interface ModuleConfig {
translationReq: string; translationReq: string;
translationSave: string; translationSave: string;
}; };
acceptableFileExtensions: string[];
} }

View File

@ -58,7 +58,11 @@ import { AppNativeLayoutModule } from './layouts/native/native.layout.module';
PerfectScrollbarModule, PerfectScrollbarModule,
UCapCommonApiModule.forRoot({ urls: environment.urls.apiCommon }), UCapCommonApiModule.forRoot({
urls: environment.urls.apiCommon,
acceptableFileExtensions:
environment.modules.event.acceptableFileExtensions
}),
UCapPublicApiModule.forRoot({ UCapPublicApiModule.forRoot({
urls: environment.urls.apiPublic urls: environment.urls.apiPublic

View File

@ -333,6 +333,11 @@ export interface Environment {
max: number; max: number;
}; };
}; };
modules: {
event: {
acceptableFileExtensions: string[];
};
};
} }
export function build(production: boolean): Environment { export function build(production: boolean): Environment {
@ -374,6 +379,107 @@ export function build(production: boolean): Environment {
min: 1, min: 1,
max: 59999 max: 59999
} }
},
modules: {
event: {
acceptableFileExtensions: [
// 문서1
'csv',
'd01',
'doc',
'docx',
'dot',
'dotx',
'hwp',
'log',
'one',
'pdf',
'pot',
'potx',
'pps',
'ppsx',
'ppt',
'pptx',
'ps',
// 문서2
'rtf',
'txt',
'vcf',
'xls',
'xlsx',
'xlt',
'xltx',
'xlsm',
'ods',
// CAD
'asc',
'dwg',
'dws',
'dwt',
'dxf',
'pgp',
'plt',
// MAC
'pages',
'keynote',
// 압축
'7z',
'a01',
'a02',
'a03',
'alz',
'egg',
'gz',
'rar',
'tar',
'zip',
// 오디오
'aac',
'aiff',
'flac',
'm4a',
'mp2',
'mp3',
'mpega',
'mpga',
'ogg',
'wma',
'wav',
// 플래쉬
'fla',
'flv',
'swf',
// 이미지
'ai',
'bmp',
'cdr',
'emf',
'eps',
'gif',
'jpeg',
'jpg',
'png',
'psd',
'tif',
'tiff',
'wmf',
// 동영상
'3gp',
'avi',
'm4v',
'mkv',
'mov',
'mp4',
'mpeg',
'mpg',
'rv',
'ts',
'webm',
'wmv',
// 폴더전송용
'zdr'
]
}
} }
}; };
} }