1.通过点击按钮预览,
<el-button size="small" @click="handlecompreview(row,$index)">预览</el-button>
<el-dialog :visible.sync="imageDialog" title="预览" width="40%">
<el-image
style="width: 100%; height: 100%"
:src="ImageUrl"
:preview-src-list="[ImageUrl]"
> />
</el-image>
// 预览
handlepreview(row) {
//调预览接口
previewSupplierOrderImg({ Id: row.Id }).then((res) => {
this.ImageUrl = res.Data
if (this.ImageUrl) {
this.imageDialog = true
}
})
},