增加文档部分功能
This commit is contained in:
@@ -95,6 +95,7 @@
|
||||
hideRefresh: { type: Boolean, default: false },
|
||||
hideSetting: { type: Boolean, default: false },
|
||||
paginationLayout: { type: String, default: config.paginationLayout },
|
||||
rowChild:{type:Boolean, default:true}
|
||||
},
|
||||
watch: {
|
||||
//监听从props里拿到值了
|
||||
@@ -210,7 +211,16 @@
|
||||
if(this.hidePagination){
|
||||
this.tableData = response.data || [];
|
||||
}else{
|
||||
this.tableData = response.rows || [];
|
||||
if(!this.rowChild){
|
||||
response.rows.forEach(item=>{
|
||||
item.data = item.children;
|
||||
delete item.children
|
||||
})
|
||||
this.tableData = response.rows || [];
|
||||
console.log('数据处理')
|
||||
}else{
|
||||
this.tableData = response.rows || [];
|
||||
}
|
||||
}
|
||||
if(response.data.columnConfig){
|
||||
this.userColumn = response.data.columnConfig; // 表头获取
|
||||
|
||||
Reference in New Issue
Block a user