style: 私密分享的office文件挂载后无法预览的问题
This commit is contained in:
parent
df604dd4b1
commit
a20502fc05
@ -142,6 +142,14 @@ export default {
|
|||||||
if (!res) {
|
if (!res) {
|
||||||
return []
|
return []
|
||||||
}
|
}
|
||||||
|
console.log('checkChunkUploadedByResponse', res)
|
||||||
|
if (res.duplicate) {
|
||||||
|
if (confirm("文件已存在, 确定要覆盖吗?")) {
|
||||||
|
return true
|
||||||
|
} else {
|
||||||
|
return []
|
||||||
|
}
|
||||||
|
}
|
||||||
if (res.pass) {
|
if (res.pass) {
|
||||||
// 秒传
|
// 秒传
|
||||||
return true
|
return true
|
||||||
@ -322,6 +330,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
onFilesAdded(files) {
|
onFilesAdded(files) {
|
||||||
|
console.log('onFilesAdded', files)
|
||||||
if (files.length === 0) {
|
if (files.length === 0) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -395,6 +404,18 @@ export default {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const data = res.data
|
const data = res.data
|
||||||
|
|
||||||
|
// if (data.duplicate) {
|
||||||
|
// console.log(this.uploader)
|
||||||
|
// this.$refs.uploader.fileRemoved(file)
|
||||||
|
// if (confirm("文件已存在, 确定要覆盖吗?")) {
|
||||||
|
// this.$refs.uploader.fileAdded(file)
|
||||||
|
// this.$refs.uploader.uploadStart()
|
||||||
|
// } else {
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
|
||||||
// 服务器自定义的错误(即虽返回200,但是是错误的情况),这种错误是Uploader无法拦截的
|
// 服务器自定义的错误(即虽返回200,但是是错误的情况),这种错误是Uploader无法拦截的
|
||||||
if (!data.upload) {
|
if (!data.upload) {
|
||||||
// this.$message({ message: res.message, type: 'error' })
|
// this.$message({ message: res.message, type: 'error' })
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user