<el-upload
ref="upload"
:class="{ imageupload: true, disabled: isMax }"
action=""
:on-change="getFile"
:on-remove="handleRemove"
list-type="picture-card"
:file-list="fileList"//显示预览
:on-preview="handlePictureCardPreview"
:auto-upload="false"
:limit="1"
style="display: flex"
>
<i
class="el-icon-plus"
style="width: 30px; height: 30px; font-size: 30px"
/>
</el-upload>
data() {
return{
fileList: [],//显示的预览图
}
}
this.fileList.push({ url: 'data:image/jpg;base64,' + this.formdata.frontphoto })