添加资产展示

pull/7/head^2
Yueng 2024-09-02 20:12:37 +08:00
parent c20e4d1667
commit 7c8e69e1f6
4 changed files with 17 additions and 17 deletions

View File

@ -7,9 +7,9 @@ export function getExtractDataTableNameList() {
}) })
} }
export function findTableValueList(data) { export function findTableValueList(basicId,dataId,tableName) {
return request({ return request({
url: '/property/dataSource/findTableValueList', url: '/property/dataSource/findTableValueList?basicId='+basicId+"&dataId="+dataId+"&tableName="+tableName,
method: 'post', method: 'post',
data: data data: data
}) })

View File

@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<h1>测试4()- 资产展示</h1> <h1>资产展示</h1>
<el-container> <el-container>
<el-aside width="400px"> <el-aside width="400px">
@ -26,7 +26,7 @@
<el-descriptions class="margin-top" title="资产模型基本信息" :column="2" border> <el-descriptions class="margin-top" title="资产模型基本信息" :column="2" border>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">表名称</template> <template slot="label">表名称</template>
{{ tableBasic.tableName }} {{ tableBasic.name }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">表备注</template> <template slot="label">表备注</template>
@ -34,7 +34,7 @@
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">数据量</template> <template slot="label">数据量</template>
{{ tableBasic.dataNum }} {{ dataNum }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">是否核心</template> <template slot="label">是否核心</template>
@ -112,10 +112,10 @@ export default {
return { return {
data:[], data:[],
defaultProps: { defaultProps: {
children: 'children', children: 'tableNames',
label: 'tableName' label: 'name'
}, },
tableBasic:{}, tableBasic:[],
tableStructure:[], tableStructure:[],
assetShowList: [ assetShowList: [
// {key: ".sys_user.id", type: "String", value: 1}, // {key: ".sys_user.id", type: "String", value: 1},
@ -124,9 +124,8 @@ export default {
// {key: ".sys_user.email", type: "String", value: "123@136.com"}, // {key: ".sys_user.email", type: "String", value: "123@136.com"},
// {key: ".sys_user.sex", type: "String", value: "Y"}, // {key: ".sys_user.sex", type: "String", value: "Y"},
], ],
kvtList: [],
DataValue:[], DataValue:[],
dataNum:'',
}; };
}, },
// data", // data",
@ -145,16 +144,17 @@ export default {
handleNodeClick(data){ handleNodeClick(data){
console.log("...."+data) console.log("...."+data)
this.tableBasic=data this.tableBasic=data
console.log(this.tableBasic)
dataNum=this.tableBasic.tableFie.length
// findStructureByTableId(data.id).then((res)=>{ // findStructureByTableId(data.id).then((res)=>{
// this.tableStructure=res.data // this.tableStructure=res.data
// }) // })
if (data.children==null){
findTableValueList(data.basicId,data.tableName).then(res=>{ findTableValueList(data.id,data.dataId,data.tableName).then(res=>{
this.assetShowList=res.data; this.assetShowList=res.data;
this.DataValue=res.data; this.DataValue=res.data;
}) })
}
console.log("-----"+this.DataValue); console.log("-----"+this.DataValue);
console.log("...."+data.basicId) console.log("...."+data.basicId)

View File

@ -136,7 +136,7 @@ export default {
console.log(this.tableBasic.length) console.log(this.tableBasic.length)
if (this.tableBasic.length === undefined){ if (this.tableBasic.length === undefined){
selectBasicList().then(ress=>{ selectBasicList().then(ress=>{
this.tableBasic.ress.data this.tableBasic = ress.data
this.tableBasics.data this.tableBasics.data
}) })
this.dataNum=data.tableFie.length this.dataNum=data.tableFie.length