diff --git a/src/components/AttachmentUpload.vue b/src/components/AttachmentUpload.vue index ce4ea51..400e929 100644 --- a/src/components/AttachmentUpload.vue +++ b/src/components/AttachmentUpload.vue @@ -133,14 +133,13 @@ watch(() => props.showTable, (newVal) => { watch(() => props.otherFileList, (newVal) => { console.log('newotherFileList', newVal) if (props.preview) { - if (props.formData.fileList == null) { + if (props.formData.fileList.length===0) { allFileList.value = newVal } else { newVal?.forEach(item => { allFileList.value.push(item) }) } - } else { allFileList.value = newVal }