优化bug

This commit is contained in:
24kycj
2024-11-26 16:41:52 +08:00
parent 93212a8e96
commit ba8b99b7d2
3 changed files with 38 additions and 32 deletions
+16 -14
View File
@@ -283,18 +283,18 @@ export default {
value: 2,
label: 'ISO文件刻录'
},
// {
// value: 3,
// label: '复制光盘'
// },
// {
// value: 4,
// label: '自动批量读取光盘'
// },
// {
// value: 5,
// label: '自动归档任务'
// },
{
value: 3,
label: '复制光盘'
},
{
value: 4,
label: '自动批量读取光盘'
},
{
value: 5,
label: '自动归档任务'
},
],
fileProgess: 30,
// 模板列表
@@ -455,6 +455,7 @@ export default {
const files = this.$refs.files.getLists()
let fileList = []
that.submitFlag = true
that.form.ass_task = []
setTimeout(() => {
that.submitFlag = false
}, 1000)
@@ -520,8 +521,7 @@ export default {
})
return
}
total_size += fileList[i].size
if (total_size > diskSize) {
if (total_size + fileList[i].size > diskSize) {
that.form.ass_task.push(task)
total_size = 0
index++
@@ -531,10 +531,12 @@ export default {
path_file: []
}
}
total_size += fileList[i].size
task.path_file.push(fileList[i].path)
task.task_size += fileList[i].size
if (i === fileList.length - 1) that.form.ass_task.push(task)
}
console.log(that.form.ass_task)
} else {
let task = {
ass_task_index: 1,