修改文件上传为多个
This commit is contained in:
parent
c35ff719c6
commit
e4827b4fe6
|
@ -346,6 +346,7 @@
|
|||
style="height: 69vh; width: 70%"
|
||||
:disable="uploader_loading"
|
||||
:url="getUrl"
|
||||
multiple
|
||||
method="post"
|
||||
:headers="generatorFileUploadHeaders"
|
||||
:label="$t('select file') + ':'"
|
||||
|
@ -687,7 +688,6 @@ export default defineComponent({
|
|||
loading.value = false;
|
||||
};
|
||||
|
||||
|
||||
const refresh_file_list_async = async () => {
|
||||
const response = await _request_list_files(path.value);
|
||||
_show_files(response);
|
||||
|
@ -1148,7 +1148,7 @@ export default defineComponent({
|
|||
}
|
||||
}, 1);
|
||||
},
|
||||
onUploaded() {
|
||||
onUploaded(info: any) {
|
||||
uploading.value = false;
|
||||
uploader.value.reset();
|
||||
refresh_file_list();
|
||||
|
@ -1161,8 +1161,10 @@ export default defineComponent({
|
|||
});
|
||||
loading.value = false;
|
||||
},
|
||||
onFailed(info: any) {
|
||||
console.log(info);
|
||||
async onFailed(info: any) {
|
||||
let file_list: any = await _request_list_files(path.value);
|
||||
setTimeout(() => {
|
||||
if (files.value.length != file_list.files.length) {
|
||||
$q.notify({
|
||||
type: "warning",
|
||||
message: $t.t("file upload") + $t.t("fail") + "!",
|
||||
|
@ -1170,7 +1172,9 @@ export default defineComponent({
|
|||
timeout: 1500,
|
||||
});
|
||||
loading.value = false;
|
||||
loading.value = false;
|
||||
}
|
||||
}, 500);
|
||||
|
||||
},
|
||||
copyFile(file: FileEntity) {
|
||||
if (file) {
|
||||
|
|
Loading…
Reference in New Issue