回退到根目录就不做操作
This commit is contained in:
parent
46580cbc7b
commit
b9ef107311
@ -851,10 +851,14 @@ export default {
|
|||||||
},
|
},
|
||||||
// 浏览器的返回事件
|
// 浏览器的返回事件
|
||||||
goBack(){
|
goBack(){
|
||||||
|
if (this.pathList.length === 2){
|
||||||
|
this.$router.push(`/?vmode=${this.vmode}&path=${encodeURIComponent(this.path)}`)
|
||||||
|
return
|
||||||
|
}
|
||||||
const linkIndex = this.pathList.length-3
|
const linkIndex = this.pathList.length-3
|
||||||
this.handleLink(this.pathList[linkIndex],linkIndex)
|
this.handleLink(this.pathList[linkIndex],linkIndex)
|
||||||
},
|
},
|
||||||
handleLink(item, index, unPushLink) {
|
handleLink(item, index, unPushLink, unRefresh) {
|
||||||
if(item && item.search){
|
if(item && item.search){
|
||||||
if(item.searchKey){
|
if(item.searchKey){
|
||||||
this.searchFileByKeyWord(item.searchKey)
|
this.searchFileByKeyWord(item.searchKey)
|
||||||
@ -874,17 +878,17 @@ export default {
|
|||||||
})
|
})
|
||||||
if(!unPushLink){
|
if(!unPushLink){
|
||||||
if (!this.$route.query.path){
|
if (!this.$route.query.path){
|
||||||
this.$router.push(`/_m`)
|
this.$router.push(`/?vmode=${this.vmode}&path=${encodeURIComponent(this.path)}`)
|
||||||
} else {
|
} else {
|
||||||
// this.$router.push(`?path=${encodeURIComponent(this.path)}`)
|
|
||||||
this.$router.push(`?vmode=${this.vmode}&path=${encodeURIComponent(this.path)}`)
|
this.$router.push(`?vmode=${this.vmode}&path=${encodeURIComponent(this.path)}`)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
setPath(this.path, this.pathList)
|
if(!unRefresh){
|
||||||
this.pagination.pageIndex = 1
|
this.pagination.pageIndex = 1
|
||||||
this.getFileList()
|
this.getFileList()
|
||||||
|
}
|
||||||
|
// setPath(this.path, this.pathList)
|
||||||
}
|
}
|
||||||
console.log("this.pathList:", this.pathList)
|
|
||||||
},
|
},
|
||||||
// 新建文档
|
// 新建文档
|
||||||
newDocument() {
|
newDocument() {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user