实现如下图片展示效果:
页面:html/vue
<el-table :data="tableData" border style="width: 100%;margin-top:20px;">
<el-table-column prop="picture" label="头像" align="center">
<template slot-scope="scope">
<img :src="scope.row.image" min-width="70" height="70" />
</template>
</el-table-column>
<el-table-column prop="name" label="人" align="center"></el-table-column>
<el-table-column prop="" label="地址" align="center"></el-table-column>
</el-table>
js:
var app = new Vue({
el:'#app',
data:{
tableData: [{
image: 'https://gss1.bdstatic.com/-vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike92%2C5%2C5%2C92%2C30/sign=1a3d82d42f2dd42a4b0409f9625230d0/314e251f95cad1c86a912b9a753e6709c93d5161.jpg',
name: '王小虎',
address: '上海市普陀区金沙江路 1518 弄'
}, {
image: 'https://gss1.bdstatic.com/-vo3dSag_xI4khGkpoWK1HF6hhy/baike/c0%3Dbaike92%2C5%2C5%2C92%2C30/sign=1a3d82d42f2dd42a4b0409f9625230d0/314e251f95cad1c86a912b9a753e6709c93d5161.jpg',
name: '王小虎',
address: '上海市普陀区金沙江路 1517 弄'
}]
}
})