mirror of
				https://gitee.com/dromara/mayfly-go
				synced 2025-11-04 08:20:25 +08:00 
			
		
		
		
	fix: 问题修复
This commit is contained in:
		@@ -10,12 +10,12 @@
 | 
			
		||||
  },
 | 
			
		||||
  "dependencies": {
 | 
			
		||||
    "@element-plus/icons-vue": "^2.0.10",
 | 
			
		||||
    "asciinema-player": "^3.0.1",
 | 
			
		||||
    "asciinema-player": "^3.1.0",
 | 
			
		||||
    "axios": "^1.3.2",
 | 
			
		||||
    "countup.js": "^2.0.7",
 | 
			
		||||
    "cropperjs": "^1.5.11",
 | 
			
		||||
    "echarts": "^5.4.0",
 | 
			
		||||
    "element-plus": "^2.2.30",
 | 
			
		||||
    "element-plus": "^2.2.32",
 | 
			
		||||
    "jsencrypt": "^3.2.1",
 | 
			
		||||
    "lodash": "^4.17.21",
 | 
			
		||||
    "mitt": "^3.0.0",
 | 
			
		||||
@@ -25,7 +25,7 @@
 | 
			
		||||
    "nprogress": "^0.2.0",
 | 
			
		||||
    "screenfull": "^6.0.2",
 | 
			
		||||
    "sortablejs": "^1.13.0",
 | 
			
		||||
    "sql-formatter": "^9.2.0",
 | 
			
		||||
    "sql-formatter": "^12.1.2",
 | 
			
		||||
    "vue": "^3.2.47",
 | 
			
		||||
    "vue-clipboard3": "^1.0.1",
 | 
			
		||||
    "vue-router": "^4.1.6",
 | 
			
		||||
 
 | 
			
		||||
@@ -5,9 +5,6 @@ import themeConfig from '@/store/modules/themeConfig.ts';
 | 
			
		||||
import routesList from '@/store/modules/routesList.ts';
 | 
			
		||||
import keepAliveNames from '@/store/modules/keepAliveNames.ts';
 | 
			
		||||
import userInfos from '@/store/modules/userInfos.ts';
 | 
			
		||||
import sqlExecInfo from '@/store/modules/mysqlDbOptInfo.ts';
 | 
			
		||||
import redisDbOptInfo  from '@/store/modules/redisDbOptInfo.ts';
 | 
			
		||||
import mongoDbOptInfo from '@/store/modules/mongoDbOptInfo.ts';
 | 
			
		||||
 | 
			
		||||
export const key: InjectionKey<Store<RootStateTypes>> = Symbol();
 | 
			
		||||
 | 
			
		||||
@@ -17,9 +14,6 @@ export const store = createStore<RootStateTypes>({
 | 
			
		||||
        routesList,
 | 
			
		||||
        keepAliveNames,
 | 
			
		||||
        userInfos,
 | 
			
		||||
        sqlExecInfo,
 | 
			
		||||
        redisDbOptInfo,
 | 
			
		||||
        mongoDbOptInfo,
 | 
			
		||||
    },
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -72,14 +72,6 @@ export interface UserInfosState {
 | 
			
		||||
    userInfos: object;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// 数据操作信息
 | 
			
		||||
export interface DbOptInfoState {
 | 
			
		||||
    dbOptInfo: {
 | 
			
		||||
        tagPath?: string,
 | 
			
		||||
        dbId?: number,
 | 
			
		||||
        db?: string,
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// 后端返回原始路由(未处理时)
 | 
			
		||||
// export interface RequestOldRoutesState {
 | 
			
		||||
@@ -92,8 +84,5 @@ export interface RootStateTypes {
 | 
			
		||||
    routesList: RoutesListState;
 | 
			
		||||
    keepAliveNames: KeepAliveNamesState;
 | 
			
		||||
    userInfos: UserInfosState;
 | 
			
		||||
    sqlExecInfo: DbOptInfoState;
 | 
			
		||||
    redisDbOptInfo: DbOptInfoState;
 | 
			
		||||
    mongoDbOptInfo: DbOptInfoState;
 | 
			
		||||
    // requestOldRoutes: RequestOldRoutesState;
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -1,30 +0,0 @@
 | 
			
		||||
import { Module } from 'vuex';
 | 
			
		||||
// 此处加上 `.ts` 后缀报错,具体原因不详
 | 
			
		||||
import {DbOptInfoState, RootStateTypes} from '@/store/interface';
 | 
			
		||||
 | 
			
		||||
const mongoDbOptInfoModule: Module<DbOptInfoState, RootStateTypes> = {
 | 
			
		||||
    namespaced: true,
 | 
			
		||||
    state: {
 | 
			
		||||
        dbOptInfo: {
 | 
			
		||||
            tagPath: '',
 | 
			
		||||
            dbId: 0,
 | 
			
		||||
            db: '0',
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
    mutations: {
 | 
			
		||||
        // 设置用户信息
 | 
			
		||||
        getMongoDbOptInfo(state: any, data: object) {
 | 
			
		||||
            state.dbOptInfo = data;
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
    actions: {
 | 
			
		||||
        // 设置用户信息
 | 
			
		||||
        async setMongoDbOptInfo({ commit }, data: object) {
 | 
			
		||||
            if (data) {
 | 
			
		||||
                commit('getMongoDbOptInfo', data);
 | 
			
		||||
            }
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
export default mongoDbOptInfoModule;
 | 
			
		||||
@@ -1,30 +0,0 @@
 | 
			
		||||
import { Module } from 'vuex';
 | 
			
		||||
// 此处加上 `.ts` 后缀报错,具体原因不详
 | 
			
		||||
import { DbOptInfoState, RootStateTypes } from '@/store/interface';
 | 
			
		||||
 | 
			
		||||
const sqlExecInfoModule: Module<DbOptInfoState, RootStateTypes> = {
 | 
			
		||||
    namespaced: true,
 | 
			
		||||
    state: {
 | 
			
		||||
        dbOptInfo: {
 | 
			
		||||
            tagPath: '',
 | 
			
		||||
            dbId: 0,
 | 
			
		||||
            db: '0',
 | 
			
		||||
        }
 | 
			
		||||
    },
 | 
			
		||||
    mutations: {
 | 
			
		||||
        // 设置用户信息
 | 
			
		||||
        getSqlExecInfo(state: any, data: object) {
 | 
			
		||||
            state.dbOptInfo = data;
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
    actions: {
 | 
			
		||||
        // 设置用户信息
 | 
			
		||||
        async setSqlExecInfo({ commit }, data: object) {
 | 
			
		||||
            if (data) {
 | 
			
		||||
                commit('getSqlExecInfo', data);
 | 
			
		||||
            }
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
export default sqlExecInfoModule;
 | 
			
		||||
@@ -1,30 +0,0 @@
 | 
			
		||||
import { Module } from 'vuex';
 | 
			
		||||
// 此处加上 `.ts` 后缀报错,具体原因不详
 | 
			
		||||
import {DbOptInfoState, RootStateTypes} from '@/store/interface';
 | 
			
		||||
 | 
			
		||||
const redisDbOptInfoModule: Module<DbOptInfoState, RootStateTypes> = {
 | 
			
		||||
    namespaced: true,
 | 
			
		||||
    state: {
 | 
			
		||||
        dbOptInfo: {
 | 
			
		||||
            tagPath: '',
 | 
			
		||||
            dbId: 0,
 | 
			
		||||
            db: '0',
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
    mutations: {
 | 
			
		||||
        // 设置用户信息
 | 
			
		||||
        getRedisDbOptInfo(state: any, data: object) {
 | 
			
		||||
            state.dbOptInfo = data;
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
    actions: {
 | 
			
		||||
        // 设置用户信息
 | 
			
		||||
        async setRedisDbOptInfo({ commit }, data: object) {
 | 
			
		||||
            if (data) {
 | 
			
		||||
                commit('getRedisDbOptInfo', data);
 | 
			
		||||
            }
 | 
			
		||||
        },
 | 
			
		||||
    },
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
export default redisDbOptInfoModule;
 | 
			
		||||
@@ -107,11 +107,11 @@ const themeConfigModule: Module<ThemeConfigState, RootStateTypes> = {
 | 
			
		||||
            layout: 'classic',
 | 
			
		||||
 | 
			
		||||
            // ssh终端字体颜色
 | 
			
		||||
            terminalForeground: '#50583E',
 | 
			
		||||
            terminalForeground: '#C5C8C6',
 | 
			
		||||
            // ssh终端背景色
 | 
			
		||||
            terminalBackground: '#FFFFDD',
 | 
			
		||||
            terminalBackground: '#121212',
 | 
			
		||||
            // ssh终端cursor色
 | 
			
		||||
            terminalCursor: '#979b7c',
 | 
			
		||||
            terminalCursor: '#F0CC09',
 | 
			
		||||
            terminalFontSize: 14,
 | 
			
		||||
            terminalFontWeight: 'bold',
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -24,10 +24,10 @@
 | 
			
		||||
                </div> -->
 | 
			
		||||
            </div>
 | 
			
		||||
        </div>
 | 
			
		||||
        <div class="login-copyright">
 | 
			
		||||
        <!-- <div class="login-copyright">
 | 
			
		||||
            <div class="mb5 login-copyright-company">mayfly</div>
 | 
			
		||||
            <div class="login-copyright-msg">mayfly</div>
 | 
			
		||||
        </div>
 | 
			
		||||
        </div> -->
 | 
			
		||||
    </div>
 | 
			
		||||
</template>
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,7 +1,7 @@
 | 
			
		||||
<template>
 | 
			
		||||
    <div
 | 
			
		||||
        style="display: inline-flex;  justify-content: center;  align-items: center; cursor: pointer;vertical-align: middle;">
 | 
			
		||||
        <el-popover @show="showTagInfo" placement="right-end" title="标签信息" :width="300" trigger="hover">
 | 
			
		||||
        <el-popover @show="showTagInfo" placement="top-start" title="标签信息" :width="300" trigger="hover">
 | 
			
		||||
            <template #reference>
 | 
			
		||||
                <el-icon>
 | 
			
		||||
                    <InfoFilled />
 | 
			
		||||
 
 | 
			
		||||
@@ -6,7 +6,7 @@
 | 
			
		||||
 | 
			
		||||
                <el-tree ref="treeRef" :style="{ maxHeight: state.height, height: state.height, overflow: 'auto' }"
 | 
			
		||||
                    :highlight-current="true" :indent="7" :load="loadNode" :props="treeProps" lazy node-key="key"
 | 
			
		||||
                    :expand-on-click-node="true" :filter-node-method="filterNode" @node-click="treeNodeClick">
 | 
			
		||||
                    :expand-on-click-node="true" :filter-node-method="filterNode" @node-click="treeNodeClick" @node-expand="treeNodeClick">
 | 
			
		||||
                    <template #default="{ node, data }">
 | 
			
		||||
                        <span class="icon-middle ">
 | 
			
		||||
                            <span v-if="data.type == TagTreeNode.TagPath">
 | 
			
		||||
 
 | 
			
		||||
@@ -568,10 +568,10 @@ array-union@^2.1.0:
 | 
			
		||||
  resolved "https://registry.npm.taobao.org/array-union/download/array-union-2.1.0.tgz?cache=0&sync_timestamp=1614624262896&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Farray-union%2Fdownload%2Farray-union-2.1.0.tgz"
 | 
			
		||||
  integrity sha1-t5hCCtvrHego2ErNii4j0+/oXo0=
 | 
			
		||||
 | 
			
		||||
asciinema-player@^3.0.1:
 | 
			
		||||
  version "3.0.1"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/asciinema-player/-/asciinema-player-3.0.1.tgz"
 | 
			
		||||
  integrity sha512-plm/C/MhOtZWysrfcT/rzxOuu8vxvvDSvF50pqZS6KpJUDmATedAhO54zktbE/g7RiaaYfzgX8xjRhlQdgISwA==
 | 
			
		||||
asciinema-player@^3.1.0:
 | 
			
		||||
  version "3.1.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/asciinema-player/-/asciinema-player-3.1.0.tgz#64a315e75cb55c61f69e4be91ad0f4ffe0504979"
 | 
			
		||||
  integrity sha512-O36+vQOreHW2w9Sao7AbHY4o3RJW7AxtVGtQdb74QkKZmaY8VzQJ3u36PTzltqlybJIpwXY9yK/PdVVmgmTEpg==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/runtime" "^7.15.4"
 | 
			
		||||
    solid-js "^1.3.0"
 | 
			
		||||
@@ -676,6 +676,11 @@ combined-stream@^1.0.8:
 | 
			
		||||
  dependencies:
 | 
			
		||||
    delayed-stream "~1.0.0"
 | 
			
		||||
 | 
			
		||||
commander@^2.19.0:
 | 
			
		||||
  version "2.20.3"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33"
 | 
			
		||||
  integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==
 | 
			
		||||
 | 
			
		||||
concat-map@0.0.1:
 | 
			
		||||
  version "0.0.1"
 | 
			
		||||
  resolved "https://registry.npm.taobao.org/concat-map/download/concat-map-0.0.1.tgz"
 | 
			
		||||
@@ -744,6 +749,11 @@ dir-glob@^3.0.1:
 | 
			
		||||
  dependencies:
 | 
			
		||||
    path-type "^4.0.0"
 | 
			
		||||
 | 
			
		||||
discontinuous-range@1.0.0:
 | 
			
		||||
  version "1.0.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/discontinuous-range/-/discontinuous-range-1.0.0.tgz#e38331f0844bba49b9a9cb71c771585aab1bc65a"
 | 
			
		||||
  integrity sha512-c68LpLbO+7kP/b1Hr1qs8/BJ09F5khZGTxqxZuhzxpmwJKOgRFHJWIb9/KmqnqHhLdO55aOxFH/EGBvUQbL/RQ==
 | 
			
		||||
 | 
			
		||||
doctrine@^3.0.0:
 | 
			
		||||
  version "3.0.0"
 | 
			
		||||
  resolved "https://registry.nlark.com/doctrine/download/doctrine-3.0.0.tgz"
 | 
			
		||||
@@ -772,10 +782,10 @@ echarts@^5.4.0:
 | 
			
		||||
    tslib "2.3.0"
 | 
			
		||||
    zrender "5.4.0"
 | 
			
		||||
 | 
			
		||||
element-plus@^2.2.30:
 | 
			
		||||
  version "2.2.30"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/element-plus/-/element-plus-2.2.30.tgz#b594efcbd6969f3f88130aa1edf50c98139d6e73"
 | 
			
		||||
  integrity sha512-HYSnmf2VMGa0gmw03evxevodPy3WimbAd4sfenOAhNs7Wl8IdT+YJjQyGAQjgEjRvhmujN4O/CZqhuEffRyOZg==
 | 
			
		||||
element-plus@^2.2.32:
 | 
			
		||||
  version "2.2.32"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/element-plus/-/element-plus-2.2.32.tgz#e7e6757a66ed158363a86b5c9fc10dfbc0096783"
 | 
			
		||||
  integrity sha512-DTJMhYOy6MApbmh6z/95hPTK5WrBiNHGzV4IN+uEkup1WoimQ+Qyt8RxKdTe/X1LWEJ8YgWv/Cl8P4ocrt5z5g==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@ctrl/tinycolor" "^3.4.1"
 | 
			
		||||
    "@element-plus/icons-vue" "^2.0.6"
 | 
			
		||||
@@ -1346,6 +1356,11 @@ monaco-themes@^0.4.2:
 | 
			
		||||
  dependencies:
 | 
			
		||||
    fast-plist "^0.1.2"
 | 
			
		||||
 | 
			
		||||
moo@^0.5.0:
 | 
			
		||||
  version "0.5.2"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/moo/-/moo-0.5.2.tgz#f9fe82473bc7c184b0d32e2215d3f6e67278733c"
 | 
			
		||||
  integrity sha512-iSAJLHYKnX41mKcJKjqvnAN9sf0LMDTXDEvFv+ffuRR9a1MIuXLjMNL6EsnDHSkKLTWNqQQ5uo61P4EbU4NU+Q==
 | 
			
		||||
 | 
			
		||||
ms@2.1.2:
 | 
			
		||||
  version "2.1.2"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/ms/download/ms-2.1.2.tgz"
 | 
			
		||||
@@ -1366,6 +1381,16 @@ natural-compare@^1.4.0:
 | 
			
		||||
  resolved "https://registry.npm.taobao.org/natural-compare/download/natural-compare-1.4.0.tgz"
 | 
			
		||||
  integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=
 | 
			
		||||
 | 
			
		||||
nearley@^2.20.1:
 | 
			
		||||
  version "2.20.1"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/nearley/-/nearley-2.20.1.tgz#246cd33eff0d012faf197ff6774d7ac78acdd474"
 | 
			
		||||
  integrity sha512-+Mc8UaAebFzgV+KpI5n7DasuuQCHA89dmwm7JXw3TV43ukfNQ9DnBH3Mdb2g/I4Fdxc26pwimBWvjIw0UAILSQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    commander "^2.19.0"
 | 
			
		||||
    moo "^0.5.0"
 | 
			
		||||
    railroad-diagrams "^1.0.0"
 | 
			
		||||
    randexp "0.4.6"
 | 
			
		||||
 | 
			
		||||
neo-async@^2.6.2:
 | 
			
		||||
  version "2.6.2"
 | 
			
		||||
  resolved "https://registry.npm.taobao.org/neo-async/download/neo-async-2.6.2.tgz"
 | 
			
		||||
@@ -1490,6 +1515,19 @@ queue-microtask@^1.2.2:
 | 
			
		||||
  resolved "https://registry.nlark.com/queue-microtask/download/queue-microtask-1.2.3.tgz"
 | 
			
		||||
  integrity sha1-SSkii7xyTfrEPg77BYyve2z7YkM=
 | 
			
		||||
 | 
			
		||||
railroad-diagrams@^1.0.0:
 | 
			
		||||
  version "1.0.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/railroad-diagrams/-/railroad-diagrams-1.0.0.tgz#eb7e6267548ddedfb899c1b90e57374559cddb7e"
 | 
			
		||||
  integrity sha512-cz93DjNeLY0idrCNOH6PviZGRN9GJhsdm9hpn1YCS879fj4W+x5IFJhhkRZcwVgMmFF7R82UA/7Oh+R8lLZg6A==
 | 
			
		||||
 | 
			
		||||
randexp@0.4.6:
 | 
			
		||||
  version "0.4.6"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/randexp/-/randexp-0.4.6.tgz#e986ad5e5e31dae13ddd6f7b3019aa7c87f60ca3"
 | 
			
		||||
  integrity sha512-80WNmd9DA0tmZrw9qQa62GPPWfuXJknrmVmLcxvq4uZBdYqb1wYoKTmnlGUchvVWe0XiLupYkBoXVOxz3C8DYQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    discontinuous-range "1.0.0"
 | 
			
		||||
    ret "~0.1.10"
 | 
			
		||||
 | 
			
		||||
readdirp@~3.6.0:
 | 
			
		||||
  version "3.6.0"
 | 
			
		||||
  resolved "https://registry.npm.taobao.org/readdirp/download/readdirp-3.6.0.tgz"
 | 
			
		||||
@@ -1521,6 +1559,11 @@ resolve@^1.22.1:
 | 
			
		||||
    path-parse "^1.0.7"
 | 
			
		||||
    supports-preserve-symlinks-flag "^1.0.0"
 | 
			
		||||
 | 
			
		||||
ret@~0.1.10:
 | 
			
		||||
  version "0.1.15"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc"
 | 
			
		||||
  integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==
 | 
			
		||||
 | 
			
		||||
reusify@^1.0.4:
 | 
			
		||||
  version "1.0.4"
 | 
			
		||||
  resolved "https://registry.npm.taobao.org/reusify/download/reusify-1.0.4.tgz"
 | 
			
		||||
@@ -1630,12 +1673,13 @@ sourcemap-codec@^1.4.8:
 | 
			
		||||
  resolved "https://registry.npmmirror.com/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz"
 | 
			
		||||
  integrity sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==
 | 
			
		||||
 | 
			
		||||
sql-formatter@^9.2.0:
 | 
			
		||||
  version "9.2.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/sql-formatter/-/sql-formatter-9.2.0.tgz"
 | 
			
		||||
  integrity sha512-Dn4lEpUeAhfNDR2LnEs9Uaq92TSHjhcNrzhllPuMnp188P4sLU7UcdcB9UqIfMfcN62gWXJlJ3KocaAf/SOzXQ==
 | 
			
		||||
sql-formatter@^12.1.2:
 | 
			
		||||
  version "12.1.2"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/sql-formatter/-/sql-formatter-12.1.2.tgz#6dfd042caaa468316123832751a05c77d2d1ef87"
 | 
			
		||||
  integrity sha512-SoFn+9ZflUt8+HYZ/PaifXt1RptcDUn8HXqsWmfXdPV3WeHPgT0qOSJXxHU24d7NOVt9X40MLqf263fNk79XqA==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    argparse "^2.0.1"
 | 
			
		||||
    nearley "^2.20.1"
 | 
			
		||||
 | 
			
		||||
strip-ansi@^6.0.1:
 | 
			
		||||
  version "6.0.1"
 | 
			
		||||
 
 | 
			
		||||
@@ -3,7 +3,7 @@ module mayfly-go
 | 
			
		||||
go 1.20
 | 
			
		||||
 | 
			
		||||
require (
 | 
			
		||||
	github.com/gin-gonic/gin v1.8.2
 | 
			
		||||
	github.com/gin-gonic/gin v1.9.0
 | 
			
		||||
	github.com/go-redis/redis/v8 v8.11.5
 | 
			
		||||
	github.com/go-sql-driver/mysql v1.7.0
 | 
			
		||||
	github.com/golang-jwt/jwt/v4 v4.4.3
 | 
			
		||||
@@ -23,38 +23,42 @@ require (
 | 
			
		||||
)
 | 
			
		||||
 | 
			
		||||
require (
 | 
			
		||||
	github.com/bytedance/sonic v1.8.0 // indirect
 | 
			
		||||
	github.com/cespare/xxhash/v2 v2.1.2 // indirect
 | 
			
		||||
	github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 // indirect
 | 
			
		||||
	github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
 | 
			
		||||
	github.com/gin-contrib/sse v0.1.0 // indirect
 | 
			
		||||
	github.com/go-playground/locales v0.14.0 // indirect
 | 
			
		||||
	github.com/go-playground/universal-translator v0.18.0 // indirect
 | 
			
		||||
	github.com/go-playground/validator/v10 v10.11.1 // indirect
 | 
			
		||||
	github.com/goccy/go-json v0.9.11 // indirect
 | 
			
		||||
	github.com/go-playground/locales v0.14.1 // indirect
 | 
			
		||||
	github.com/go-playground/universal-translator v0.18.1 // indirect
 | 
			
		||||
	github.com/go-playground/validator/v10 v10.11.2 // indirect
 | 
			
		||||
	github.com/goccy/go-json v0.10.0 // indirect
 | 
			
		||||
	github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0 // indirect
 | 
			
		||||
	github.com/golang/snappy v0.0.1 // indirect
 | 
			
		||||
	github.com/jinzhu/inflection v1.0.0 // indirect
 | 
			
		||||
	github.com/jinzhu/now v1.1.5 // indirect
 | 
			
		||||
	github.com/json-iterator/go v1.1.12 // indirect
 | 
			
		||||
	github.com/klauspost/compress v1.13.6 // indirect
 | 
			
		||||
	github.com/klauspost/cpuid/v2 v2.0.9 // indirect
 | 
			
		||||
	github.com/kr/fs v0.1.0 // indirect
 | 
			
		||||
	github.com/leodido/go-urn v1.2.1 // indirect
 | 
			
		||||
	github.com/mattn/go-isatty v0.0.16 // indirect
 | 
			
		||||
	github.com/mattn/go-isatty v0.0.17 // indirect
 | 
			
		||||
	github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
 | 
			
		||||
	github.com/modern-go/reflect2 v1.0.2 // indirect
 | 
			
		||||
	github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe // indirect
 | 
			
		||||
	github.com/pelletier/go-toml/v2 v2.0.6 // indirect
 | 
			
		||||
	github.com/pkg/errors v0.9.1 // indirect
 | 
			
		||||
	github.com/ugorji/go/codec v1.2.7 // indirect
 | 
			
		||||
	github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
 | 
			
		||||
	github.com/ugorji/go/codec v1.2.9 // indirect
 | 
			
		||||
	github.com/xdg-go/pbkdf2 v1.0.0 // indirect
 | 
			
		||||
	github.com/xdg-go/scram v1.1.1 // indirect
 | 
			
		||||
	github.com/xdg-go/stringprep v1.0.3 // indirect
 | 
			
		||||
	github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d // indirect
 | 
			
		||||
	golang.org/x/arch v0.0.0-20210923205945-b76863e36670 // indirect
 | 
			
		||||
	golang.org/x/image v0.0.0-20220302094943-723b81ca9867 // indirect
 | 
			
		||||
	golang.org/x/net v0.6.0 // indirect
 | 
			
		||||
	golang.org/x/net v0.7.0 // indirect
 | 
			
		||||
	golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
 | 
			
		||||
	golang.org/x/sys v0.5.0 // indirect
 | 
			
		||||
	golang.org/x/text v0.7.0 // indirect
 | 
			
		||||
	golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
 | 
			
		||||
	google.golang.org/protobuf v1.28.1 // indirect
 | 
			
		||||
	gopkg.in/yaml.v2 v2.4.0 // indirect
 | 
			
		||||
)
 | 
			
		||||
 
 | 
			
		||||
@@ -30,7 +30,7 @@ type Db struct {
 | 
			
		||||
	TagApp       tagapp.TagTree
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
const DEFAULT_ROW_SIZE = 1800
 | 
			
		||||
const DEFAULT_ROW_SIZE = 5000
 | 
			
		||||
 | 
			
		||||
// @router /api/dbs [get]
 | 
			
		||||
func (d *Db) Dbs(rc *req.Ctx) {
 | 
			
		||||
@@ -186,7 +186,7 @@ func (d *Db) ExecSqlFile(rc *req.Ctx) {
 | 
			
		||||
 | 
			
		||||
	logExecRecord := true
 | 
			
		||||
	// 如果执行sql文件大于该值则不记录sql执行记录
 | 
			
		||||
	if fileheader.Size > 500*1024 {
 | 
			
		||||
	if fileheader.Size > 50*1024 {
 | 
			
		||||
		logExecRecord = false
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -297,9 +297,6 @@ func (d *DbInstance) Close() {
 | 
			
		||||
 | 
			
		||||
//------------------------------------------------------------------------------
 | 
			
		||||
 | 
			
		||||
// 单次最大查询数据集
 | 
			
		||||
const Max_Rows = 2000
 | 
			
		||||
 | 
			
		||||
// 客户端连接缓存,指定时间内没有访问则会被关闭, key为数据库实例id:数据库
 | 
			
		||||
var dbCache = cache.NewTimedCache(constant.DbConnExpireTime, 5*time.Second).
 | 
			
		||||
	WithUpdateAccessTime(true).
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user