Files
vxe-table/examples/plugins/xtable/renderer/content.js
2020-03-14 17:37:44 +08:00

29 lines
643 B
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import VXETable from '../../../../packages/v-x-e-table'
// 创建一个展开内容渲染器
VXETable.renderer.add('MyExpand', {
renderExpand (h, renderOpts, params) {
const { row } = params
return [
<ul>
<li>
<span>ID</span>
<span>{ row.id }</span>
</li>
<li>
<span>Name</span>
<span>{ row.name }</span>
</li>
<li>
<span>UpdateTime</span>
<span>{ row.updateTime }</span>
</li>
<li>
<span>CreateTime</span>
<span>{ row.createTime }</span>
</li>
</ul>
]
}
})