|
@@ -11,12 +11,18 @@
|
|
|
width="850px"
|
|
|
>
|
|
|
<a-row :gutter="24">
|
|
|
- <a-col :md="24" :sm="24">
|
|
|
+ <a-col :md="4" :sm="24">
|
|
|
<!-- <div class="copy-btn-box-9136076486841527"> -->
|
|
|
数据库表名:
|
|
|
- <a-input placeholder="请输入表名" style="width:20%;" v-model="businessTable" />
|
|
|
+ <!-- <a-input placeholder="请输入表名" style="width:20%;" v-model="businessTable" /> -->
|
|
|
+
|
|
|
<!-- </div> -->
|
|
|
</a-col>
|
|
|
+ <a-col :md="18" :sm="24">
|
|
|
+ <a-select v-model="businessTable" style="width: 30%" placeholder="请选择数据库表名" allowClear show-search >
|
|
|
+ <a-select-option v-for="(item) in tableList" :key="item.tableName" :value="item.tableName">{{item.tableName}}{{item.tableComment}}</a-select-option>
|
|
|
+ </a-select>
|
|
|
+ </a-col>
|
|
|
</a-row>
|
|
|
<a-row :gutter="24" v-if="dataSource.length>0">
|
|
|
<a-col :md="24" :sm="24">
|
|
@@ -38,7 +44,7 @@
|
|
|
</a-modal>
|
|
|
</template>
|
|
|
<script>
|
|
|
-import { getFormByBusinessTable } from "../../api/api";
|
|
|
+import { getFormByBusinessTable,getTableList } from "../../api/api";
|
|
|
/*
|
|
|
* author kcz
|
|
|
* date 2019-11-20
|
|
@@ -48,6 +54,7 @@ export default {
|
|
|
name: "queryModal",
|
|
|
data() {
|
|
|
return {
|
|
|
+ tableList:[],
|
|
|
dataSource:[],
|
|
|
columns:[
|
|
|
{
|
|
@@ -77,6 +84,14 @@ export default {
|
|
|
formData: {}
|
|
|
};
|
|
|
},
|
|
|
+ created(){
|
|
|
+ //获取数据库表名下拉数据
|
|
|
+ getTableList().then(res=>{
|
|
|
+ if(res.data.success){
|
|
|
+ this.tableList=res.data.result;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
methods: {
|
|
|
handleCancel() {
|
|
|
this.visible = false;
|