vue + iview的render添加ref属性
vue + iview的render添加ref属性render: (h, params) => {let create = this.$createElementlet dom = create('div', {ref: params...
·
vue + iview的render添加ref属性
render: (h, params) => {
let create = this.$createElement
let dom = create('div', {
ref: params.row.ref,
props: {
type: 'text',
size: 'small'
},
domProps: {
innerHTML: params.row.activeText
},
attrs: {
class: 'btn'
},
style: {
width: '100%',
height: '40px',
lineHeight: '40px',
testAlign: 'center',
marginRight: '5px',
cursor: 'pointer'
},
on: {
click: () => {
this.operate(params.row)
}
}
})
return dom
}
更多推荐
已为社区贡献7条内容
所有评论(0)