赞
踩
:table-cols='tableColsMax'
:table-data='tableData'
v-loading="loading"
element-loading-text="拼命加载中"
element-loading-spinner="el-icon-loading"
element-loading-background="rgba(0, 0, 0, 0.3)"
data() { return { tableColsMax: [], //表头数据 tableData: [], //表格数据 loading: true, testCols: [ { label: '站名', prop: 'dataName', }, { label: '2-01', prop: 'one', }, { label: '2-02', prop: 'two', }, { label: '2-03', prop: 'three', }, ], testData: [ { dataName: '111', one: '正常',two: '正常', three: '不正常' }, { dataName: '111', one: '正常',two: '不正常', three: '不正常' }, { dataName: '111', one: '不正常',two: '正常', three: '不正常' }, ], } }
getData() {
setTimeout(() => {
this.tableColsMax = this.testCols
this.tableData = this.testData
}, 4000)
},
testChange() {
this.loading = false
}
mounted() {
this.getData()
}
watch: {
tableData: 'testChange'
}
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。