数据资产(完善)
parent
9e1df6e75a
commit
157c051a5e
|
@ -21,7 +21,9 @@
|
|||
<span>查询语句</span>
|
||||
</div>
|
||||
<el-input type="textarea" v-model="source.sql" style="width: 1080px;" :rows="6"></el-input>
|
||||
<el-button style="float: right;margin-top: 20px" @click="dialogTableVisible = true">数据结构</el-button>
|
||||
<el-button style="float: right;margin-top: 20px" @click="sql()">查询</el-button>
|
||||
|
||||
</el-card>
|
||||
<br>
|
||||
<el-card>
|
||||
|
@ -40,6 +42,20 @@
|
|||
</el-main>
|
||||
</el-container>
|
||||
</el-container>
|
||||
|
||||
<el-dialog title="数据结构" :visible.sync="dialogTableVisible">
|
||||
<el-table :data="tableAssets">
|
||||
<el-table-column property="field" label="字段名" width="150"></el-table-column>
|
||||
<el-table-column property="type" label="类型" width="150"></el-table-column>
|
||||
<el-table-column property="null" label="是否为空" width="150"></el-table-column>
|
||||
<el-table-column property="key" label="键" width="150"></el-table-column>
|
||||
<el-table-column property="default" label="默认值" width="150"></el-table-column>
|
||||
</el-table>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogTableVisible = false">取 消</el-button>
|
||||
<el-button type="primary" @click="dialogTableVisible = false">确 定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
@ -54,6 +70,7 @@ export default {
|
|||
props: {},
|
||||
data() {
|
||||
return {
|
||||
dialogTableVisible: false,
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
|
@ -66,6 +83,7 @@ export default {
|
|||
sourceList: [],
|
||||
assetsList:[],
|
||||
structureList:[],
|
||||
tableAssets:[],
|
||||
source: {
|
||||
sql: ''
|
||||
}
|
||||
|
@ -79,7 +97,6 @@ export default {
|
|||
methods: {
|
||||
sql(){
|
||||
structureList(this.source).then(res => {
|
||||
console.log(res)
|
||||
this.structureList = res.data.kvtList
|
||||
})
|
||||
},
|
||||
|
@ -92,6 +109,7 @@ export default {
|
|||
assetsList(source).then(res => {
|
||||
console.log(res)
|
||||
this.assetsList = res.data.structure
|
||||
this.tableAssets = res.data.tableAssets
|
||||
})
|
||||
},
|
||||
getList() {
|
||||
|
|
Loading…
Reference in New Issue