elementUI upload 上传 传参

2019-08-26
<el-upload
  class="upload-demo"
  action="https://jsonplaceholder.typicode.com/posts/"
  :on-preview="handlePreview"
  :on-remove="handleRemove"
  :before-remove="beforeRemove"
  multiple
  :limit="3"
  :on-exceed="handleExceed"
:on-success="(response, file, fileList) => uploadSuccess(response, file, fileList, scope.$index)" :file-list="fileList"> <el-button size="small" type="primary">点击上传</el-button> <div slot="tip" class="el-upload__tip">只能上传jpg/png文件,且不超过500kb</div> </el-upload>

  js

methods:{
   uploadSuccess(response, file, fileList, scope.$index){

   }

}