feat: 字典模型初版
parent
86545423b5
commit
8b58d6775d
|
@ -0,0 +1,10 @@
|
||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
// 查询字典列表
|
||||||
|
export function findDictionaryByStructureId(id) {
|
||||||
|
return request({
|
||||||
|
url: '/dataSource/dict/findDictionaryByStructureId?id='+id,
|
||||||
|
method: 'get',
|
||||||
|
params:id
|
||||||
|
})
|
||||||
|
}
|
|
@ -74,11 +74,9 @@ export default {
|
||||||
dataBaseTableInformation(){
|
dataBaseTableInformation(){
|
||||||
dataBaseTableInformation().then(res=>{
|
dataBaseTableInformation().then(res=>{
|
||||||
this.informationNum=res.data.length;
|
this.informationNum=res.data.length;
|
||||||
// this.dataTotal+=res.data.dataTotal
|
|
||||||
res.data.forEach(item=>{
|
res.data.forEach(item=>{
|
||||||
this.dataTotal+=item.dataTotal
|
this.dataTotal+=item.dataTotal
|
||||||
})
|
})
|
||||||
// console.log(res.data)
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleSetLineChartData(type) {
|
handleSetLineChartData(type) {
|
||||||
|
|
|
@ -1,6 +1,4 @@
|
||||||
<template>
|
<template>
|
||||||
|
|
||||||
|
|
||||||
<el-container :style="{height: mainHeight + 'px'}">
|
<el-container :style="{height: mainHeight + 'px'}">
|
||||||
<el-aside>
|
<el-aside>
|
||||||
<el-tree :data="assetStructureList"
|
<el-tree :data="assetStructureList"
|
||||||
|
@ -17,7 +15,7 @@
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-main>
|
<el-main>
|
||||||
<overall-assets v-if="showAssets==null" :sum="sum"/>
|
<overall-assets v-if="showAssets==null" :sum="sum"/>
|
||||||
<overall-specific-assets v-if="showAssets === 0" :num="num" :dataTotal="dataTotal" :databaseTableInformationList="databaseTableInformationList" :title="title"/>
|
<overall-specific-assets v-if="showAssets === 0" :dictionaryTypeList="dictionaryTypeList" :num="num" :dataTotal="dataTotal" :databaseTableInformationList="databaseTableInformationList" :title="title"/>
|
||||||
<overall-asset-structure v-if="showAssets === 1" :databaseTable="databaseTable" :databaseTableInformation="databaseTableInformation" :childrenList="childrenList" :title="title"/>
|
<overall-asset-structure v-if="showAssets === 1" :databaseTable="databaseTable" :databaseTableInformation="databaseTableInformation" :childrenList="childrenList" :title="title"/>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
|
@ -33,6 +31,7 @@ import {
|
||||||
findInformationById
|
findInformationById
|
||||||
} from "@/api/dataSource/source";
|
} from "@/api/dataSource/source";
|
||||||
import OverallAssetStructure from "@/views/dataSource/assets/OverallAssetStructure.vue";
|
import OverallAssetStructure from "@/views/dataSource/assets/OverallAssetStructure.vue";
|
||||||
|
import {findDictionaryByStructureId} from "@/api/dataSource/dictionary";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'assets',
|
name: 'assets',
|
||||||
|
@ -55,6 +54,7 @@ export default {
|
||||||
sum:0,
|
sum:0,
|
||||||
num:0,
|
num:0,
|
||||||
dataTotal:0,
|
dataTotal:0,
|
||||||
|
dictionaryTypeList:[],
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -75,6 +75,12 @@ export default {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
findDictionaryByStructureId(data.id).then(
|
||||||
|
res=>{
|
||||||
|
console.log(data.id)
|
||||||
|
this.dictionaryTypeList=res.data;
|
||||||
|
}
|
||||||
|
)
|
||||||
findDataBaseTable(data.id).then(
|
findDataBaseTable(data.id).then(
|
||||||
res=>{
|
res=>{
|
||||||
this.databaseTableInformation=res.data
|
this.databaseTableInformation=res.data
|
||||||
|
|
Loading…
Reference in New Issue