|
|
@@ -85,7 +85,7 @@ |
|
|
|
showOffice: false, // 预览Office文件 |
|
|
|
officeUrl: "", // PDF URL |
|
|
|
isShowDefault:false, |
|
|
|
isClient: false,//是否是客户端 |
|
|
|
isClient: true,//是否是客户端 |
|
|
|
}; |
|
|
|
}, |
|
|
|
mounted: function () { |
|
|
@@ -184,15 +184,7 @@ |
|
|
|
this.officeTitle = file.archName + "." + file.extension; |
|
|
|
if (file.extension == "pdf") { |
|
|
|
this.showOffice = true; |
|
|
|
var fileUrl = |
|
|
|
encodeURIComponent(process.env.API_HOST + "archives/pdf?path=") + |
|
|
|
encodeURIComponent(file.alias) + |
|
|
|
"&filename=" + |
|
|
|
encodeURIComponent(file.archName); |
|
|
|
this.officeUrl = |
|
|
|
process.env.API_WEB + |
|
|
|
"static/pdfjs-2.2.228-dist/web/viewer.html?file=" + |
|
|
|
fileUrl; |
|
|
|
this.officeUrl = process.env.OFFICE_WEB + "?furl=" + file.alias; |
|
|
|
this.$axios({ |
|
|
|
method: "delete", |
|
|
|
url: encodeURI( |
|
|
@@ -213,17 +205,7 @@ |
|
|
|
file.extension == "txt" |
|
|
|
) { |
|
|
|
this.showOffice = true; |
|
|
|
var lastIndex = file.alias.lastIndexOf("."); |
|
|
|
var namePdf = file.alias.substring(0, lastIndex) + ".pdf"; |
|
|
|
var fileUrl = |
|
|
|
encodeURIComponent(process.env.API_HOST + "archives/pdf?path=") + |
|
|
|
encodeURIComponent(namePdf) + |
|
|
|
"&filename=" + |
|
|
|
encodeURIComponent(file.archName); |
|
|
|
this.officeUrl = |
|
|
|
process.env.API_WEB + |
|
|
|
"static/pdfjs-2.2.228-dist/web/viewer.html?file=" + |
|
|
|
fileUrl; |
|
|
|
this.officeUrl = process.env.OFFICE_WEB + "?furl=" + file.alias; |
|
|
|
this.$axios({ |
|
|
|
method: "delete", |
|
|
|
url: encodeURI( |
|
|
|