team folder browsing with static team folder details

This commit is contained in:
Peter Papp
2021-08-31 14:08:47 +02:00
parent f44e262d6e
commit a3516769de
46 changed files with 317 additions and 225 deletions

View File

@@ -46,35 +46,6 @@ const actions = {
}
})
},
getTeamFolder: ({commit, getters}, id) => {
commit('LOADING_STATE', {loading: true, data: []})
axios
.get(`${getters.api}/teams/folders/${id}/${getters.sorting.URI}`)
.then(response => {
commit('LOADING_STATE', {loading: false, data: response.data.folders.data})
commit('SET_CURRENT_FOLDER', response.data.root)
events.$emit('scrollTop')
})
.catch(error => {
// Redirect if unauthenticated
if ([401, 403].includes(error.response.status)) {
commit('SET_AUTHORIZED', false)
router.push({name: 'SignIn'})
} else {
// Show error message
events.$emit('alert:open', {
title: i18n.t('popup_error.title'),
message: i18n.t('popup_error.message'),
})
}
})
},
getRecentUploads: ({commit, getters}) => {
commit('LOADING_STATE', {loading: true, data: []})