pull/7/head^2
parent
7d8e8e6eec
commit
3189457a62
|
@ -47,10 +47,3 @@ export function delapi(productId){
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getprice(productId){
|
|
||||||
return request({
|
|
||||||
url:"/background/apimanage/getprice/"+productId,
|
|
||||||
method: "POST",
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
|
@ -7,12 +7,3 @@ export function gethostportList(){
|
||||||
method: "GET",
|
method: "GET",
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getcompany(){
|
|
||||||
return request({
|
|
||||||
url:"/market/company/selectcompany",
|
|
||||||
method: "POST",
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -6,3 +6,17 @@ export function getExtractDataTableNameList() {
|
||||||
method: 'post',
|
method: 'post',
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function findTableValue(dataId,name) {
|
||||||
|
return request({
|
||||||
|
url: '/property/dataRunName/findTableValue?dataId='+dataId+"&tableName="+name,
|
||||||
|
method: 'post',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export function selectBasicList() {
|
||||||
|
return request({
|
||||||
|
url: '/property/dataRunName/selectBasicList',
|
||||||
|
method: 'post',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
|
@ -48,3 +48,10 @@ export function selectHandleClick(data) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function extractDataName(data) {
|
||||||
|
return request({
|
||||||
|
url: '/property/dataRunName/extractDataName',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
|
@ -148,31 +148,7 @@ export const constantRoutes = [
|
||||||
path: 'index',
|
path: 'index',
|
||||||
name: 'apiupdmessage',
|
name: 'apiupdmessage',
|
||||||
component: () => import('@/views/background/apiupdmessage/index.vue'),
|
component: () => import('@/views/background/apiupdmessage/index.vue'),
|
||||||
meta: { title: '接口信息修改页面', icon: 'form' }
|
meta: { title: '接口列表', icon: 'form' }
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/product',
|
|
||||||
component: Layout,
|
|
||||||
children: [
|
|
||||||
{
|
|
||||||
path: 'index',
|
|
||||||
name: 'product',
|
|
||||||
component: () => import('@/views/market/product/index.vue'),
|
|
||||||
meta: { title: '数据块', icon: 'form' }
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: '/Workbench',
|
|
||||||
component: Layout,
|
|
||||||
children: [
|
|
||||||
{
|
|
||||||
path: 'index',
|
|
||||||
name: 'Workbench',
|
|
||||||
component: () => import('@/views/market/workbench/index.vue'),
|
|
||||||
meta: { title: '信息', icon: 'form' }
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
|
@ -116,12 +116,10 @@
|
||||||
:total="total">
|
:total="total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
|
|
||||||
|
|
||||||
<!--新增对话框-->
|
|
||||||
<el-dialog
|
<el-dialog
|
||||||
title="新增接口"
|
title="提示"
|
||||||
:visible.sync="dialogVisible"
|
:visible.sync="dialogVisible"
|
||||||
width="60%"
|
width="30%"
|
||||||
:before-close="handleClose">
|
:before-close="handleClose">
|
||||||
<center>
|
<center>
|
||||||
<el-form :model="api" status-icon :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
|
<el-form :model="api" status-icon :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
|
||||||
|
@ -134,6 +132,9 @@
|
||||||
<el-form-item label="接口描述" prop="productContent" style="width: 70%">
|
<el-form-item label="接口描述" prop="productContent" style="width: 70%">
|
||||||
<el-input type="text" v-model="api.productContent" autocomplete="off"></el-input>
|
<el-input type="text" v-model="api.productContent" autocomplete="off"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="接口价格" prop="productPrice" style="width: 70%">
|
||||||
|
<el-input type="text" v-model="api.productPrice" autocomplete="off"></el-input>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="接口来源" prop="productFrom" style="width: 70%">
|
<el-form-item label="接口来源" prop="productFrom" style="width: 70%">
|
||||||
<el-input type="text" v-model="api.productFrom" autocomplete="off"></el-input>
|
<el-input type="text" v-model="api.productFrom" autocomplete="off"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -149,28 +150,6 @@
|
||||||
<el-form-item label="请求方式" prop="requestMethod" style="width: 70%">
|
<el-form-item label="请求方式" prop="requestMethod" style="width: 70%">
|
||||||
<el-input type="text" v-model="api.requestMethod" autocomplete="off"></el-input>
|
<el-input type="text" v-model="api.requestMethod" autocomplete="off"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="选择默认规格" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-select v-model="api.productSpecification" placeholder="请选择默认规格">
|
|
||||||
<el-option label="按次查询" value="按次查询"></el-option>
|
|
||||||
<el-option label="包日" value="包日"></el-option>
|
|
||||||
<el-option label="包月" value="包月"></el-option>
|
|
||||||
<el-option label="包年" value="包年"></el-option>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-divider></el-divider>
|
|
||||||
<span>价格</span>
|
|
||||||
<el-form-item label="按次查询" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.timemoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="包日" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.daymoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="包月" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.monthmoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="包年" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.yearmoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
</el-form>
|
||||||
</center>
|
</center>
|
||||||
<span slot="footer" class="dialog-footer">
|
<span slot="footer" class="dialog-footer">
|
||||||
|
@ -192,13 +171,14 @@
|
||||||
//例如:import 《组件名称》 from '《组件路径》,
|
//例如:import 《组件名称》 from '《组件路径》,
|
||||||
import {
|
import {
|
||||||
addproduct,
|
addproduct,
|
||||||
delapi, getprice,
|
delapi,
|
||||||
|
productStateLis,
|
||||||
|
productStateList,
|
||||||
selectapiList,
|
selectapiList,
|
||||||
UpdproductState
|
UpdproductState
|
||||||
} from "@/api/background/apimanage";
|
} from "@/api/background/apimanage";
|
||||||
import {resetForm} from "@/utils/muyu";
|
import {resetForm} from "@/utils/muyu";
|
||||||
import {add} from "lodash/math";
|
import {add} from "lodash/math";
|
||||||
import api from "js-cookie";
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Apimanage",
|
name: "Apimanage",
|
||||||
|
@ -209,13 +189,6 @@ export default {
|
||||||
//这里存放数据"
|
//这里存放数据"
|
||||||
return {
|
return {
|
||||||
tableData:[],
|
tableData:[],
|
||||||
moneyData:[],
|
|
||||||
money:{
|
|
||||||
timemoney:'',
|
|
||||||
daymoney:'',
|
|
||||||
monthmoney:'',
|
|
||||||
yearmoney:''
|
|
||||||
},
|
|
||||||
ruleForm:{
|
ruleForm:{
|
||||||
pageNum:1,
|
pageNum:1,
|
||||||
pageSize:9,
|
pageSize:9,
|
||||||
|
@ -280,21 +253,7 @@ export default {
|
||||||
},
|
},
|
||||||
//修改
|
//修改
|
||||||
handleEdit(row){
|
handleEdit(row){
|
||||||
//查询中间表,获取不同规格对应的价格
|
|
||||||
getprice(row.productId).then(response=>{
|
|
||||||
this.moneyData=response.data
|
|
||||||
this.money.timemoney=this.moneyData[0].middlePrice
|
|
||||||
this.money.daymoney=this.moneyData[1].middlePrice
|
|
||||||
this.money.monthmoney=this.moneyData[2].middlePrice
|
|
||||||
this.money.yearmoney=this.moneyData[3].middlePrice
|
|
||||||
row.timemoney = this.money.timemoney;
|
|
||||||
row.daymoney = this.money.daymoney;
|
|
||||||
row.monthmoney = this.money.monthmoney;
|
|
||||||
row.yearmoney = this.money.yearmoney;
|
|
||||||
this.$router.push({path:"/apiupdmessage/index",query:{api:row}})
|
this.$router.push({path:"/apiupdmessage/index",query:{api:row}})
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
//删除
|
//删除
|
||||||
handleDelete(row){
|
handleDelete(row){
|
||||||
|
|
|
@ -20,6 +20,9 @@
|
||||||
<el-form-item label="接口销量" prop="productSales" style="width: 70%">
|
<el-form-item label="接口销量" prop="productSales" style="width: 70%">
|
||||||
<el-input type="text" v-model="api.productSales" autocomplete="off"></el-input>
|
<el-input type="text" v-model="api.productSales" autocomplete="off"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="接口价格" prop="productPrice" style="width: 70%">
|
||||||
|
<el-input type="text" v-model="api.productPrice" autocomplete="off"></el-input>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="接口来源" prop="productFrom" style="width: 70%">
|
<el-form-item label="接口来源" prop="productFrom" style="width: 70%">
|
||||||
<el-input type="text" v-model="api.productFrom" autocomplete="off"></el-input>
|
<el-input type="text" v-model="api.productFrom" autocomplete="off"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -35,28 +38,6 @@
|
||||||
<el-form-item label="请求方式" prop="requestMethod" style="width: 70%">
|
<el-form-item label="请求方式" prop="requestMethod" style="width: 70%">
|
||||||
<el-input type="text" v-model="api.requestMethod" autocomplete="off"></el-input>
|
<el-input type="text" v-model="api.requestMethod" autocomplete="off"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="选择默认规格" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-select v-model="api.productSpecification" placeholder="请选择默认规格">
|
|
||||||
<el-option label="按次查询" value="按次查询"></el-option>
|
|
||||||
<el-option label="包日" value="包日"></el-option>
|
|
||||||
<el-option label="包月" value="包月"></el-option>
|
|
||||||
<el-option label="包年" value="包年"></el-option>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-divider></el-divider>
|
|
||||||
<span>价格</span>
|
|
||||||
<el-form-item label="按次查询" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.timemoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="包日" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.daymoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="包月" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.monthmoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="包年" prop="requestMethod" style="width: 70%">
|
|
||||||
<el-input type="text" v-model="api.yearmoney" autocomplete="off"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="submitForm(api)">修改</el-button>
|
<el-button type="primary" @click="submitForm(api)">修改</el-button>
|
||||||
<el-button @click="resetForm('ruleForm')">重置</el-button>
|
<el-button @click="resetForm('ruleForm')">重置</el-button>
|
||||||
|
|
|
@ -8,18 +8,19 @@
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="20"><div class="grid-content bg-purple">
|
<el-col :span="20"><div class="grid-content bg-purple">
|
||||||
<el-form :model="ruleForm" status-icon :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
|
<el-form :model="ruleForm" status-icon :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
|
||||||
<!-- <el-select v-model="ruleForm.productState" placeholder="请选择状态">-->
|
<el-select v-model="ruleForm.productState" placeholder="请选择状态">
|
||||||
<!-- <el-option-->
|
<el-option
|
||||||
<!-- v-for="item in options"-->
|
v-for="item in options"
|
||||||
<!-- :key="item.value"-->
|
:key="item.value"
|
||||||
<!-- :label="item.label"-->
|
:label="item.label"
|
||||||
<!-- :value="item.value">-->
|
:value="item.value">
|
||||||
<!-- </el-option>-->
|
</el-option>
|
||||||
<!-- </el-select>-->
|
</el-select>
|
||||||
<el-input type="text" v-model="ruleForm.productName" style="width: 200px" autocomplete="off" placeholder="名称搜索"></el-input>
|
<el-input type="text" v-model="ruleForm.productName" style="width: 200px" autocomplete="off" placeholder="名称搜索"></el-input>
|
||||||
<el-button type="primary" @click="submitForm('ruleForm')">提交</el-button>
|
<el-button type="primary" @click="submitForm('ruleForm')">提交</el-button>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div></el-col>
|
</div></el-col>
|
||||||
|
<el-col :span="4"><div class="grid-content bg-purple-light"><el-button type="primary">新增数据</el-button></div></el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
|
||||||
<el-row :gutter="12">
|
<el-row :gutter="12">
|
||||||
|
@ -38,7 +39,7 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="6"><div class="grid-content bg-purple">
|
<el-col :span="6"><div class="grid-content bg-purple">
|
||||||
<el-button type="success" @click="test(myapi)">使用</el-button>
|
<el-button type="info" @click="test(myapi)">测试</el-button>
|
||||||
</div></el-col>
|
</div></el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-form>
|
</el-form>
|
||||||
|
|
|
@ -73,13 +73,14 @@
|
||||||
//例如:import 《组件名称》 from '《组件路径》,
|
//例如:import 《组件名称》 from '《组件路径》,
|
||||||
|
|
||||||
|
|
||||||
import {ifbuy, selectList, selectTypeList} from "@/api/market/product";
|
import {selectList, selectTypeList} from "@/api/market/product";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Product',
|
name: 'Product',
|
||||||
//import引入的组件需要注入到对象中才能使用"
|
//import引入的组件需要注入到对象中才能使用"
|
||||||
components: {},
|
components: {},
|
||||||
props: {},
|
props: {},
|
||||||
|
|
||||||
data() {
|
data() {
|
||||||
//这里存放数据"
|
//这里存放数据"
|
||||||
return {
|
return {
|
||||||
|
@ -131,12 +132,6 @@ export default {
|
||||||
},
|
},
|
||||||
//接口测试页面
|
//接口测试页面
|
||||||
test(product){
|
test(product){
|
||||||
//判断是否已购买
|
|
||||||
ifbuy(product).then(response=>{
|
|
||||||
if (response.code!=200) {
|
|
||||||
alert(response.msg)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
this.$router.push({path:"/apitest/index",query:{myapi:JSON.stringify(product)}})
|
this.$router.push({path:"/apitest/index",query:{myapi:JSON.stringify(product)}})
|
||||||
},
|
},
|
||||||
// test(product) {
|
// test(product) {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<h1>资产展示</h1>
|
<h1>测试4()- 资产展示</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.name }}
|
{{ tableBasic.tableName }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">表备注</template>
|
<template slot="label">表备注</template>
|
||||||
|
@ -34,11 +34,11 @@
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">数据量</template>
|
<template slot="label">数据量</template>
|
||||||
{{ dataNum }}
|
{{ tableBasic.dataNum }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item>
|
<el-descriptions-item>
|
||||||
<template slot="label">是否核心</template>
|
<template slot="label">是否核心</template>
|
||||||
<el-tag size="small" v-if="dataNum!=0">是</el-tag>
|
<dict-tag :options="dict.type.sys_no" :value="tableBasic.isCenter"/>
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
</template>
|
</template>
|
||||||
|
@ -51,13 +51,13 @@
|
||||||
</div>
|
</div>
|
||||||
<el-row :gutter="20">
|
<el-row :gutter="20">
|
||||||
<!-- -->
|
<!-- -->
|
||||||
<el-col :span="6" v-for="DataValue in tableStructure" style="margin-top: 20px">
|
<el-col :span="6" v-for="DataValue in assetShowList" style="margin-top: 20px">
|
||||||
<el-descriptions :title="测试+'.'+tableBasic.name+'.'+DataValue.field" direction="vertical"
|
<el-descriptions :title="tableBasic.tableRemark+'.'+tableBasic.tableName+'.'+DataValue.key" direction="vertical"
|
||||||
border :column="1">
|
border :column="1">
|
||||||
<el-descriptions-item label="Type">
|
<el-descriptions-item label="Type">
|
||||||
<el-tag size="small">{{ DataValue.dataMapping}}</el-tag>
|
<el-tag size="small">{{ DataValue.type }}</el-tag>
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label="Value">{{ DataValue.dataValue }}</el-descriptions-item>
|
<el-descriptions-item label="Value">{{ DataValue.value }}</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
|
|
||||||
|
|
||||||
|
@ -65,15 +65,15 @@
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-table
|
<el-table
|
||||||
:data="tableStructure"
|
:data="DataValue"
|
||||||
style="width: 100%">
|
style="width: 100%">
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="field"
|
prop="key"
|
||||||
label="key"
|
label="key"
|
||||||
width="180">
|
width="180">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="annotation"
|
prop="label"
|
||||||
label="label"
|
label="label"
|
||||||
width="180">
|
width="180">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -82,10 +82,11 @@
|
||||||
label="type">
|
label="type">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
prop="dataValue"
|
prop="value"
|
||||||
label="value">
|
label="value">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
|
|
||||||
|
@ -111,10 +112,10 @@ export default {
|
||||||
return {
|
return {
|
||||||
data:[],
|
data:[],
|
||||||
defaultProps: {
|
defaultProps: {
|
||||||
children: 'tableNames',
|
children: 'children',
|
||||||
label: 'name'
|
label: 'tableName'
|
||||||
},
|
},
|
||||||
tableBasic:[],
|
tableBasic:{},
|
||||||
tableStructure:[],
|
tableStructure:[],
|
||||||
assetShowList: [
|
assetShowList: [
|
||||||
// {key: "测试.sys_user.id", type: "String", value: 1},
|
// {key: "测试.sys_user.id", type: "String", value: 1},
|
||||||
|
@ -123,8 +124,9 @@ 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概念",
|
||||||
|
@ -141,12 +143,23 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
handleNodeClick(data){
|
handleNodeClick(data){
|
||||||
|
console.log("...."+data)
|
||||||
this.tableBasic=data
|
this.tableBasic=data
|
||||||
console.log(this.tableBasic)
|
|
||||||
this.dataNum=data.tableFie.length
|
// findStructureByTableId(data.id).then((res)=>{
|
||||||
this.tableStructure=data.tableFie
|
// this.tableStructure=res.data
|
||||||
console.log(this.tableStructure)
|
// })
|
||||||
},
|
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() {
|
||||||
|
|
|
@ -62,7 +62,7 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="类型" prop="type"></el-table-column>
|
<el-table-column label="类型" prop="type"></el-table-column>
|
||||||
<el-table-column label="映射类型" prop="dataMapping"></el-table-column>
|
<el-table-column label="映射类型" prop="types"></el-table-column>
|
||||||
<el-table-column label="是否为空" prop="nullable"></el-table-column>
|
<el-table-column label="是否为空" prop="nullable"></el-table-column>
|
||||||
<el-table-column label="是否字典" prop="isDictionary"></el-table-column>
|
<el-table-column label="是否字典" prop="isDictionary"></el-table-column>
|
||||||
<el-table-column label="映射字典" prop="dictionaryTable"></el-table-column>
|
<el-table-column label="映射字典" prop="dictionaryTable"></el-table-column>
|
||||||
|
@ -87,7 +87,7 @@
|
||||||
//这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等),
|
//这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等),
|
||||||
//例如:import 《组件名称》 from '《组件路径》,
|
//例如:import 《组件名称》 from '《组件路径》,
|
||||||
|
|
||||||
import { getExtractDataTableNameList } from '@/api/property/astr'
|
import { findTableValue, getExtractDataTableNameList } from '@/api/property/astr'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
//import引入的组件需要注入到对象中才能使用"
|
//import引入的组件需要注入到对象中才能使用"
|
||||||
|
@ -124,10 +124,34 @@ export default {
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleNodeClick(data){
|
handleNodeClick(data){
|
||||||
|
// console.log(data)
|
||||||
this.tableBasic=data
|
this.tableBasic=data
|
||||||
this.dataNum=data.tableFie.length
|
this.dataNum=data.tableFie.length
|
||||||
this.tableStructure=data.tableFie
|
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
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue