diff --git a/src/renderer/src/api/file/index.js b/src/renderer/src/api/file/index.js index f5da5e8..b5228b5 100644 --- a/src/renderer/src/api/file/index.js +++ b/src/renderer/src/api/file/index.js @@ -95,7 +95,7 @@ export const addFileToSC = (params) => { params }) } - +//EOS生成表单上传的签名 export const createSignature = (data) => { return request({ url: '/eos/createSignature', @@ -103,7 +103,7 @@ export const createSignature = (data) => { data }) } - +//EOS生成本地上传的临时签名 export const sessionToken = () => { return request({ url: '/eos/sessionToken', diff --git a/src/renderer/src/main.js b/src/renderer/src/main.js index 16f16ec..11bbad5 100644 --- a/src/renderer/src/main.js +++ b/src/renderer/src/main.js @@ -27,8 +27,8 @@ import customComponent from '@/components/common' // 自定义组件 import plugins from './plugins' // plugins插件 import useUserStore from '@/store/modules/user' import aiAudio from 'aix-plugins-aitools' // 文字转语音插件 -import '../../../node_modules/aix-plugins-aitools/aitools.css' - +import '../../../node_modules/aix-plugins-aitools/aitools.css' + if(process.env.NODE_ENV != 'development') { // 非开发环境,将日志打印到日志文件 Object.assign(console, log.functions) // 渲染进程日志-控制台替换 @@ -55,6 +55,20 @@ VMdPreview.use(githubTheme, { Hljs: hljs, }); +(function () { + if (!['development', 'mock'].includes(process.env.NODE_ENV)&&import.meta.env.VITE_SHOW_DEV_TOOLS==='true') { + ['log', 'warn', 'error', 'info'].forEach((item) => { + console[item] = (function (func) { + const res = localStorage.getItem('debug'); + if (res === 'GMV_desk') { + return func; + } + return function () {}; + })(console[item]); + }); + } +})() + app.use(router) .use(store) .use(ElementPlus, { locale: zhLocale })