Skip to content

When uploading a file, use beforeUpload to modify the name of the uploaded file. The modification and upload can be successful, but there is an error message in the console #6208

@5563

Description

@5563
  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

1.7.2

Environment

谷歌浏览器, vue2.0

Reproduction link

Edit on CodeSandbox

Steps to reproduce

  1. 使用 upload组件第一个例子
  2. 在组件中添加 beforeUpload 实现上传文件修改名字的功能
beforeUpload(file) {
   return new Promise((resolve) => {
     let temp = new File([file], 'ssss.jpeg')
     resolve(temp)
   })
},

What is expected?

预期结果是希望能够修改成功,并且控制台没有报错信息

What is actually happening?

实际,文件上传成功了,也是改名后的,但是控制台有报错信息,希望知道怎么样就没有报错信息,报错信息如下

[Vue warn]: Invalid prop: custom validator check failed for prop "items".

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions