mirror of
				https://gitee.com/dromara/mayfly-go
				synced 2025-11-04 08:20:25 +08:00 
			
		
		
		
	feat: 新增系统样式配置,支持改logo图标与标题
This commit is contained in:
		@@ -9,7 +9,7 @@
 | 
			
		||||
    "lint-fix": "eslint --fix --ext .js --ext .jsx --ext .vue src/"
 | 
			
		||||
  },
 | 
			
		||||
  "dependencies": {
 | 
			
		||||
    "@element-plus/icons-vue": "^2.1.0",
 | 
			
		||||
    "@element-plus/icons-vue": "^2.3.1",
 | 
			
		||||
    "@vueuse/core": "^10.7.0",
 | 
			
		||||
    "asciinema-player": "^3.6.3",
 | 
			
		||||
    "axios": "^1.6.2",
 | 
			
		||||
@@ -33,7 +33,7 @@
 | 
			
		||||
    "splitpanes": "^3.1.5",
 | 
			
		||||
    "sql-formatter": "^14.0.0",
 | 
			
		||||
    "uuid": "^9.0.1",
 | 
			
		||||
    "vue": "^3.4.0",
 | 
			
		||||
    "vue": "^3.4.5",
 | 
			
		||||
    "vue-router": "^4.2.5",
 | 
			
		||||
    "xterm": "^5.3.0",
 | 
			
		||||
    "xterm-addon-fit": "^0.8.0",
 | 
			
		||||
@@ -47,8 +47,8 @@
 | 
			
		||||
    "@types/sortablejs": "^1.15.3",
 | 
			
		||||
    "@typescript-eslint/eslint-plugin": "^6.7.4",
 | 
			
		||||
    "@typescript-eslint/parser": "^6.7.4",
 | 
			
		||||
    "@vitejs/plugin-vue": "^4.5.2",
 | 
			
		||||
    "@vue/compiler-sfc": "^3.3.11",
 | 
			
		||||
    "@vitejs/plugin-vue": "^5.0.2",
 | 
			
		||||
    "@vue/compiler-sfc": "^3.4.3",
 | 
			
		||||
    "dotenv": "^16.3.1",
 | 
			
		||||
    "eslint": "^8.35.0",
 | 
			
		||||
    "eslint-plugin-vue": "^9.19.2",
 | 
			
		||||
 
 | 
			
		||||
@@ -22,12 +22,9 @@ import { ref, onMounted, onUnmounted, nextTick, watch } from 'vue';
 | 
			
		||||
import { useRoute } from 'vue-router';
 | 
			
		||||
import { storeToRefs } from 'pinia';
 | 
			
		||||
import { useThemeConfig } from '@/store/themeConfig';
 | 
			
		||||
import { getLocal } from '@/common/utils/storage';
 | 
			
		||||
import LockScreen from '@/layout/lockScreen/index.vue';
 | 
			
		||||
import Setings from '@/layout/navBars/breadcrumb/setings.vue';
 | 
			
		||||
import mittBus from '@/common/utils/mitt';
 | 
			
		||||
import { getThemeConfig } from './common/utils/storage';
 | 
			
		||||
import { useWatermark } from '@/common/sysconfig';
 | 
			
		||||
import { useIntervalFn } from '@vueuse/core';
 | 
			
		||||
 | 
			
		||||
const setingsRef = ref();
 | 
			
		||||
@@ -49,17 +46,8 @@ onMounted(() => {
 | 
			
		||||
            openSetingsDrawer();
 | 
			
		||||
        });
 | 
			
		||||
 | 
			
		||||
        // 获取缓存中的布局配置
 | 
			
		||||
        const tc = getThemeConfig();
 | 
			
		||||
        if (tc) {
 | 
			
		||||
            themeConfigStores.setThemeConfig({ themeConfig: tc });
 | 
			
		||||
            document.documentElement.style.cssText = getLocal('themeConfigStyle');
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        // 是否开启水印
 | 
			
		||||
        useWatermark().then((res) => {
 | 
			
		||||
            themeConfigStores.setWatermarkConfig(res);
 | 
			
		||||
        });
 | 
			
		||||
        // 初始化系统主题
 | 
			
		||||
        themeConfigStores.initThemeConfig();
 | 
			
		||||
    });
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,5 +1,5 @@
 | 
			
		||||
import request from './request';
 | 
			
		||||
import { useApiFetch } from './useRequest';
 | 
			
		||||
import { useApiFetch } from '@/hooks/useRequest';
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 可用于各模块定义各自api请求
 | 
			
		||||
 
 | 
			
		||||
@@ -4,7 +4,7 @@ import { getClientId, getToken } from './utils/storage';
 | 
			
		||||
import { templateResolve } from './utils/string';
 | 
			
		||||
import { ElMessage } from 'element-plus';
 | 
			
		||||
import axios from 'axios';
 | 
			
		||||
import { useApiFetch } from './useRequest';
 | 
			
		||||
import { useApiFetch } from '../hooks/useRequest';
 | 
			
		||||
import Api from './Api';
 | 
			
		||||
 | 
			
		||||
