public share navigation

This commit is contained in:
Peter Papp
2021-08-23 08:30:34 +02:00
parent 882b5543f0
commit 26e3194f21
11 changed files with 193 additions and 56 deletions

View File

@@ -121,6 +121,7 @@
'isVisibleSidebar',
'FilePreviewType',
'currentFolder',
'sharedDetail',
'clipboard',
]),
isLoadedFolder() {

View File

@@ -258,18 +258,19 @@ export default {
// Clear selected items after open another folder
this.$store.commit('CLIPBOARD_CLEAR')
if (this.$isThisLocation('public')) {
this.$store.dispatch('browseShared', [{folder: this.item, back: false, init: false}])
} else {
let route = this.$router.currentRoute.name
let route = this.$router.currentRoute.name
if (route === 'Files')
this.$router.push({name: 'Files', params: {id: this.item.id}})
if (route === 'Trash')
this.$router.push({name: 'Trash', params: {id: this.item.id}})
else
this.$router.push({name: 'Files', params: {id: this.item.id}})
}
if (route === 'Public') {
this.$router.push({name: 'Public', params: {token: this.$route.params.token, id: this.item.id}})
}
if (route === 'Trash') {
this.$router.push({name: 'Trash', params: {id: this.item.id}})
}
if (route === 'Files') {
this.$router.push({name: 'Files', params: {id: this.item.id}})
}
}
},
renameItem: debounce(function (e) {