资产结构测试2
parent
180fd905fc
commit
95db638abb
|
@ -57,6 +57,13 @@ export default {
|
|||
structureNum: null,
|
||||
}
|
||||
},
|
||||
|
||||
watch:{
|
||||
infoOpen(newName, oldName){
|
||||
console.log(newName)
|
||||
console.log(oldName)
|
||||
}
|
||||
},
|
||||
name: 'AssetsBasic',
|
||||
components: {
|
||||
CountTo
|
||||
|
@ -143,7 +150,7 @@ export default {
|
|||
float: right;
|
||||
font-weight: bold;
|
||||
margin: 26px;
|
||||
margin-left: 0px;
|
||||
margin-left: 0;
|
||||
|
||||
.card-panel-text {
|
||||
line-height: 18px;
|
||||
|
|
|
@ -1,8 +1,54 @@
|
|||
<template>
|
||||
<el-row :gutter="40" class="panel-group">
|
||||
<div class="title-header">
|
||||
|
||||
</div>
|
||||
{{tableInfo}}
|
||||
<el-card>
|
||||
|
||||
<el-tabs type="border-card" @tab-click="handleClick">
|
||||
<el-tab-pane
|
||||
v-for="tableInfo in list"
|
||||
|
||||
:label="tableInfo.tableName+'('+tableInfo.info.tableRemark+')'">
|
||||
<el-card>
|
||||
|
||||
<div slot="header" class="clearfix">
|
||||
<span>资产模型基本信息</span>
|
||||
</div>
|
||||
|
||||
<el-descriptions
|
||||
class="margin-top"
|
||||
:column="2" :size="size"
|
||||
border>
|
||||
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
<i class="el-icon-user"></i>
|
||||
表名称
|
||||
</template>
|
||||
{{tableInfo.info.tableName}}
|
||||
</el-descriptions-item>
|
||||
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
<i class="el-icon-mobile-phone"></i>
|
||||
表备注
|
||||
</template>
|
||||
{{tableInfo.info.tableRemark}}
|
||||
</el-descriptions-item>
|
||||
|
||||
<el-descriptions-item>
|
||||
<template slot="label">
|
||||
<i class="el-icon-mobile-phone"></i>
|
||||
表备注
|
||||
</template>
|
||||
{{tableInfo.info.tableRemark}}
|
||||
</el-descriptions-item>
|
||||
|
||||
</el-descriptions>
|
||||
</el-card>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</el-card>
|
||||
</el-row>
|
||||
</template>
|
||||
|
||||
|
@ -11,11 +57,8 @@ import CountTo from 'vue-count-to'
|
|||
|
||||
export default {
|
||||
props:{
|
||||
fundDataNum: {
|
||||
basicNum: null,
|
||||
tableNum: null,
|
||||
structureNum: null,
|
||||
}
|
||||
info:{},
|
||||
list:[],
|
||||
},
|
||||
name: 'AssetsModel',
|
||||
components: {
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
|
||||
|
||||
<AssetsBasic :infoOpen="infoOpen" :fundDataNum="fundDataNum"></AssetsBasic>
|
||||
<AssetsModel v-if=""></AssetsModel>
|
||||
<AssetsModel v-if="infoOpen" :info="tableInfoForm" :list="tableInfoList"></AssetsModel>
|
||||
</el-main>
|
||||
</el-container>
|
||||
</div>
|
||||
|
@ -21,12 +21,15 @@
|
|||
|
||||
import {getTableTree} from "@/api/etl/etl";
|
||||
import AssetsBasic from "@/views/etl/construction/AssetsBasic.vue";
|
||||
import AssetsModel from "@/views/etl/construction/AssetsModel.vue";
|
||||
|
||||
export default {
|
||||
name:'construction',
|
||||
components:{ AssetsBasic },
|
||||
components:{AssetsModel, AssetsBasic },
|
||||
data() {
|
||||
return {
|
||||
//结构标题
|
||||
title: null,
|
||||
//查看详细资产结构
|
||||
infoOpen: false,
|
||||
//资产结构与数据结构载体
|
||||
|
@ -90,21 +93,23 @@ export default {
|
|||
},
|
||||
//获取具体表相关数据
|
||||
handleNodeClick(data) {
|
||||
console.log(data);
|
||||
//获取asserstureList中的对象
|
||||
let info = this.assetStructureList.find(
|
||||
assent => assent.info.id === data.info.id
|
||||
)
|
||||
this.infoOpen = true
|
||||
if (data.length()===3){
|
||||
this.tableInfoList = data
|
||||
this.tableInfoForm = data.children[0]
|
||||
|
||||
//先将对象存入infoform
|
||||
this.tableInfoForm = data
|
||||
//如果判断对象不存在,重新给form 和listfuhi
|
||||
if (info !==undefined){
|
||||
this.tableInfoList = data.children
|
||||
this.tableInfoForm = data.constructor=[0]
|
||||
}else {
|
||||
this.tableInfoForm = data
|
||||
let info = this.assetStructureList.stream.filter(assent =>
|
||||
assent.info.id===data.basicId
|
||||
)
|
||||
console.log(info)
|
||||
this.tableInfoList = info[0].children
|
||||
info = this.assetStructureList.find(assent=>
|
||||
assent.info.id === this.tableInfoForm.info.basicId)
|
||||
this.tableInfoList = info.children
|
||||
}
|
||||
console.log(this.tableInfoList)
|
||||
console.log(this.tableInfoForm)
|
||||
},
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue