feat: change location on edit file
This also fix when edit file on seach which cannot detect existing file(s)
This commit is contained in:
parent
c1eaeb5c64
commit
4cd95143d8
1 changed files with 5 additions and 1 deletions
|
|
@ -7,7 +7,7 @@ import UploadExistDialog from './UploadExistDialog.vue'
|
||||||
|
|
||||||
const storageStore = useStorage()
|
const storageStore = useStorage()
|
||||||
const { file, currentInfo } = storeToRefs(storageStore)
|
const { file, currentInfo } = storeToRefs(storageStore)
|
||||||
const { createFile, updateFile } = storageStore
|
const { createFile, updateFile, goto } = storageStore
|
||||||
|
|
||||||
const fileFormState = ref<boolean>(false)
|
const fileFormState = ref<boolean>(false)
|
||||||
const fileFormPath = ref<string>('')
|
const fileFormPath = ref<string>('')
|
||||||
|
|
@ -61,6 +61,10 @@ function triggerFileEdit(
|
||||||
metadata: value.metadata,
|
metadata: value.metadata,
|
||||||
}
|
}
|
||||||
fileNameLabel.value = file
|
fileNameLabel.value = file
|
||||||
|
|
||||||
|
const arr = pathname.split('/')
|
||||||
|
arr[arr.length - 1] = ''
|
||||||
|
goto(arr.join('/'))
|
||||||
}
|
}
|
||||||
|
|
||||||
defineExpose({
|
defineExpose({
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue