添加资产授权

yuan
Yueng 2024-09-08 23:15:30 +08:00
parent 2e83199138
commit a884b72720
4 changed files with 29 additions and 45 deletions

View File

@ -7,4 +7,10 @@ export function getExtractDataTableNameList() {
}) })
} }
export function tableStructureShow(data) {
return request({
url: '/property/dataRunName/tableStructureShow',
method: 'post',
data:data
})
}

View File

@ -20,3 +20,11 @@ export function selectBasicList() {
method: 'post', method: 'post',
}) })
} }
export function tableStructureShow(data) {
return request({
url: '/property/dataRunName/tableStructureShow',
method: 'post',
data:data
})
}

View File

@ -99,7 +99,7 @@
<script> <script>
//jsjsjson, //jsjsjson,
//import from ', //import from ',
import { findTableValue, getExtractDataTableNameList, selectBasicList } from '@/api/property/asDisplay' import { tableStructureShow } from '@/api/property/astr'
export default { export default {
//import使" //import使"
@ -143,23 +143,14 @@ export default {
}, },
handleNodeClick(data){ handleNodeClick(data){
console.log("...."+data) if (this.data.name!=data.name){
tableStructureShow(data).then(res=>{
this.tableBasic=data this.tableBasic=data
console.log(res)
// findStructureByTableId(data.id).then((res)=>{ this.dataNum=res.data.length
// this.tableStructure=res.data this.tableStructure=res.data
// })
if (data.children==null){
findTableValueList(data.basicId,data.tableName).then(res=>{
this.assetShowList=res.data;
this.DataValue=res.data;
}) })
} }
console.log("-----"+this.DataValue);
console.log("...."+data.basicId)
}
}, },
// - 访this", // - 访this",
created() { created() {

View File

@ -87,7 +87,7 @@
//jsjsjson, //jsjsjson,
//import from ', //import from ',
import { findTableValue, getExtractDataTableNameList } from '@/api/property/astr' import { getExtractDataTableNameList, tableStructureShow } from '@/api/property/astr'
export default { export default {
//import使" //import使"
@ -124,35 +124,14 @@ export default {
}) })
}, },
handleNodeClick(data){ handleNodeClick(data){
// console.log(data) console.log(data)
this.tableBasic=data this.tableBasic=data
this.dataNum=data.tableFie.length
this.tableStructure=data.tableFie
// console.log(this.tableStructure)
findTableValue(data.dataId,data.name).then(res=>{
let tableMapping=res.data
// console.log(res.data)
for (const index in tableMapping) {
for (const i in this.tableStructure) {
if (tableMapping[index].key === this.tableStructure[i].field) {
this.tableStructure[i].types.push(tableMapping[index].type)
console.log(this.tableStructure[i].types)
if (i!== 0&& this.tableStructure[i].types==this.tableStructure[0].types){
alert("dawdwadad")
return
}
}
}
}
tableStructureShow(data).then(res=>{
console.log(res)
this.dataNum=res.data.length
this.tableStructure=res.data
}) })
},
}, },