|
发表于 2018-6-13 11:09:27
|
显示全部楼层
1.java中
- DocServerDefines dc = DocServerDefines.getInstance();
- String urlPattern = "/repository/file/view/" + fileID + "/last/content";
- String url = DocUtils.getDocUrl(docPath, urlPattern);
复制代码
2.js中
- var url = DocUtils.InnerUtils.getdocServerAction({
- "docPath" : docPath,
- urlPattern : "/repository/file/view/" + fileID + "/last/content",
- isFormAction : false,
- context : this.getContext()
- });
复制代码
API的底层实现是daisy提供的,平台只是调用了daisy的接口,然后封装了上面的API,通过fileID拼接url去下载或者预览 |
|