在使用element的upload组件的时候,发现上传成功的时候我请求接口,但是这个接口有个额外的参数需要在上传文件之前就要获取到。
<el-upload
ref="uploadFile"
:action="'/sys/common/upload'"
:headers="headers"
:accept="acceptFileTypeDocx"
:before-upload="beforeUploadDocx"
:on-success="uploadSuccess"
:on-error="uploadError"
:auto-upload="true"
:limit="1"
:file-list="fileList"
:show-file-list="false"
style="float: left;margin-right: 6px;">
<el-button type="text" @click="row(row)">上传</el-button>
</el-upload>
本来