🔨 查询上传任务.

This commit is contained in:
lijiahang
2024-05-10 13:21:08 +08:00
parent cd312ef5c8
commit 564e40a31d
10 changed files with 210 additions and 60 deletions

View File

@@ -74,7 +74,7 @@
import type { FileItem } from '@arco-design/web-vue';
import type { UploadTaskFileCreateRequest } from '@/api/exec/upload-task';
import type { IFileUploader } from '@/components/system/uploader/const';
import { ref } from 'vue';
import { onUnmounted, ref } from 'vue';
import { getFileSize } from '@/utils/file';
import FileUploader from '@/components/system/uploader/file-uploader';
@@ -127,6 +127,11 @@
defineExpose({ getFiles, startUpload, close });
// 卸载时关闭
onUnmounted(() => {
uploader.value?.close();
});
</script>
<style lang="less" scoped>

View File

@@ -58,8 +58,9 @@
const filesRef = ref();
const hostModal = ref<any>();
// TODO pullstatus
// TODO 测试 error 情况
// TODO pullstatus 按钮显示就可以去掉了吧
// host tab
// status tab
// 设置选中主机
const setSelectedHost = (hosts: Array<number>) => {
@@ -147,6 +148,7 @@
const clear = () => {
status.value = UploadTaskStatus.WAITING;
formModel.value = { ...defaultForm() };
filesRef.value?.close();
};
</script>