2014-04-20 42 views
1

有沒有辦法允許用戶通過在線表單上傳文件並將其附加到記錄中?我有一個自定義記錄類型,潛在資源,我創建了一個在線表單。這個想法是,任何人都可以使用在線表單創建潛在資源記錄並上傳該記錄的簡歷。NetSuite上傳文件的記錄

回答

0

我覺得有一個文件類型字段:

Document 
This lets you select a file cabinet document to preview or download. The field is searchable and can be added to search results. 
Note: The user of the document custom field must have file cabinet access in order to view, select or upload documents. 

您可能必須與角色玩了一下。

0

通過在線表單你指的是一個suitelet嗎?

我相信你可以通過suitelet做到這一點,像這樣

function imageUpload(request, response) { 

if (request.getMethod() === 'GET') { 

    var form = nlapiCreateForm(formTitle); 

    var file = form.addField('file1', 'file', 'Logo'); 
    file.setMandatory(true); 

    form.addSubmitButton('SUBMIT'); 

    response.writePage(form); 
} 
else { 
    var file = request.getFile('file1'); 

    // 133 is the id of the folder you want to save the file 
    file.setFolder(133); 
    file.setIsOnline(true); 

    var id = nlapiSubmitFile(file); 

} 

}

+0

呀,從一切我讀過你不能從一個在線的形式上傳文件的NetSuite的外。 – CodeMoto