https://github.com/xaboy/form-builder#readme
Showing posts with label VUEIVIEW. Show all posts
Showing posts with label VUEIVIEW. Show all posts
Tuesday, 18 May 2021
Monday, 17 May 2021
Vue iview plugin Table rendering function
https://www.programmersought.com/article/2791772083/
https://www.iviewui.com/components/table-en
, a simple example
- render: (h, params) => {
- return h('span', 'hello');
- }
3, display multiple content at the same time
- render: (h, params) => {
- return h('div', [
- h('span', params.row.name),
- h('span', ' ('+params.row.age+')')
- ]);
- }
4, processing the data
Any data processing can be done before the data is returned
1>Time format conversion
- render: (h, params) => {
- let time = this.$moment(params.row.time).format('YYYY-MM-DD HH:mm:ss')
- return h('span', time);
- }
2> data processing: array splicing string, etc.
- render: (h, params) => {
- let str = ''
- for (let i = 0, len = params.row.arr.length; i < len; i++) {
- str += `${params.row.arr[i].name}-${params.row.arr[i].age} | `
- }
- return h('span', str);
Subscribe to:
Posts (Atom)