ElemeFE / ElemeFE/element

[bug report] the manual upload method of upload component can't delete the files in the file list perfectly

Open
#21,151 2 comments 0 reactions 0 assignees View on GitHub
component: upload type: bug
Dominant language
Vue
Stars
54k
Forks
14.4k
PR merge metrics
No merged PRs in 30d

Description

### Element UI version
2.15.3

### OS/Browsers version
win10,chrome

### Vue version
2.5.21

### Reproduction Link
https://jsfiddle.net/9vnj8w4e/

### Steps to reproduce
当我多选了多个文件之后,我发现选错了一个,我想删除掉一个,是没办法实现的,因为触发before-upload事件的同时,也会出发on-remove或者before-remove,我如果在这两个钩子函数做删除(before-upload(file, fileList){ this.fileList = fileList }),那么我选择上传的文件就会少一个

### What is Expected?
当我多选了多个文件之后,我发现选错了一个,我想删除掉一个,是没办法实现的,在on-remove或者before-remove做删除(before-upload(file, fileList){ this.fileList = fileList }),文件列表正常删除掉一个。

### What is actually happening?
当我多选了多个文件之后,我发现选错了一个,我想删除掉一个,是没办法实现的,因为触发before-upload事件的同时,也会出发on-remove或者before-remove,我如果在这两个钩子函数做删除(before-upload(file, fileList){ this.fileList = fileList }),那么我选择上传的文件就会少一个

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.