✨ feat(加入热更和eval的管理模块):

This commit is contained in:
liangtongchuan
2023-05-05 15:42:17 +08:00
committed by luying
parent a362a397b5
commit 3a41136722
4 changed files with 176 additions and 0 deletions
+8
View File
@@ -37,6 +37,10 @@ import { setGVGConfig } from './app/services/gvg/gvgService';
import { isDevelopEnv } from './app/services/utilService';
import { initTeamToMem } from './app/services/gvg/gvgBattleService';
import { setServerGroup } from './app/services/serverService';
// 管理相关模块
import { UpdateComponent } from './app/components/UpdateComponent';
import { EvalComponent } from './app/components/EvalComponent';
import { UsrAdminModule } from './app/modules/UsrAdmin';
const filePath = (_pinus as any).FILEPATH;
filePath.MASTER = '/config/master';
@@ -103,6 +107,9 @@ app.configure(function () {
'reloadHandlers': true,
'reloadRemotes': true,
});
app.load(UpdateComponent, { app: app });
app.load(EvalComponent, { app: app });
});
// 对所有 env 的 个别 serverType 进行配置
@@ -155,6 +162,7 @@ app.configure(ALL_ENVS, 'gm', function () {
app.filter(tokenFilter(app));
});
app.registerAdmin(UsrAdminModule, {app: app});
function errorHandler(err: Error, msg: any, resp: any,
session: FrontendOrBackendSession, cb: HandlerCallback) {