mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-18 08:12:15 +00:00
upload file into request folder and get their thumbnails
This commit is contained in:
18
resources/js/store/modules/uploadRequest.js
vendored
18
resources/js/store/modules/uploadRequest.js
vendored
@@ -8,7 +8,23 @@ const defaultState = {
|
||||
uploadRequest: undefined,
|
||||
}
|
||||
|
||||
const actions = {}
|
||||
const actions = {
|
||||
getUploadRequestDetail: ({ commit, getters }) => {
|
||||
|
||||
axios.get(`/api/upload-request/${router.currentRoute.params.token}`)
|
||||
.then((response) => {
|
||||
|
||||
commit('LOADING_STATE', { loading: false, data: [] })
|
||||
|
||||
commit('SET_UPLOAD_REQUEST', response.data)
|
||||
|
||||
// Set current folder if exist
|
||||
if (response.data.data.relationships.folder) {
|
||||
commit('SET_CURRENT_FOLDER', response.data.data.relationships.folder)
|
||||
}
|
||||
})
|
||||
},
|
||||
}
|
||||
|
||||
const mutations = {
|
||||
SET_UPLOAD_REQUEST(state, payload) {
|
||||
|
||||
Reference in New Issue
Block a user