Demo:修复导入弹窗选择了一个文件后再把它删除实际上并没有删掉的问题

This commit is contained in:
街角小林
2024-03-07 10:40:21 +08:00
parent 798591f6f9
commit 70b6b0052f

View File

@@ -8,10 +8,12 @@
<el-upload
ref="upload"
action="x"
accept=".smm,.json,.xmind,.xlsx,.md"
:file-list="fileList"
:auto-upload="false"
:multiple="false"
:on-change="onChange"
:on-remove="onRemove"
:limit="1"
:on-exceed="onExceed"
>
@@ -117,6 +119,11 @@ export default {
}
},
// 移除文件
onRemove(file, fileList) {
this.fileList = fileList
},
/**
* @Author: 王林
* @Date: 2021-08-03 22:48:47