export default {
 | 
			
		||||
 
 | 
			
		||||
@@ -1,9 +1,77 @@
 | 
			
		||||
import openApi from './openApi';
 | 
			
		||||
 | 
			
		||||
// 登录是否使用验证码配置key
 | 
			
		||||
const AccountLoginSecurity = 'AccountLoginSecurity';
 | 
			
		||||
const UseWatermarkConfigKey = 'UseWatermark';
 | 
			
		||||
const MachineConfig = 'MachineConfig';
 | 
			
		||||
const AccountLoginSecurityKey = 'AccountLoginSecurity';
 | 
			
		||||
const MachineConfigKey = 'MachineConfig';
 | 
			
		||||
const SysStyleConfigKey = 'SysStyleConfig';
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取账号登录安全配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getAccountLoginSecurity(): Promise<any> {
 | 
			
		||||
    const value = await getConfigValue(AccountLoginSecurityKey);
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return null;
 | 
			
		||||
    }
 | 
			
		||||
    const jsonValue = JSON.parse(value);
 | 
			
		||||
    jsonValue.useCaptcha = convertBool(jsonValue.useCaptcha, true);
 | 
			
		||||
    jsonValue.useOtp = convertBool(jsonValue.useOtp, true);
 | 
			
		||||
    return jsonValue;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取全局系统样式配置(logo、title等)
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getSysStyleConfig(): Promise<any> {
 | 
			
		||||
    const value = await getConfigValue(SysStyleConfigKey);
 | 
			
		||||
    const defaultValue = {
 | 
			
		||||
        useWatermark: true,
 | 
			
		||||
    };
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    const jsonValue = JSON.parse(value);
 | 
			
		||||
    // 将字符串转为bool
 | 
			
		||||
    jsonValue.useWatermark = convertBool(jsonValue.useWatermark, true);
 | 
			
		||||
    return jsonValue;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取LDAP登录配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getLdapEnabled(): Promise<any> {
 | 
			
		||||
    const value = await openApi.getLdapEnabled();
 | 
			
		||||
    return convertBool(value, false);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取机器配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getMachineConfig(): Promise<any> {
 | 
			
		||||
    const value = await getConfigValue(MachineConfigKey);
 | 
			
		||||
    const defaultValue = {
 | 
			
		||||
        // 默认1gb
 | 
			
		||||
        uploadMaxFileSize: '1GB',
 | 
			
		||||
    };
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
    try {
 | 
			
		||||
        const jsonValue = JSON.parse(value);
 | 
			
		||||
        return jsonValue;
 | 
			
		||||
    } catch (e) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取系统配置值
 | 
			
		||||
@@ -27,77 +95,6 @@ export async function getBoolConfigValue(key: string, defaultValue: boolean): Pr
 | 
			
		||||
    return convertBool(value, defaultValue);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取账号登录安全配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getAccountLoginSecurity(): Promise<any> {
 | 
			
		||||
    const value = await getConfigValue(AccountLoginSecurity);
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return null;
 | 
			
		||||
    }
 | 
			
		||||
    const jsonValue = JSON.parse(value);
 | 
			
		||||
    jsonValue.useCaptcha = convertBool(jsonValue.useCaptcha, true);
 | 
			
		||||
    jsonValue.useOtp = convertBool(jsonValue.useOtp, true);
 | 
			
		||||
    return jsonValue;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 是否启用水印信息配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function useWatermark(): Promise<any> {
 | 
			
		||||
    const value = await getConfigValue(UseWatermarkConfigKey);
 | 
			
		||||
    const defaultValue = {
 | 
			
		||||
        isUse: true,
 | 
			
		||||
    };
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
    try {
 | 
			
		||||
        const jsonValue = JSON.parse(value);
 | 
			
		||||
        // 将字符串转为bool
 | 
			
		||||
        jsonValue.isUse = convertBool(jsonValue.isUse, true);
 | 
			
		||||
        return jsonValue;
 | 
			
		||||
    } catch (e) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 获取LDAP登录配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getLdapEnabled(): Promise<any> {
 | 
			
		||||
    const value = await openApi.getLdapEnabled();
 | 
			
		||||
    return convertBool(value, false);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * 是否启用水印信息配置
 | 
			
		||||
 *
 | 
			
		||||
 * @returns
 | 
			
		||||
 */
 | 
			
		||||
export async function getMachineConfig(): Promise<any> {
 | 
			
		||||
    const value = await getConfigValue(MachineConfig);
 | 
			
		||||
    const defaultValue = {
 | 
			
		||||
        // 默认1gb
 | 
			
		||||
        uploadMaxFileSize: '1GB',
 | 
			
		||||
    };
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
    try {
 | 
			
		||||
        const jsonValue = JSON.parse(value);
 | 
			
		||||
        return jsonValue;
 | 
			
		||||
    } catch (e) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
function convertBool(value: string, defaultValue: boolean) {
 | 
			
		||||
    if (!value) {
 | 
			
		||||
        return defaultValue;
 | 
			
		||||
 
 | 
			
		||||
@@ -1,13 +1,13 @@
 | 
			
		||||
import router from '../router';
 | 
			
		||||
import { getClientId, getToken } from './utils/storage';
 | 
			
		||||
import { templateResolve } from './utils/string';
 | 
			
		||||
import router from '@/router';
 | 
			
		||||
import { getClientId, getToken } from '@/common/utils/storage';
 | 
			
		||||
import { templateResolve } from '@/common/utils/string';
 | 
			
		||||
import { ElMessage } from 'element-plus';
 | 
			
		||||
import { createFetch } from '@vueuse/core';
 | 
			
		||||
import Api from './Api';
 | 
			
		||||
import { Result, ResultEnum } from './request';
 | 
			
		||||
import config from './config';
 | 
			
		||||
import Api from '@/common/Api';
 | 
			
		||||
import { Result, ResultEnum } from '@/common/request';
 | 
			
		||||
import config from '@/common/config';
 | 
			
		||||
import { unref } from 'vue';
 | 
			
		||||
import { URL_401 } from '../router/staticRouter';
 | 
			
		||||
import { URL_401 } from '@/router/staticRouter';
 | 
			
		||||
 | 
			
		||||
const baseUrl: string = config.baseApiUrl;
 | 
			
		||||
 | 
			
		||||
@@ -1,6 +1,6 @@
 | 
			
		||||
<template>
 | 
			
		||||
    <div class="layout-logo" v-if="setShowLogo" @click="onThemeConfigChange">
 | 
			
		||||
        <img src="@/assets/image/logo.svg" class="layout-logo-medium-img" />
 | 
			
		||||
        <img :src="themeConfig.logoIcon" class="layout-logo-medium-img" />
 | 
			
		||||
        <span>
 | 
			
		||||
            {{ `${themeConfig.globalTitle}` }}
 | 
			
		||||
            <sub
 | 
			
		||||
@@ -9,7 +9,7 @@
 | 
			
		||||
        </span>
 | 
			
		||||
    </div>
 | 
			
		||||
    <div class="layout-logo-size" v-else @click="onThemeConfigChange">
 | 
			
		||||
        <img src="@/assets/image/logo.svg" class="layout-logo-size-img" />
 | 
			
		||||
        <img :src="themeConfig.logoIcon" class="layout-logo-size-img" />
 | 
			
		||||
    </div>
 | 
			
		||||
</template>
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,12 @@
 | 
			
		||||
import { defineStore } from 'pinia';
 | 
			
		||||
import { dateFormat2 } from '@/common/utils/date';
 | 
			
		||||
import { useUserInfo } from '@/store/userInfo';
 | 
			
		||||
import { getSysStyleConfig } from '@/common/sysconfig';
 | 
			
		||||
import { getLocal, getThemeConfig } from '@/common/utils/storage';
 | 
			
		||||
 | 
			
		||||
// 系统默认logo图标,对应于@/assets/image/logo.svg
 | 
			
		||||
const logoIcon =
 | 
			
		||||
    'data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+PHN2ZyB0PSIxNjIxODU5MDA5NjA1IiBjbGFzcz0iaWNvbiIgdmlld0JveD0iMCAwIDEwMjQgMTAyNCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHAtaWQ9Ijk3MDkiIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+PGRlZnM+PHN0eWxlIHR5cGU9InRleHQvY3NzIj48L3N0eWxlPjwvZGVmcz48cGF0aCBkPSJNODIwLjIwMzkyMiA4MTIuMTcyNTQ5SDY4NC42NzQ1MXYtNDUuMTc2NDcxaDExMi40MzkyMTVWMjc5LjA5MDE5Nkg2MzMuNDc0NTFsLTg1LjMzMzMzNCAyNzcuMDgyMzUzYy0zLjAxMTc2NSAxMC4wMzkyMTYtMTIuMDQ3MDU5IDE2LjA2Mjc0NS0yMi4wODYyNzQgMTYuMDYyNzQ1LTEwLjAzOTIxNiAwLTE5LjA3NDUxLTcuMDI3NDUxLTIxLjA4MjM1My0xNy4wNjY2NjdsLTcxLjI3ODQzMS0yODAuMDk0MTE3aC0xODAuNzA1ODgzVjc2Mi45ODAzOTJoMTIwLjQ3MDU4OXY0NS4xNzY0NzFIMjI5Ljg5ODAzOWMtMTIuMDQ3MDU5IDAtMjIuMDg2Mjc1LTEwLjAzOTIxNi0yMi4wODYyNzQtMjIuMDg2Mjc1VjI1Mi45ODgyMzVjMC0xMi4wNDcwNTkgMTAuMDM5MjE2LTIyLjA4NjI3NSAyMi4wODYyNzQtMjIuMDg2Mjc0SDQ1MS43NjQ3MDZjMTAuMDM5MjE2IDAgMTkuMDc0NTEgNy4wMjc0NTEgMjIuMDg2Mjc0IDE3LjA2NjY2Nmw1NS4yMTU2ODcgMjE4Ljg1NDkwMkw1OTUuMzI1NDkgMjUwLjk4MDM5MmMzLjAxMTc2NS05LjAzNTI5NCAxMi4wNDcwNTktMTYuMDYyNzQ1IDIxLjA4MjM1My0xNi4wNjI3NDVoMjAyLjc5MjE1N2MxMi4wNDcwNTkgMCAyMi4wODYyNzUgMTAuMDM5MjE2IDIyLjA4NjI3NSAyMi4wODYyNzV2NTMzLjA4MjM1M2MxLjAwMzkyMiAxMi4wNDcwNTktOS4wMzUyOTQgMjIuMDg2Mjc1LTIxLjA4MjM1MyAyMi4wODYyNzR6IG0wIDAiIGZpbGw9IiNlMjU4MTMiIHAtaWQ9Ijk3MTAiPjwvcGF0aD48cGF0aCBkPSJNNzMxLjg1ODgyNCA0MjUuNjYyNzQ1YzQuMDE1Njg2LTEyLjA0NzA1OS0yLjAwNzg0My0yNS4wOTgwMzktMTQuMDU0OTAyLTI5LjExMzcyNS0xMi4wNDcwNTktNC4wMTU2ODYtMjUuMDk4MDM5IDIuMDA3ODQzLTI5LjExMzcyNiAxNC4wNTQ5MDJMNTYzLjIgNzY2Ljk5NjA3OGgtNzMuMjg2Mjc1TDM3MS40NTA5OCA0MTAuNjAzOTIyYy00LjAxNTY4Ni0xMi4wNDcwNTktMTcuMDY2NjY3LTE4LjA3MDU4OC0yOC4xMDk4MDQtMTQuMDU0OTAyLTEyLjA0NzA1OSA0LjAxNTY4Ni0xOC4wNzA1ODggMTcuMDY2NjY3LTE0LjA1NDkwMSAyOC4xMDk4MDRsMTIzLjQ4MjM1MiAzNzEuNDUwOThjMy4wMTE3NjUgOS4wMzUyOTQgMTIuMDQ3MDU5IDE1LjA1ODgyNCAyMS4wODIzNTMgMTUuMDU4ODIzaDcyLjI4MjM1M2wtNTMuMjA3ODQzIDE2MC42Mjc0NTEgNDYuMTgwMzkyIDIuMDA3ODQ0IDE5Mi43NTI5NDItNTQ4LjE0MTE3N3oiIGZpbGw9IiMyYzJjMmMiIHAtaWQ9Ijk3MTEiPjwvcGF0aD48L3N2Zz4=';
 | 
			
		||||
 | 
			
		||||
export const useThemeConfig = defineStore('themeConfig', {
 | 
			
		||||
    state: (): ThemeConfigState => ({
 | 
			
		||||
@@ -130,7 +136,9 @@ export const useThemeConfig = defineStore('themeConfig', {
 | 
			
		||||
            // 网站主标题(菜单导航、浏览器当前网页标题)
 | 
			
		||||
            globalTitle: 'mayfly',
 | 
			
		||||
            // 网站副标题(登录页顶部文字)
 | 
			
		||||
            globalViceTitle: 'mayfly',
 | 
			
		||||
            globalViceTitle: 'mayfly-go',
 | 
			
		||||
            // 网站logo icon, base64编码内容
 | 
			
		||||
            logoIcon: logoIcon,
 | 
			
		||||
            // 默认初始语言,可选值"<zh-cn|en|zh-tw>",默认 zh-cn
 | 
			
		||||
            globalI18n: 'zh-cn',
 | 
			
		||||
            // 默认全局组件大小,可选值"<|large|default|small>",默认 ''
 | 
			
		||||
@@ -142,19 +150,34 @@ export const useThemeConfig = defineStore('themeConfig', {
 | 
			
		||||
        },
 | 
			
		||||
    }),
 | 
			
		||||
    actions: {
 | 
			
		||||
        // 设置布局配置
 | 
			
		||||
        setThemeConfig(data: ThemeConfigState) {
 | 
			
		||||
            this.themeConfig = data.themeConfig;
 | 
			
		||||
        },
 | 
			
		||||
        // 设置水印配置信息
 | 
			
		||||
        setWatermarkConfig(useWatermarkConfig: any) {
 | 
			
		||||
        initThemeConfig() {
 | 
			
		||||
            // 获取缓存中的布局配置
 | 
			
		||||
            const tc = getThemeConfig();
 | 
			
		||||
            if (tc) {
 | 
			
		||||
                this.themeConfig = tc;
 | 
			
		||||
                document.documentElement.style.cssText = getLocal('themeConfigStyle');
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            // 根据后台系统配置初始化
 | 
			
		||||
            getSysStyleConfig().then((res) => {
 | 
			
		||||
                if (res?.title) {
 | 
			
		||||
                    this.themeConfig.globalTitle = res.title;
 | 
			
		||||
                }
 | 
			
		||||
                if (res?.viceTitle) {
 | 
			
		||||
                    this.themeConfig.globalViceTitle = res.viceTitle;
 | 
			
		||||
                }
 | 
			
		||||
                if (res?.logoIcon) {
 | 
			
		||||
                    this.themeConfig.logoIcon = res.logoIcon;
 | 
			
		||||
                }
 | 
			
		||||
 | 
			
		||||
                this.themeConfig.watermarkText = [];
 | 
			
		||||
            this.themeConfig.isWatermark = useWatermarkConfig.isUse;
 | 
			
		||||
            if (!useWatermarkConfig.isUse) {
 | 
			
		||||
                this.themeConfig.isWatermark = res?.useWatermark;
 | 
			
		||||
                if (!res?.useWatermark) {
 | 
			
		||||
                    return;
 | 
			
		||||
                }
 | 
			
		||||
                // 索引2为用户自定义水印信息
 | 
			
		||||
            this.themeConfig.watermarkText[2] = useWatermarkConfig.content;
 | 
			
		||||
                this.themeConfig.watermarkText[2] = res.watermarkContent;
 | 
			
		||||
            });
 | 
			
		||||
        },
 | 
			
		||||
        // 设置水印用户信息
 | 
			
		||||
        setWatermarkUser(del: boolean = false) {
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										1
									
								
								mayfly_go_web/src/types/pinia.d.ts
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								mayfly_go_web/src/types/pinia.d.ts
									
									
									
									
										vendored
									
									
								
							@@ -49,6 +49,7 @@ declare interface ThemeConfigState {
 | 
			
		||||
        isRequestRoutes: boolean;
 | 
			
		||||
        globalTitle: string;
 | 
			
		||||
        globalViceTitle: string;
 | 
			
		||||
        logoIcon: string;
 | 
			
		||||
        globalI18n: string;
 | 
			
		||||
        globalComponentSize: string;
 | 
			
		||||
        terminalForeground: string;
 | 
			
		||||
 
 | 
			
		||||
@@ -2,9 +2,9 @@
 | 
			
		||||
    <div class="login-container flex">
 | 
			
		||||
        <div class="login-left">
 | 
			
		||||
            <div class="login-left-logo">
 | 
			
		||||
                <img :src="logoMini" />
 | 
			
		||||
                <img :src="themeConfig.logoIcon" />
 | 
			
		||||
                <div class="login-left-logo-text">
 | 
			
		||||
                    <span>mayfly-go</span>
 | 
			
		||||
                    <span>{{ themeConfig.globalViceTitle }}</span>
 | 
			
		||||
                    <!-- <span class="login-left-logo-text-msg">mayfly-go</span> -->
 | 
			
		||||
                </div>
 | 
			
		||||
            </div>
 | 
			
		||||
@@ -18,7 +18,7 @@
 | 
			
		||||
                <span class="login-right-warp-one"></span>
 | 
			
		||||
                <span class="login-right-warp-two"></span>
 | 
			
		||||
                <div class="login-right-warp-mian">
 | 
			
		||||
                    <div class="login-right-warp-main-title">mayfly-go</div>
 | 
			
		||||
                    <div class="login-right-warp-main-title">{{ themeConfig.globalViceTitle }}</div>
 | 
			
		||||
                    <div class="login-right-warp-main-form">
 | 
			
		||||
                        <div v-if="!state.isScan">
 | 
			
		||||
                            <el-tabs v-model="state.tabsActiveName">
 | 
			
		||||
@@ -47,11 +47,11 @@
 | 
			
		||||
<script setup lang="ts" name="loginIndex">
 | 
			
		||||
import { ref, defineAsyncComponent, onMounted, reactive } from 'vue';
 | 
			
		||||
import { useThemeConfig } from '@/store/themeConfig';
 | 
			
		||||
import logoMini from '@/assets/image/logo.svg';
 | 
			
		||||
import loginBgImg from '@/assets/image/login-bg-main.svg';
 | 
			
		||||
import loginBgSplitImg from '@/assets/image/login-bg-split.svg';
 | 
			
		||||
import openApi from '@/common/openApi';
 | 
			
		||||
import config from '@/common/config';
 | 
			
		||||
import { storeToRefs } from 'pinia';
 | 
			
		||||
 | 
			
		||||
// 引入组件
 | 
			
		||||
const Account = defineAsyncComponent(() => import('./component/AccountLogin.vue'));
 | 
			
		||||
@@ -60,6 +60,7 @@ const loginForm = ref<{ loginResDeal: (data: any) => void } | null>(null);
 | 
			
		||||
 | 
			
		||||
// 定义变量内容
 | 
			
		||||
const storesThemeConfig = useThemeConfig();
 | 
			
		||||
const { themeConfig } = storeToRefs(storesThemeConfig);
 | 
			
		||||
 | 
			
		||||
const state = reactive({
 | 
			
		||||
    tabsActiveName: 'account',
 | 
			
		||||
 
 | 
			
		||||
@@ -24,7 +24,7 @@
 | 
			
		||||
            </template>
 | 
			
		||||
 | 
			
		||||
            <template #action="{ data }">
 | 
			
		||||
                <div style="text-align: left">
 | 
			
		||||
                <div>
 | 
			
		||||
                    <el-button @click="editDbBackup(data)" type="primary" link>编辑</el-button>
 | 
			
		||||
                    <el-button v-if="!data.enabled" @click="enableDbBackup(data)" type="primary" link>启用</el-button>
 | 
			
		||||
                    <el-button v-if="data.enabled" @click="disableDbBackup(data)" type="primary" link>禁用</el-button>
 | 
			
		||||
@@ -75,7 +75,7 @@ const columns = [
 | 
			
		||||
    TableColumn.new('enabled', '是否启用'),
 | 
			
		||||
    TableColumn.new('lastResult', '执行结果'),
 | 
			
		||||
    TableColumn.new('lastTime', '执行时间').isTime(),
 | 
			
		||||
    TableColumn.new('action', '操作').isSlot().setMinWidth(160).fixedRight().alignCenter(),
 | 
			
		||||
    TableColumn.new('action', '操作').isSlot().setMinWidth(160).fixedRight(),
 | 
			
		||||
];
 | 
			
		||||
 | 
			
		||||
const emptyQuery = {
 | 
			
		||||
 
 | 
			
		||||
@@ -2,11 +2,6 @@
 | 
			
		||||
# yarn lockfile v1
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
"@babel/parser@^7.23.5":
 | 
			
		||||
  version "7.23.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@babel/parser/-/parser-7.23.5.tgz#37dee97c4752af148e1d38c34b856b2507660563"
 | 
			
		||||
  integrity sha512-hOOqoiNXrmGdFbhgCzu6GiURxUgM27Xwd/aPuu8RfHEZPBzL1Z54okAHAQjXfcQNwvrlkAmAp4SlRTZ45vlthQ==
 | 
			
		||||
 | 
			
		||||
"@babel/parser@^7.23.6":
 | 
			
		||||
  version "7.23.6"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@babel/parser/-/parser-7.23.6.tgz#ba1c9e512bda72a47e285ae42aff9d2a635a9e3b"
 | 
			
		||||
@@ -24,11 +19,6 @@
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@ctrl/tinycolor/-/tinycolor-3.4.1.tgz"
 | 
			
		||||
  integrity sha512-ej5oVy6lykXsvieQtqZxCOaLT+xD4+QNarq78cIYISHmZXshCvROLudpQN3lfL8G0NL7plMSSK+zlyvCaIJ4Iw==
 | 
			
		||||
 | 
			
		||||
"@element-plus/icons-vue@^2.1.0":
 | 
			
		||||
  version "2.1.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@element-plus/icons-vue/-/icons-vue-2.1.0.tgz#7ad90d08a8c0d5fd3af31c4f73264ca89614397a"
 | 
			
		||||
  integrity sha512-PSBn3elNoanENc1vnCfh+3WA9fimRC7n+fWkf3rE5jvv+aBohNHABC/KAR5KWPecxWxDTVT1ERpRbOMRcOV/vA==
 | 
			
		||||
 | 
			
		||||
"@element-plus/icons-vue@^2.3.1":
 | 
			
		||||
  version "2.3.1"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@element-plus/icons-vue/-/icons-vue-2.3.1.tgz#1f635ad5fdd5c85ed936481525570e82b5a8307a"
 | 
			
		||||
@@ -440,152 +430,141 @@
 | 
			
		||||
    "@typescript-eslint/types" "6.7.4"
 | 
			
		||||
    eslint-visitor-keys "^3.4.1"
 | 
			
		||||
 | 
			
		||||
"@vitejs/plugin-vue@^4.5.2":
 | 
			
		||||
  version "4.5.2"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vitejs/plugin-vue/-/plugin-vue-4.5.2.tgz#1212d81bc83680e14448fefe55abd9fe1ed49ed1"
 | 
			
		||||
  integrity sha512-UGR3DlzLi/SaVBPX0cnSyE37vqxU3O6chn8l0HJNzQzDia6/Au2A4xKv+iIJW8w2daf80G7TYHhi1pAUjdZ0bQ==
 | 
			
		||||
"@vitejs/plugin-vue@^5.0.2":
 | 
			
		||||
  version "5.0.2"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vitejs/plugin-vue/-/plugin-vue-5.0.2.tgz#8428ec3f446b9c2f7a7ec950f34e3d6f3c665444"
 | 
			
		||||
  integrity sha512-kEjJHrLb5ePBvjD0SPZwJlw1QTRcjjCA9sB5VyfonoXVBxTS7TMnqL6EkLt1Eu61RDeiuZ/WN9Hf6PxXhPI2uA==
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-core@3.3.11":
 | 
			
		||||
  version "3.3.11"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-core/-/compiler-core-3.3.11.tgz#9fa26f8c81b9b34365f94ce1ed4d0e6e6f94a2ac"
 | 
			
		||||
  integrity sha512-h97/TGWBilnLuRaj58sxNrsUU66fwdRKLOLQ9N/5iNDfp+DZhYH9Obhe0bXxhedl8fjAgpRANpiZfbgWyruQ0w==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/parser" "^7.23.5"
 | 
			
		||||
    "@vue/shared" "3.3.11"
 | 
			
		||||
    estree-walker "^2.0.2"
 | 
			
		||||
    source-map-js "^1.0.2"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-core@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-core/-/compiler-core-3.4.0.tgz#2a35bc4b70afb5504ff62f916e22f9080d8149b6"
 | 
			
		||||
  integrity sha512-cw4S15PkNGTKkP9OFFl4wnQoJJk+HqaYBafgrpDnSukiQGpcYJeRpzmqnCVCIkl6V6Eqsv58E0OAdl6b592vuA==
 | 
			
		||||
"@vue/compiler-core@3.4.3":
 | 
			
		||||
  version "3.4.3"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-core/-/compiler-core-3.4.3.tgz#8e8f88273f061cf0a49bf958255f5f0621f12d8b"
 | 
			
		||||
  integrity sha512-u8jzgFg0EDtSrb/hG53Wwh1bAOQFtc1ZCegBpA/glyvTlgHl+tq13o1zvRfLbegYUw/E4mSTGOiCnAJ9SJ+lsg==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/parser" "^7.23.6"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.3"
 | 
			
		||||
    entities "^4.5.0"
 | 
			
		||||
    estree-walker "^2.0.2"
 | 
			
		||||
    source-map-js "^1.0.2"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-dom@3.3.11":
 | 
			
		||||
  version "3.3.11"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-dom/-/compiler-dom-3.3.11.tgz#36a76ea3a296d41bad133a6912cb0a847d969e4f"
 | 
			
		||||
  integrity sha512-zoAiUIqSKqAJ81WhfPXYmFGwDRuO+loqLxvXmfUdR5fOitPoUiIeFI9cTTyv9MU5O1+ZZglJVTusWzy+wfk5hw==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-core" "3.3.11"
 | 
			
		||||
    "@vue/shared" "3.3.11"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-dom@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-dom/-/compiler-dom-3.4.0.tgz#25d4c1e24a2e37c4136cdc593cd533d371bc573b"
 | 
			
		||||
  integrity sha512-E957uOhpoE48YjZGWeAoLmNYd3UeU4oIP8kJi8Rcsb9l2tV8Z48Jn07Zgq1aW0v3vuhlmydEKkKKbhLpADHXEA==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-core" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-sfc@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-sfc/-/compiler-sfc-3.4.0.tgz#dab7b87a9a09e3860a4b5c9baf6b7d3ab8af0c0f"
 | 
			
		||||
  integrity sha512-PWE0mE2yW7bJS7PmaCrVDEG6KPaDJo0pb4AKnCxJ5lRRDO4IwL/fswBGhCpov+v/c+N/e+hQHpXNwvqU9BtUXg==
 | 
			
		||||
"@vue/compiler-core@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-core/-/compiler-core-3.4.5.tgz#9565aebaadef8649eb7c8e150a5f4f4e2542667d"
 | 
			
		||||
  integrity sha512-Daka7P1z2AgKjzuueWXhwzIsKu0NkLB6vGbNVEV2iJ8GJTrzraZo/Sk4GWCMRtd/qVi3zwnk+Owbd/xSZbwHtQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/parser" "^7.23.6"
 | 
			
		||||
    "@vue/compiler-core" "3.4.0"
 | 
			
		||||
    "@vue/compiler-dom" "3.4.0"
 | 
			
		||||
    "@vue/compiler-ssr" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
    entities "^4.5.0"
 | 
			
		||||
    estree-walker "^2.0.2"
 | 
			
		||||
    source-map-js "^1.0.2"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-dom@3.4.3":
 | 
			
		||||
  version "3.4.3"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-dom/-/compiler-dom-3.4.3.tgz#bea8acde9585d5ce92a3f11c062c863fb33e44d7"
 | 
			
		||||
  integrity sha512-oGF1E9/htI6JWj/lTJgr6UgxNCtNHbM6xKVreBWeZL9QhRGABRVoWGAzxmtBfSOd+w0Zi5BY0Es/tlJrN6WgEg==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-core" "3.4.3"
 | 
			
		||||
    "@vue/shared" "3.4.3"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-dom@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-dom/-/compiler-dom-3.4.5.tgz#c53c9d7715b777b1d6d2adcbc491bfd4f9510edd"
 | 
			
		||||
  integrity sha512-J8YlxknJVd90SXFJ4HwGANSAXsx5I0lK30sO/zvYV7s5gXf7gZR7r/1BmZ2ju7RGH1lnc6bpBc6nL61yW+PsAQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-core" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-sfc@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-sfc/-/compiler-sfc-3.4.5.tgz#f93f986dfc5c7f72b9a5e00b48be75d9116cc948"
 | 
			
		||||
  integrity sha512-jauvkDuSSUbP0ebhfNqljhShA90YEfX/0wZ+w40oZF43IjGyWYjqYaJbvMJwGOd+9+vODW6eSvnk28f0SGV7OQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/parser" "^7.23.6"
 | 
			
		||||
    "@vue/compiler-core" "3.4.5"
 | 
			
		||||
    "@vue/compiler-dom" "3.4.5"
 | 
			
		||||
    "@vue/compiler-ssr" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
    estree-walker "^2.0.2"
 | 
			
		||||
    magic-string "^0.30.5"
 | 
			
		||||
    postcss "^8.4.32"
 | 
			
		||||
    source-map-js "^1.0.2"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-sfc@^3.3.11":
 | 
			
		||||
  version "3.3.11"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-sfc/-/compiler-sfc-3.3.11.tgz#acfae240c875d067e0e2c9a4e2d910074408c73b"
 | 
			
		||||
  integrity sha512-U4iqPlHO0KQeK1mrsxCN0vZzw43/lL8POxgpzcJweopmqtoYy9nljJzWDIQS3EfjiYhfdtdk9Gtgz7MRXnz3GA==
 | 
			
		||||
"@vue/compiler-sfc@^3.4.3":
 | 
			
		||||
  version "3.4.3"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-sfc/-/compiler-sfc-3.4.3.tgz#a9d35b2deef38576dedd9938851c032fb2ca8617"
 | 
			
		||||
  integrity sha512-NuJqb5is9I4uzv316VRUDYgIlPZCG8D+ARt5P4t5UDShIHKL25J3TGZAUryY/Aiy0DsY7srJnZL5ryB6DD63Zw==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/parser" "^7.23.5"
 | 
			
		||||
    "@vue/compiler-core" "3.3.11"
 | 
			
		||||
    "@vue/compiler-dom" "3.3.11"
 | 
			
		||||
    "@vue/compiler-ssr" "3.3.11"
 | 
			
		||||
    "@vue/reactivity-transform" "3.3.11"
 | 
			
		||||
    "@vue/shared" "3.3.11"
 | 
			
		||||
    "@babel/parser" "^7.23.6"
 | 
			
		||||
    "@vue/compiler-core" "3.4.3"
 | 
			
		||||
    "@vue/compiler-dom" "3.4.3"
 | 
			
		||||
    "@vue/compiler-ssr" "3.4.3"
 | 
			
		||||
    "@vue/shared" "3.4.3"
 | 
			
		||||
    estree-walker "^2.0.2"
 | 
			
		||||
    magic-string "^0.30.5"
 | 
			
		||||
    postcss "^8.4.32"
 | 
			
		||||
    source-map-js "^1.0.2"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-ssr@3.3.11":
 | 
			
		||||
  version "3.3.11"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-ssr/-/compiler-ssr-3.3.11.tgz#598942a73b64f2bd3f95908b104a7fbb55fc41a2"
 | 
			
		||||
  integrity sha512-Zd66ZwMvndxRTgVPdo+muV4Rv9n9DwQ4SSgWWKWkPFebHQfVYRrVjeygmmDmPewsHyznCNvJ2P2d6iOOhdv8Qg==
 | 
			
		||||
"@vue/compiler-ssr@3.4.3":
 | 
			
		||||
  version "3.4.3"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-ssr/-/compiler-ssr-3.4.3.tgz#c3f641a15a04893b5bc3278f3dac65bed44dce1d"
 | 
			
		||||
  integrity sha512-wnYQtMBkeFSxgSSQbYGQeXPhQacQiog2c6AlvMldQH6DB+gSXK/0F6DVXAJfEiuBSgBhUc8dwrrG5JQcqwalsA==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-dom" "3.3.11"
 | 
			
		||||
    "@vue/shared" "3.3.11"
 | 
			
		||||
    "@vue/compiler-dom" "3.4.3"
 | 
			
		||||
    "@vue/shared" "3.4.3"
 | 
			
		||||
 | 
			
		||||
"@vue/compiler-ssr@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-ssr/-/compiler-ssr-3.4.0.tgz#0e437c6e619ce4ec515d2d77a0a9e67e877cc2cd"
 | 
			
		||||
  integrity sha512-+oXKy105g9DIYQKDi3Gwung0xqQX5gJHr0GR+Vf7yK/WkNDM6q61ummcKmKAB85EIst8y3vj2PA9z9YU5Oc4DQ==
 | 
			
		||||
"@vue/compiler-ssr@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/compiler-ssr/-/compiler-ssr-3.4.5.tgz#d412a4c9b10d69172a5ce0ec78de98dad441a58d"
 | 
			
		||||
  integrity sha512-DDdEcDzj2lWTMfUMMtEpLDhURai9LhM0zSZ219jCt7b2Vyl0/jy3keFgCPMitG0V1S1YG4Cmws3lWHWdxHQOpg==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-dom" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/compiler-dom" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
 | 
			
		||||
"@vue/devtools-api@^6.5.0":
 | 
			
		||||
  version "6.5.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/devtools-api/-/devtools-api-6.5.0.tgz#98b99425edee70b4c992692628fa1ea2c1e57d07"
 | 
			
		||||
  integrity sha512-o9KfBeaBmCKl10usN4crU53fYtC1r7jJwdGKjPT24t348rHxgfpZ0xL3Xm/gLUYnc0oTp8LAmrxOeLyu6tbk2Q==
 | 
			
		||||
 | 
			
		||||
"@vue/reactivity-transform@3.3.11":
 | 
			
		||||
  version "3.3.11"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/reactivity-transform/-/reactivity-transform-3.3.11.tgz#2bd486f4eff60c8724309925618891e722fcfadc"
 | 
			
		||||
  integrity sha512-fPGjH0wqJo68A0wQ1k158utDq/cRyZNlFoxGwNScE28aUFOKFEnCBsvyD8jHn+0kd0UKVpuGuaZEQ6r9FJRqCg==
 | 
			
		||||
"@vue/reactivity@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/reactivity/-/reactivity-3.4.5.tgz#68bc91cd356eed95dc5e9e0570e3f7becaee578b"
 | 
			
		||||
  integrity sha512-BcWkKvjdvqJwb7BhhFkXPLDCecX4d4a6GATvCduJQDLv21PkPowAE5GKuIE5p6RC07/Lp9FMkkq4AYCTVF5KlQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@babel/parser" "^7.23.5"
 | 
			
		||||
    "@vue/compiler-core" "3.3.11"
 | 
			
		||||
    "@vue/shared" "3.3.11"
 | 
			
		||||
    estree-walker "^2.0.2"
 | 
			
		||||
    magic-string "^0.30.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
 | 
			
		||||
"@vue/reactivity@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/reactivity/-/reactivity-3.4.0.tgz#84e1d4196bed3fb471e3593d187680a35cfee23a"
 | 
			
		||||
  integrity sha512-X6BvQjNcgKKHWPQzlRJjZvIu72Kkn8xJSv6VNptqWh8dToMknD0Hch1l4N7llKgVt6Diq4lMeUnErbZFvuGlAA==
 | 
			
		||||
"@vue/runtime-core@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/runtime-core/-/runtime-core-3.4.5.tgz#2bf253a6f6b0430af1aacf0fdfd8f5782feefce9"
 | 
			
		||||
  integrity sha512-wh9ELIOQKeWT9SaUPdLrsxRkZv14jp+SJm9aiQGWio+/MWNM3Lib0wE6CoKEqQ9+SCYyGjDBhTOTtO47kCgbkg==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/reactivity" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
 | 
			
		||||
"@vue/runtime-core@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/runtime-core/-/runtime-core-3.4.0.tgz#6c49cac6142d941954c68c2888160c8fbcdbfc11"
 | 
			
		||||
  integrity sha512-NYrj/JgMMqnSWcIud8lLzDQrBLu+EVEeQ56QE9DYJeKG2eFrnQy8o/h57R9nCprafHs0uImKL3xsdXjHseYVxw==
 | 
			
		||||
"@vue/runtime-dom@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/runtime-dom/-/runtime-dom-3.4.5.tgz#b43736d66c32f6038778024587592cb9d68495de"
 | 
			
		||||
  integrity sha512-n5ewvOjyG3IEpqGBahdPXODFSpVlSz3H4LF76Sx0XAqpIOqyJ5bIb2PrdYuH2ogBMAQPh+o5tnoH4nJpBr8U0Q==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/reactivity" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
 | 
			
		||||
"@vue/runtime-dom@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/runtime-dom/-/runtime-dom-3.4.0.tgz#9397aa9e74c6f44a03c4f4755d931a10dbf6ec44"
 | 
			
		||||
  integrity sha512-1ZoHEsA5l77qbx2F+SWo/hQdBksPuOmww1t/jznidDG+xMB/iidafEFvo2ZTtZii0JfTIrlDhjshfYUvQC17wQ==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/runtime-core" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/runtime-core" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
    csstype "^3.1.3"
 | 
			
		||||
 | 
			
		||||
"@vue/server-renderer@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/server-renderer/-/server-renderer-3.4.0.tgz#7b0c5e71463140c64d05c314f46a07c9dcc62625"
 | 
			
		||||
  integrity sha512-GuOVCyLDlWPu8nKo5AUxb8B+iB/Ik4I1WwqAlBqf5+y48z6D6rvKshp7KR3cJea+pte1tdTsb0+Ja82KizMZOw==
 | 
			
		||||
"@vue/server-renderer@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/server-renderer/-/server-renderer-3.4.5.tgz#4bfa7aa763217d8b2d4767d2c8d968a9d40352c1"
 | 
			
		||||
  integrity sha512-jOFc/VE87yvifQpNju12VcqimH8pBLxdcT+t3xMeiED1K6DfH9SORyhFEoZlW5TG2Vwfn3Ul5KE+1aC99xnSBg==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-ssr" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/compiler-ssr" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
 | 
			
		||||
"@vue/shared@3.3.11":
 | 
			
		||||
  version "3.3.11"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/shared/-/shared-3.3.11.tgz#f6a038e15237edefcc90dbfe7edb806dd355c7bd"
 | 
			
		||||
  integrity sha512-u2G8ZQ9IhMWTMXaWqZycnK4UthG1fA238CD+DP4Dm4WJi5hdUKKLg0RMRaRpDPNMdkTwIDkp7WtD0Rd9BH9fLw==
 | 
			
		||||
"@vue/shared@3.4.3":
 | 
			
		||||
  version "3.4.3"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/shared/-/shared-3.4.3.tgz#01d54b32b9796c85c853c670d9395a813f23a8c2"
 | 
			
		||||
  integrity sha512-rIwlkkP1n4uKrRzivAKPZIEkHiuwY5mmhMJ2nZKCBLz8lTUlE73rQh4n1OnnMurXt1vcUNyH4ZPfdh8QweTjpQ==
 | 
			
		||||
 | 
			
		||||
"@vue/shared@3.4.0":
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/shared/-/shared-3.4.0.tgz#b6e804a4742929f94f0159aafd0a2940621cd8de"
 | 
			
		||||
  integrity sha512-Nhh3ed3G1R6HDAWiG6YYFt0Zmq/To6u5vjzwa9TIquGheCXPY6nEdIAO8ZdlwXsWqC2yNLj700FOvShpYt5CEA==
 | 
			
		||||
"@vue/shared@3.4.5":
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/@vue/shared/-/shared-3.4.5.tgz#c8b4eb6399a7fc986565ea736d938b3a1579256d"
 | 
			
		||||
  integrity sha512-6XptuzlMvN4l4cDnDw36pdGEV+9njYkQ1ZE0Q6iZLwrKefKaOJyiFmcP3/KBDHbt72cJZGtllAc1GaHe6XGAyg==
 | 
			
		||||
 | 
			
		||||
"@vueuse/core@^10.7.0":
 | 
			
		||||
  version "10.7.0"
 | 
			
		||||
@@ -2002,16 +1981,16 @@ vue-router@^4.2.5:
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/devtools-api" "^6.5.0"
 | 
			
		||||
 | 
			
		||||
vue@^3.4.0:
 | 
			
		||||
  version "3.4.0"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/vue/-/vue-3.4.0.tgz#0671a2607265c16ab56041174744b6bed8ac2baa"
 | 
			
		||||
  integrity sha512-iTE9Ve/7DO/H39+gXHrNkRdnh1jDwPe/fap4brbPKkp1APMkS03OiZ+UY0dwpqtRX0iPWQTkh8Fu3hKgLtaxfA==
 | 
			
		||||
vue@^3.4.5:
 | 
			
		||||
  version "3.4.5"
 | 
			
		||||
  resolved "https://registry.npmmirror.com/vue/-/vue-3.4.5.tgz#c08b9d903a20faaf4df7270bf2fa7487741b2294"
 | 
			
		||||
  integrity sha512-VH6nHFhLPjgu2oh5vEBXoNZxsGHuZNr3qf4PHClwJWw6IDqw6B3x+4J+ABdoZ0aJuT8Zi0zf3GpGlLQCrGWHrw==
 | 
			
		||||
  dependencies:
 | 
			
		||||
    "@vue/compiler-dom" "3.4.0"
 | 
			
		||||
    "@vue/compiler-sfc" "3.4.0"
 | 
			
		||||
    "@vue/runtime-dom" "3.4.0"
 | 
			
		||||
    "@vue/server-renderer" "3.4.0"
 | 
			
		||||
    "@vue/shared" "3.4.0"
 | 
			
		||||
    "@vue/compiler-dom" "3.4.5"
 | 
			
		||||
    "@vue/compiler-sfc" "3.4.5"
 | 
			
		||||
    "@vue/runtime-dom" "3.4.5"
 | 
			
		||||
    "@vue/server-renderer" "3.4.5"
 | 
			
		||||
    "@vue/shared" "3.4.5"
 | 
			
		||||
 | 
			
		||||
which@^2.0.1:
 | 
			
		||||
  version "2.0.2"
 | 
			
		||||
 
 | 
			
		||||
@@ -28,17 +28,17 @@ type QueryColumn struct {
 | 
			
		||||
 | 
			
		||||
// 执行查询语句
 | 
			
		||||
// 依次返回 列信息数组(顺序),结果map,错误
 | 
			
		||||
func (d *DbConn) Query(querySql string) ([]*QueryColumn, []map[string]any, error) {
 | 
			
		||||
	return d.QueryContext(context.Background(), querySql)
 | 
			
		||||
func (d *DbConn) Query(querySql string, args ...any) ([]*QueryColumn, []map[string]any, error) {
 | 
			
		||||
	return d.QueryContext(context.Background(), querySql, args...)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// 执行查询语句
 | 
			
		||||
// 依次返回 列信息数组(顺序),结果map,错误
 | 
			
		||||
func (d *DbConn) QueryContext(ctx context.Context, querySql string) ([]*QueryColumn, []map[string]any, error) {
 | 
			
		||||
func (d *DbConn) QueryContext(ctx context.Context, querySql string, args ...any) ([]*QueryColumn, []map[string]any, error) {
 | 
			
		||||
	result := make([]map[string]any, 0, 16)
 | 
			
		||||
	columns, err := walkTableRecord(ctx, d.db, querySql, func(record map[string]any, columns []*QueryColumn) {
 | 
			
		||||
		result = append(result, record)
 | 
			
		||||
	})
 | 
			
		||||
	}, args...)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		return nil, nil, wrapSqlError(err)
 | 
			
		||||
	}
 | 
			
		||||
@@ -111,8 +111,8 @@ func (d *DbConn) Close() {
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func walkTableRecord(ctx context.Context, db *sql.DB, selectSql string, walk func(record map[string]any, columns []*QueryColumn)) ([]*QueryColumn, error) {
 | 
			
		||||
	rows, err := db.QueryContext(ctx, selectSql)
 | 
			
		||||
func walkTableRecord(ctx context.Context, db *sql.DB, selectSql string, walk func(record map[string]any, columns []*QueryColumn), args ...any) ([]*QueryColumn, error) {
 | 
			
		||||
	rows, err := db.QueryContext(ctx, selectSql, args...)
 | 
			
		||||
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		return nil, err
 | 
			
		||||
 
 | 
			
		||||
@@ -1 +0,0 @@
 | 
			
		||||
package dbm
 | 
			
		||||
@@ -142,7 +142,7 @@ func (md *MysqlDialect) GetPrimaryKey(tablename string) (string, error) {
 | 
			
		||||
 | 
			
		||||
// 获取表索引信息
 | 
			
		||||
func (md *MysqlDialect) GetTableIndex(tableName string) ([]Index, error) {
 | 
			
		||||
	_, res, err := md.dc.Query(fmt.Sprintf(GetLocalSql(MYSQL_META_FILE, MYSQL_INDEX_INFO_KEY), tableName))
 | 
			
		||||
	_, res, err := md.dc.Query(GetLocalSql(MYSQL_META_FILE, MYSQL_INDEX_INFO_KEY), tableName)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		return nil, err
 | 
			
		||||
	}
 | 
			
		||||
 
 | 
			
		||||
@@ -38,7 +38,7 @@ WHERE
 | 
			
		||||
    SELECT
 | 
			
		||||
      database ()
 | 
			
		||||
  )
 | 
			
		||||
  AND table_name = '%s'
 | 
			
		||||
  AND table_name = ?
 | 
			
		||||
ORDER BY
 | 
			
		||||
  index_name asc,
 | 
			
		||||
  SEQ_IN_INDEX asc
 | 
			
		||||
 
 | 
			
		||||
@@ -28,12 +28,6 @@ CREATE TABLE `t_db_instance` (
 | 
			
		||||
    PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='数据库实例信息表';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_db_instance
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -56,12 +50,6 @@ CREATE TABLE `t_db` (
 | 
			
		||||
    PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='数据库资源信息表';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_db
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_sql
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -84,12 +72,6 @@ CREATE TABLE `t_db_sql` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='数据库sql信息';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_db_sql
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_sql_exec
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -115,10 +97,143 @@ CREATE TABLE `t_db_sql_exec` (
 | 
			
		||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='数据库sql执行记录表';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_db_sql_exec
 | 
			
		||||
-- Table structure for t_db_backup
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_backup`;
 | 
			
		||||
CREATE TABLE `t_db_backup` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `name` varchar(32) NOT NULL COMMENT '备份名称',
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `db_name` varchar(64) NOT NULL COMMENT '数据库名称',
 | 
			
		||||
    `repeated` tinyint(1) DEFAULT NULL COMMENT '是否重复执行',
 | 
			
		||||
    `interval` bigint(20) DEFAULT NULL COMMENT '备份周期',
 | 
			
		||||
    `start_time` datetime DEFAULT NULL COMMENT '首次备份时间',
 | 
			
		||||
    `enabled` tinyint(1) DEFAULT NULL COMMENT '是否启用',
 | 
			
		||||
    `last_status` tinyint(4) DEFAULT NULL COMMENT '上次备份状态',
 | 
			
		||||
    `last_result` varchar(256) DEFAULT NULL COMMENT '上次备份结果',
 | 
			
		||||
    `last_time` datetime DEFAULT NULL COMMENT '上次备份时间',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `creator_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `creator` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `update_time` datetime DEFAULT NULL,
 | 
			
		||||
    `modifier_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `modifier` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_name` (`db_name`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_backup_history
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_backup_history`;
 | 
			
		||||
CREATE TABLE `t_db_backup_history` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `name` varchar(64) NOT NULL COMMENT '历史备份名称',
 | 
			
		||||
    `db_backup_id` bigint(20) unsigned NOT NULL COMMENT '数据库备份ID',
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `db_name` varchar(64) NOT NULL COMMENT '数据库名称',
 | 
			
		||||
    `uuid` varchar(36) NOT NULL COMMENT '历史备份uuid',
 | 
			
		||||
    `binlog_file_name` varchar(32) DEFAULT NULL COMMENT 'BINLOG文件名',
 | 
			
		||||
    `binlog_sequence` bigint(20) DEFAULT NULL COMMENT 'BINLOG序列号',
 | 
			
		||||
    `binlog_position` bigint(20) DEFAULT NULL COMMENT 'BINLOG位置',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL COMMENT '历史备份创建时间',
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_backup_id` (`db_backup_id`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_name` (`db_name`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_restore
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_restore`;
 | 
			
		||||
CREATE TABLE `t_db_restore` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `db_name` varchar(64) NOT NULL COMMENT '数据库名称',
 | 
			
		||||
    `repeated` tinyint(1) DEFAULT NULL COMMENT '是否重复执行',
 | 
			
		||||
    `interval` bigint(20) DEFAULT NULL COMMENT '恢复周期',
 | 
			
		||||
    `start_time` datetime DEFAULT NULL COMMENT '首次恢复时间',
 | 
			
		||||
    `enabled` tinyint(1) DEFAULT NULL COMMENT '是否启用',
 | 
			
		||||
    `last_status` tinyint(4) DEFAULT NULL COMMENT '上次恢复状态',
 | 
			
		||||
    `last_result` varchar(256) DEFAULT NULL COMMENT '上次恢复结果',
 | 
			
		||||
    `last_time` datetime DEFAULT NULL COMMENT '上次恢复时间',
 | 
			
		||||
    `point_in_time` datetime DEFAULT NULL COMMENT '恢复时间点',
 | 
			
		||||
    `db_backup_id` bigint(20) unsigned DEFAULT NULL COMMENT '备份ID',
 | 
			
		||||
    `db_backup_history_id` bigint(20) unsigned DEFAULT NULL COMMENT '历史备份ID',
 | 
			
		||||
    `db_backup_history_name` varchar(64) DEFAULT NULL COMMENT '历史备份名称',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `creator_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `creator` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `update_time` datetime DEFAULT NULL,
 | 
			
		||||
    `modifier_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `modifier` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_instane_id` (`db_instance_id`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_name` (`db_name`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=22 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_restore_history
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_restore_history`;
 | 
			
		||||
CREATE TABLE `t_db_restore_history` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_restore_id` bigint(20) unsigned NOT NULL COMMENT '恢复ID',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL COMMENT '历史恢复创建时间',
 | 
			
		||||
    `is_deleted` tinyint(4) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_restore_id` (`db_restore_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_binlog
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_binlog`;
 | 
			
		||||
CREATE TABLE `t_db_binlog` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `last_status` bigint(20) DEFAULT NULL COMMENT '上次下载状态',
 | 
			
		||||
    `last_result` varchar(256) DEFAULT NULL COMMENT '上次下载结果',
 | 
			
		||||
    `last_time` datetime DEFAULT NULL COMMENT '上次下载时间',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `creator_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `creator` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `update_time` datetime DEFAULT NULL,
 | 
			
		||||
    `modifier_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `modifier` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_binlog_history
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_binlog_history`;
 | 
			
		||||
CREATE TABLE `t_db_binlog_history` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `file_name` varchar(32) DEFAULT NULL COMMENT 'BINLOG文件名称',
 | 
			
		||||
    `file_size` bigint(20) DEFAULT NULL COMMENT 'BINLOG文件大小',
 | 
			
		||||
    `sequence` bigint(20) DEFAULT NULL COMMENT 'BINLOG序列号',
 | 
			
		||||
    `first_event_time` datetime DEFAULT NULL COMMENT '首次事件时间',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(4) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=17 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
DROP TABLE IF EXISTS `t_auth_cert`;
 | 
			
		||||
CREATE TABLE `t_auth_cert` (
 | 
			
		||||
@@ -169,12 +284,6 @@ CREATE TABLE `t_machine` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='机器信息';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_machine
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_machine_file
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -218,11 +327,6 @@ CREATE TABLE `t_machine_monitor` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_machine_monitor
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_machine_script
 | 
			
		||||
@@ -342,12 +446,6 @@ CREATE TABLE `t_mongo` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_mongo
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_redis
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -374,11 +472,6 @@ CREATE TABLE `t_redis` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='redis信息';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_redis
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
DROP TABLE IF EXISTS `t_oauth2_account`;
 | 
			
		||||
CREATE TABLE `t_oauth2_account` (
 | 
			
		||||
@@ -439,12 +532,6 @@ CREATE TABLE `t_sys_account_role` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=43 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='账号角色关联表';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_sys_account_role
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_sys_config
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -475,7 +562,7 @@ BEGIN;
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, create_time, creator_id, creator, update_time, modifier_id, modifier) VALUES('账号登录安全设置', 'AccountLoginSecurity', '[{"name":"登录验证码","model":"useCaptcha","placeholder":"是否启用登录验证码","options":"true,false"},{"name":"双因素校验(OTP)","model":"useOtp","placeholder":"是否启用双因素(OTP)校验","options":"true,false"},{"name":"OTP签发人","model":"otpIssuer","placeholder":"otp签发人"},{"name":"允许失败次数","model":"loginFailCount","placeholder":"登录失败n次后禁止登录"},{"name":"禁止登录时间","model":"loginFailMin","placeholder":"登录失败指定次数后禁止m分钟内再次登录"}]', '{"useCaptcha":"true","useOtp":"false","loginFailCount":"5","loginFailMin":"10","otpIssuer":"mayfly-go"}', '系统账号登录相关安全设置', '2023-06-17 11:02:11', 1, 'admin', '2023-06-17 14:18:07', 1, 'admin');
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, permission, create_time, creator_id, creator, update_time, modifier_id, modifier, is_deleted, delete_time) VALUES('oauth2登录配置', 'Oauth2Login', '[{"name":"是否启用","model":"enable","placeholder":"是否启用oauth2登录","options":"true,false"},{"name":"名称","model":"name","placeholder":"oauth2名称"},{"name":"Client ID","model":"clientId","placeholder":"Client ID"},{"name":"Client Secret","model":"clientSecret","placeholder":"Client Secret"},{"name":"Authorization URL","model":"authorizationURL","placeholder":"Authorization URL"},{"name":"AccessToken URL","model":"accessTokenURL","placeholder":"AccessToken URL"},{"name":"Redirect URL","model":"redirectURL","placeholder":"本系统地址"},{"name":"Scopes","model":"scopes","placeholder":"Scopes"},{"name":"Resource URL","model":"resourceURL","placeholder":"获取用户信息资源地址"},{"name":"UserIdentifier","model":"userIdentifier","placeholder":"用户唯一标识字段;格式为type:fieldPath(string:username)"},{"name":"是否自动注册","model":"autoRegister","placeholder":"","options":"true,false"}]', '', 'oauth2登录相关配置信息', 'admin,', '2023-07-22 13:58:51', 1, 'admin', '2023-07-22 19:34:37', 1, 'admin', 0, NULL);
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, permission, create_time, creator_id, creator, update_time, modifier_id, modifier, is_deleted, delete_time) VALUES('ldap登录配置', 'LdapLogin', '[{"name":"是否启用","model":"enable","placeholder":"是否启用","options":"true,false"},{"name":"host","model":"host","placeholder":"host"},{"name":"port","model":"port","placeholder":"port"},{"name":"bindDN","model":"bindDN","placeholder":"LDAP 服务的管理员账号,如: \\"cn=admin,dc=example,dc=com\\""},{"name":"bindPwd","model":"bindPwd","placeholder":"LDAP 服务的管理员密码"},{"name":"baseDN","model":"baseDN","placeholder":"用户所在的 base DN, 如: \\"ou=users,dc=example,dc=com\\""},{"name":"userFilter","model":"userFilter","placeholder":"过滤用户的方式, 如: \\"(uid=%s)、(&(objectClass=organizationalPerson)(uid=%s))\\""},{"name":"uidMap","model":"uidMap","placeholder":"用户id和 LDAP 字段名之间的映射关系,如: cn"},{"name":"udnMap","model":"udnMap","placeholder":"用户姓名(dispalyName)和 LDAP 字段名之间的映射关系,如: displayName"},{"name":"emailMap","model":"emailMap","placeholder":"用户email和 LDAP 字段名之间的映射关系"},{"name":"skipTLSVerify","model":"skipTLSVerify","placeholder":"客户端是否跳过 TLS 证书验证","options":"true,false"},{"name":"安全协议","model":"securityProtocol","placeholder":"安全协议(为Null不使用安全协议),如: StartTLS, LDAPS","options":"Null,StartTLS,LDAPS"}]', '', 'ldap登录相关配置', 'admin,', '2023-08-25 21:47:20', 1, 'admin', '2023-08-25 22:56:07', 1, 'admin', 0, NULL);
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, permission, create_time, creator_id, creator, update_time, modifier_id, modifier, is_deleted, delete_time) VALUES('是否启用水印', 'UseWatermark', '[{"name":"是否启用","model":"isUse","placeholder":"是否启用水印","options":"true,false"},{"name":"自定义信息","model":"content","placeholder":"额外添加的水印内容,可添加公司名称等"}]', '', '水印信息配置', 'all', '2022-08-25 23:36:35', 1, 'admin', '2022-08-26 10:02:52', 1, 'admin', 0, NULL);
 | 
			
		||||
INSERT INTO `t_sys_config` (`name`, `key`, `params`, `value`, `remark`, `permission`, `create_time`, `creator_id`, `creator`, `update_time`, `modifier_id`, `modifier`, `is_deleted`, `delete_time`) VALUES('系统全局样式设置', 'SysStyleConfig', '[{"model":"logoIcon","name":"logo图标","placeholder":"系统logo图标(base64编码, 建议svg格式,不超过10k)","required":false},{"model":"title","name":"菜单栏标题","placeholder":"系统菜单栏标题展示","required":false},{"model":"viceTitle","name":"登录页标题","placeholder":"登录页标题展示","required":false},{"model":"useWatermark","name":"是否启用水印","placeholder":"是否启用系统水印","options":"true,false","required":false},{"model":"watermarkContent","name":"水印补充信息","placeholder":"额外水印信息","required":false}]', '{"title":"mayfly-go","viceTitle":"mayfly-go","logoIcon":"","useWatermark":"true","watermarkContent":""}', '系统icon、标题、水印信息等配置', 'all', '2024-01-04 15:17:18', 1, 'admin', '2024-01-05 09:40:44', 1, 'admin', 0, NULL);
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, create_time, creator_id, creator, update_time, modifier_id, modifier)VALUES ('数据库查询最大结果集', 'DbQueryMaxCount', '[]', '200', '允许sql查询的最大结果集数。注: 0=不限制', '2023-02-11 14:29:03', 1, 'admin', '2023-02-11 14:40:56', 1, 'admin');
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, create_time, creator_id, creator, update_time, modifier_id, modifier)VALUES ('数据库是否记录查询SQL', 'DbSaveQuerySQL', '[]', '0', '1: 记录、0:不记录', '2023-02-11 16:07:14', 1, 'admin', '2023-02-11 16:44:17', 1, 'admin');
 | 
			
		||||
INSERT INTO `t_sys_config` (name, `key`, params, value, remark, permission, create_time, creator_id, creator, update_time, modifier_id, modifier, is_deleted, delete_time) VALUES('机器相关配置', 'MachineConfig', '[{"name":"终端回放存储路径","model":"terminalRecPath","placeholder":"终端回放存储路径"},{"name":"uploadMaxFileSize","model":"uploadMaxFileSize","placeholder":"允许上传的最大文件大小(1MB\\\\2GB等)"}]', '{"terminalRecPath":"./rec","uploadMaxFileSize":"1GB"}', '机器相关配置,如终端回放路径等', 'admin,', '2023-07-13 16:26:44', 1, 'admin', '2023-11-09 22:01:31', 1, 'admin', 0, NULL);
 | 
			
		||||
@@ -502,12 +589,6 @@ CREATE TABLE `t_sys_log` (
 | 
			
		||||
  KEY `idx_creator_id` (`creator_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=58 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='系统操作日志';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_sys_log
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_sys_msg
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -525,12 +606,6 @@ CREATE TABLE `t_sys_msg` (
 | 
			
		||||
  PRIMARY KEY (`id`)
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=91 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin COMMENT='系统消息表';
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Records of t_sys_msg
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
BEGIN;
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_sys_resource
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
@@ -854,142 +929,4 @@ BEGIN;
 | 
			
		||||
INSERT INTO `t_team_member` VALUES (7, 3, 1, 'admin', '2022-10-26 20:04:36', 1, 'admin', '2022-10-26 20:04:36', 1, 'admin', 0, NULL);
 | 
			
		||||
COMMIT;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_backup
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_backup`;
 | 
			
		||||
CREATE TABLE `t_db_backup` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `name` varchar(32) NOT NULL COMMENT '备份名称',
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `db_name` varchar(64) NOT NULL COMMENT '数据库名称',
 | 
			
		||||
    `repeated` tinyint(1) DEFAULT NULL COMMENT '是否重复执行',
 | 
			
		||||
    `interval` bigint(20) DEFAULT NULL COMMENT '备份周期',
 | 
			
		||||
    `start_time` datetime DEFAULT NULL COMMENT '首次备份时间',
 | 
			
		||||
    `enabled` tinyint(1) DEFAULT NULL COMMENT '是否启用',
 | 
			
		||||
    `last_status` tinyint(4) DEFAULT NULL COMMENT '上次备份状态',
 | 
			
		||||
    `last_result` varchar(256) DEFAULT NULL COMMENT '上次备份结果',
 | 
			
		||||
    `last_time` datetime DEFAULT NULL COMMENT '上次备份时间',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `creator_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `creator` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `update_time` datetime DEFAULT NULL,
 | 
			
		||||
    `modifier_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `modifier` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_name` (`db_name`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_backup_history
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_backup_history`;
 | 
			
		||||
CREATE TABLE `t_db_backup_history` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `name` varchar(64) NOT NULL COMMENT '历史备份名称',
 | 
			
		||||
    `db_backup_id` bigint(20) unsigned NOT NULL COMMENT '数据库备份ID',
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `db_name` varchar(64) NOT NULL COMMENT '数据库名称',
 | 
			
		||||
    `uuid` varchar(36) NOT NULL COMMENT '历史备份uuid',
 | 
			
		||||
    `binlog_file_name` varchar(32) DEFAULT NULL COMMENT 'BINLOG文件名',
 | 
			
		||||
    `binlog_sequence` bigint(20) DEFAULT NULL COMMENT 'BINLOG序列号',
 | 
			
		||||
    `binlog_position` bigint(20) DEFAULT NULL COMMENT 'BINLOG位置',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL COMMENT '历史备份创建时间',
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_backup_id` (`db_backup_id`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_name` (`db_name`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_restore
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_restore`;
 | 
			
		||||
CREATE TABLE `t_db_restore` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `db_name` varchar(64) NOT NULL COMMENT '数据库名称',
 | 
			
		||||
    `repeated` tinyint(1) DEFAULT NULL COMMENT '是否重复执行',
 | 
			
		||||
    `interval` bigint(20) DEFAULT NULL COMMENT '恢复周期',
 | 
			
		||||
    `start_time` datetime DEFAULT NULL COMMENT '首次恢复时间',
 | 
			
		||||
    `enabled` tinyint(1) DEFAULT NULL COMMENT '是否启用',
 | 
			
		||||
    `last_status` tinyint(4) DEFAULT NULL COMMENT '上次恢复状态',
 | 
			
		||||
    `last_result` varchar(256) DEFAULT NULL COMMENT '上次恢复结果',
 | 
			
		||||
    `last_time` datetime DEFAULT NULL COMMENT '上次恢复时间',
 | 
			
		||||
    `point_in_time` datetime DEFAULT NULL COMMENT '恢复时间点',
 | 
			
		||||
    `db_backup_id` bigint(20) unsigned DEFAULT NULL COMMENT '备份ID',
 | 
			
		||||
    `db_backup_history_id` bigint(20) unsigned DEFAULT NULL COMMENT '历史备份ID',
 | 
			
		||||
    `db_backup_history_name` varchar(64) DEFAULT NULL COMMENT '历史备份名称',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `creator_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `creator` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `update_time` datetime DEFAULT NULL,
 | 
			
		||||
    `modifier_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `modifier` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_instane_id` (`db_instance_id`) USING BTREE,
 | 
			
		||||
    KEY `idx_db_name` (`db_name`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=22 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_restore_history
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_restore_history`;
 | 
			
		||||
CREATE TABLE `t_db_restore_history` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_restore_id` bigint(20) unsigned NOT NULL COMMENT '恢复ID',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL COMMENT '历史恢复创建时间',
 | 
			
		||||
    `is_deleted` tinyint(4) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_restore_id` (`db_restore_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_binlog
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_binlog`;
 | 
			
		||||
CREATE TABLE `t_db_binlog` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `last_status` bigint(20) DEFAULT NULL COMMENT '上次下载状态',
 | 
			
		||||
    `last_result` varchar(256) DEFAULT NULL COMMENT '上次下载结果',
 | 
			
		||||
    `last_time` datetime DEFAULT NULL COMMENT '上次下载时间',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `creator_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `creator` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `update_time` datetime DEFAULT NULL,
 | 
			
		||||
    `modifier_id` bigint(20) unsigned DEFAULT NULL,
 | 
			
		||||
    `modifier` varchar(32) DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(1) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
-- Table structure for t_db_binlog_history
 | 
			
		||||
-- ----------------------------
 | 
			
		||||
DROP TABLE IF EXISTS `t_db_binlog_history`;
 | 
			
		||||
CREATE TABLE `t_db_binlog_history` (
 | 
			
		||||
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
 | 
			
		||||
    `db_instance_id` bigint(20) unsigned NOT NULL COMMENT '数据库实例ID',
 | 
			
		||||
    `file_name` varchar(32) DEFAULT NULL COMMENT 'BINLOG文件名称',
 | 
			
		||||
    `file_size` bigint(20) DEFAULT NULL COMMENT 'BINLOG文件大小',
 | 
			
		||||
    `sequence` bigint(20) DEFAULT NULL COMMENT 'BINLOG序列号',
 | 
			
		||||
    `first_event_time` datetime DEFAULT NULL COMMENT '首次事件时间',
 | 
			
		||||
    `create_time` datetime DEFAULT NULL,
 | 
			
		||||
    `is_deleted` tinyint(4) NOT NULL DEFAULT 0,
 | 
			
		||||
    `delete_time` datetime DEFAULT NULL,
 | 
			
		||||
    PRIMARY KEY (`id`),
 | 
			
		||||
    KEY `idx_db_instance_id` (`db_instance_id`) USING BTREE
 | 
			
		||||
) ENGINE=InnoDB AUTO_INCREMENT=17 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
 | 
			
		||||
 | 
			
		||||
SET FOREIGN_KEY_CHECKS = 1;
 | 
			
		||||
@@ -139,3 +139,5 @@ CREATE TABLE `t_db_binlog_history` (
 | 
			
		||||
 | 
			
		||||
INSERT INTO `t_sys_config` (`name`, `key`, `params`, `value`, `remark`, `permission`, `create_time`, `creator_id`, `creator`, `update_time`, `modifier_id`, `modifier`, `is_deleted`, `delete_time`) VALUES('Mysql可执行文件', 'MysqlBin', '[{"model":"path","name":"路径","placeholder":"可执行文件路径","required":true},{"model":"mysql","name":"mysql","placeholder":"mysql命令路径(空则为 路径/mysql)","required":false},{"model":"mysqldump","name":"mysqldump","placeholder":"mysqldump命令路径(空则为 路径/mysqldump)","required":false},{"model":"mysqlbinlog","name":"mysqlbinlog","placeholder":"mysqlbinlog命令路径(空则为 路径/mysqlbinlog)","required":false}]', '{"mysql":"","mysqldump":"","mysqlbinlog":"","path":""}', '', 'admin,', '2023-12-29 10:01:33', 1, 'admin', '2023-12-29 13:34:40', 1, 'admin', 0, NULL);
 | 
			
		||||
INSERT INTO `t_sys_config` (`name`, `key`, `params`, `value`, `remark`, `permission`, `create_time`, `creator_id`, `creator`, `update_time`, `modifier_id`, `modifier`, `is_deleted`, `delete_time`) VALUES('数据库备份恢复', 'DbBackupRestore', '[{"model":"backupPath","name":"备份路径","placeholder":"备份文件存储路径"}]', '{"backupPath":"./db/backup"}', '', 'admin,', '2023-12-29 09:55:26', 1, 'admin', '2023-12-29 15:45:24', 1, 'admin', 0, NULL);
 | 
			
		||||
DELETE FROM `t_sys_config` WHERE `key` = 'UseWatermark'
 | 
			
		||||
INSERT INTO `t_sys_config` (`name`, `key`, `params`, `value`, `remark`, `permission`, `create_time`, `creator_id`, `creator`, `update_time`, `modifier_id`, `modifier`, `is_deleted`, `delete_time`) VALUES('系统全局样式设置', 'SysStyleConfig', '[{"model":"logoIcon","name":"logo图标","placeholder":"系统logo图标(base64编码, 建议svg格式,不超过10k)","required":false},{"model":"title","name":"菜单栏标题","placeholder":"系统菜单栏标题展示","required":false},{"model":"viceTitle","name":"登录页标题","placeholder":"登录页标题展示","required":false},{"model":"useWatermark","name":"是否启用水印","placeholder":"是否启用系统水印","options":"true,false","required":false},{"model":"watermarkContent","name":"水印补充信息","placeholder":"额外水印信息","required":false}]', '{"title":"mayfly-go","viceTitle":"mayfly-go","logoIcon":"","useWatermark":"true","watermarkContent":""}', '系统icon、标题、水印信息等配置', 'all', '2024-01-04 15:17:18', 1, 'admin', '2024-01-05 09:40:44', 1, 'admin', 0, NULL);
 | 
			
		||||
		Reference in New Issue
	
	Block a user