fix : 修改提交/重新提交功能文件传参问题

This commit is contained in:
2024-06-07 20:36:54 +08:00
parent ee81e1bb23
commit 27bc6ea89f
5 changed files with 72 additions and 134 deletions

View File

@@ -428,21 +428,19 @@ const handleSubmit = debounce(async (instance) => {
})
const handleResubmit = debounce(() => {
let otherFiles = []
let fileArray
if (name.value === 'Summary/edit') {
fileArray = attachment.value.allFileList
attachment.value.allFileList.forEach(item => {
otherFiles.push(getFileParam(item))
})
}
fileArray.forEach(item => {
otherFiles.push(getFileParam(item))
})
let params = {
...formData.value,
deploymentId: deploymentId.value,
fileList: otherFiles,
requirementId: route.query.id ? route.query.id : '-1'
}
console.log('重新提交params', params, formData.value)
if (!attachment.value.isSingleFile&&!formData.value.singleFile) {
console.log('重新提交params', params)
if (!attachment.value.isSingleFile || !formData.value.singleFile) {
attachment.value.validate()
ElNotification({
title: '提示',