此函数返回选定文件列表。
SitesSDK.openDocumentPicker()
函数采用单个参数并返回 Promise,其解析为所选文档。可用选项与《Integrating and Extending Oracle Content Management》中 "Documents View Embed UI (documentsView Component) API V2" 中的 documentsView
组件的那些选项匹配。
用法
SitesSDK.openDocumentPicker({ selectable: "any", layout: "grid" }).then(function (selection) { console.log(selection); });
一旦文档被检索到,将使用 SitesSDK.getProperty('componentAssets', callback)
和 SitesSDK.setProperty('componentAssets', [assets])
属性告知 Oracle Content Management 必须将这些文档的 ID 存储在站点中。否则,它们将不会发布到站点上,且可能会删除。