Browse Source

调整数据表显示

zhangweixin 4 years ago
parent
commit
b9f9c27475

+ 0 - 66
docs/.vuepress/components/GitCode.vue

@@ -1,66 +0,0 @@
-<template>
-    <details class="custom-block details custom-code">
-        <summary>查看代码:{{ fileUrl }}</summary>
-        <pre class="line-numbers">
-    <code class="language-typescript" v-html="code"></code>
-        </pre>
-    </details>
-</template>
-
-<script>
-    import axios from "axios"
-    export default {
-        name: "GitCode",
-        props:{
-            project: {
-                type: String,
-                default: '/web/persagy-web'
-            },
-            raw: {
-                type: String,
-                default: '/raw/master'
-            },
-            fileUrl: {
-                type: String,
-                default: '/persagy-web-big/src/items/SIconTextItem.ts'
-            },
-            type: {
-                type: String,
-                default: 'typescript'
-            }
-        },
-        data(){
-            return{
-                baseUrl: '/git',
-                code:''
-            }
-        },
-        created() {
-            this.init()
-        },
-        computed:{
-          requestUrl(){
-              return this.baseUrl + this.project + this.raw + this.fileUrl;
-          }
-        },
-        methods: {
-            init(){
-                axios({
-                    method: "get",
-                    url: this.requestUrl
-                }).then(res => {
-                    this.code = res.data;
-                    this.$nextTick(()=>{
-                        document.querySelectorAll("pre code").forEach(block => {
-                            Prism.highlightElement(block)
-                        });
-                    });
-                })
-            }
-        }
-    }
-</script>
-
-<style scoped>
-
-</style>

+ 2 - 2
docs/.vuepress/components/TableDesig.vue

@@ -3,7 +3,7 @@
     <el-button style="margin-top:10px" @click="genEntrty">生成实体类</el-button>
     <el-button style="margin-top:10px" @click="genControler">生成接口类</el-button>
     <el-table
-      :data="tableData"
+      :data="tableData.ColumnList"
       :header-cell-style="headerStyle"
       border
       stripe
@@ -52,7 +52,7 @@ export default {
   methods: {
     getData() {
       Axios.get(
-        `${Opt.databaseDoc[this.sys]}/--database-doc--/column-list?schema=${
+        `${window.location.origin}/${this.sys}/--database-doc--/table-info?schema=${
           this.schema
         }&table=${this.table}`,
         {}

+ 10 - 2
docs/.vuepress/config.js

@@ -145,16 +145,24 @@ module.exports = {
     },
     devServer :{
         proxy: {
-            '/git': {
+            '/gogs': {
                 target: 'http://39.106.8.246:3003',
                 changeOrigin: true,
                 secure: false,
                 pathRewrite: {
-                    '^/git': '',
+                    '^/gogs': '',
                 },
                 bypass: function(req, res, proxyOptions) {
                     req.headers["Authorization"] = "Basic bGJzbDoyMDIwMDgyOQ=="
                 }
+            },
+            '/datacenter': {
+                target: 'http://localhost:8080/',
+                changeOrigin: true,
+                secure: false,
+                pathRewrite: {
+                    '^/datacenter': '',
+                }
             }
         }
     }

+ 3 - 0
docs/.vuepress/enhanceApp.js

@@ -2,8 +2,11 @@
 // 全局注册 Element 组件库
 
 import Vue from 'vue'
+import SDoc from 'sybotan-vue-doc'
 import Element from 'element-ui'
 import 'element-ui/lib/theme-chalk/index.css'
 import './public/plugin/prism.css'
 import './public/plugin/prism'
+
+Vue.use(SDoc);
 Vue.use(Element);

+ 2 - 0
docs/dev/lib/coding/README.md

@@ -42,6 +42,8 @@
 <<< @/docs/dev/lib/coding/src/PropertyController.kt
 :::
 
+<SCodeGit repos="server/data-center" src="/datacenter/src/main/kotlin/cn/sagacloud/server/datacenter/controllers/PropertyController.kt"/>
+
 标准的通用接口,增删改查统计
 
 ### 控制类注解说明 

+ 1 - 0
package.json

@@ -15,6 +15,7 @@
     "@persagy-web/base": "2.2.1",
     "axios": "^0.18.1",
     "element-ui": "^2.12.0",
+    "sybotan-vue-doc": "^1.1.20",
     "vue": "^2.6.10",
     "vue-property-decorator": "^8.4.2"
   },