Commit 8b889905 by 宋祥

1.root目录显示内容调整

parent 3f7172ba
...@@ -108,6 +108,11 @@ function add(docId, leafType, docType) { ...@@ -108,6 +108,11 @@ function add(docId, leafType, docType) {
message("文件类型或ID不能为空"); message("文件类型或ID不能为空");
return; return;
} }
// 第一级目录
if (leafType === "C") {
otherDownload(true, null);
return;
}
let inInfo = new EiInfo(); let inInfo = new EiInfo();
inInfo.set("result-0-fileId", $("#inqu_status-0-fileId").val()); inInfo.set("result-0-fileId", $("#inqu_status-0-fileId").val());
inInfo.set("result-0-docId", docId); inInfo.set("result-0-docId", docId);
...@@ -143,7 +148,7 @@ function preview(docId, docType) { ...@@ -143,7 +148,7 @@ function preview(docId, docType) {
} else if (isFrame(docType)) { } else if (isFrame(docType)) {
previewFrame(docId); previewFrame(docId);
} else { } else {
otherDownload(docId); otherDownload(false, docId);
} }
} }
...@@ -224,10 +229,15 @@ function previewFrame(docId) { ...@@ -224,10 +229,15 @@ function previewFrame(docId) {
/** /**
* 其他下载 * 其他下载
* *
* @param isRoot
* @param docId * @param docId
*/ */
function otherDownload(docId) { function otherDownload(isRoot, docId) {
$("#descDiv").css('display', ''); $("#descDiv").css('display', '');
$("#descSpan").html("该文件暂不支持预览,点击<a href='" + downloadHref(docId, false) if (isRoot) {
+ "' target='_blank'>下载</a>"); $("#descSpan").html("文件预览区域...");
} else {
$("#descSpan").html("该文件暂不支持预览,点击<a href='" + downloadHref(docId, false)
+ "' target='_blank'>下载</a>");
}
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment