...
Code Block |
---|
|
// release 2.3.0
{
editor: SynapEditor,
eventType: "'beforeOpenDocument"',
cancelable: true,
returnValue: null,
fileType: "'WORD"', // 파일 타입 ("'HTML"', "'WORD"', "'CELL"', ...)
fileName: "'filename.docx"' // 파일 이름
}
// release 2.14.6 이상
{
editor: SynapEditor,
eventType: 'beforeOpenDocument',
cancelable: true,
returnValue: null,
fileType: 'WORD',
fileName: 'filename.docx',
fileSize: 100 // [2.14.6] 파일 사이즈 (단위: Byte)
} |
API
event.setApi(api)
Status |
---|
colour | Yellow |
---|
title | 릴리즈 2.7.0 이상 |
---|
|
이벤트 객체를 통해 임포트 API를 설정할 수 있습니다.
Code Block |
---|
|
{
beforeOpenDocument: function (e) {
e.setApi('newImportURL');
}
} |
event.setFileFieldName(fileFieldName)
Status |
---|
colour | Yellow |
---|
title | 릴리즈 2.7.0 이상 |
---|
|
이벤트 객체를 통해 form date fieldName을 설정할 수 있습니다. (기본값: 'file')
Code Block |
---|
|
{
beforeOpenDocument: function (e) {
e.setFileFieldName('file');
}
} |
Status |
---|
colour | Yellow |
---|
title | 릴리즈 2.7.0 이상 |
---|
|
이벤트 객체를 통해 Request Header를 설정할 수 있습니다.
Code Block |
---|
|
{
beforeOpenDocument: function (e) {
e.addHeader('X-Hello', 'World');
}
} |
event.addParameter(key, value)
Status |
---|
colour | Yellow |
---|
title | 릴리즈 2.7.0 이상 |
---|
|
이벤트 객체를 통해 Parameter를 설정할 수 있습니다.
Code Block |
---|
|
{
beforeOpenDocument: function (e) {
e.addParameter('hello', 'world');
}
} |