feat(fsgx): 管理后台与部署相关更新

- admin: 路由守卫修复空白页、addRoute、devServer 端口与代理
- admin: package.json 生产构建去掉 NODE_OPTIONS openssl
- ajcaptcha: 滑块验证码改用 file 缓存避免 Redis NOAUTH
- nginx-crmeb: 增加 81 端口站点
- docs: deploy 补充 NOAUTH/Redis 说明,新增 H5 部署脚本与 nginx 示例
- 其他: database、start-api、swoole ini、uniapp 资源等

Made-with: Cursor
This commit is contained in:
apple
2026-03-21 02:33:14 +08:00
parent 413eb19adf
commit ae8b866319
20 changed files with 697 additions and 45 deletions

View File

@@ -5,6 +5,6 @@ VUE_APP_ENV='production'
# 页面 title
VUE_APP_TITLE=CRMEB
# socket 系统连接地址 (ws)或(wss)://www.crmeb.com(换成你的域名)/ws 非独立部署默认为空
VUE_APP_WS_ADMIN_URL='ws://hjf.suzhouyuqi.com/ws'
VUE_APP_WS_ADMIN_URL='ws://fsgx.uj345.com/ws'
# 接口请求地址 (http)或 (https)://www.crmeb.com(换成你的域名)/adminapi 非独立部署默认为空
VUE_APP_API_URL='http://hjf.suzhouyuqi.com/adminapi'
VUE_APP_API_URL='http://fsgx.uj345.com/adminapi'

View File

@@ -5,7 +5,7 @@
"scripts": {
"serve": "node src/libs/start.js && vue-cli-service serve --open --mode=dev",
"dev": "node src/libs/start.js && vue-cli-service serve --open --mode=dev",
"build": "cross-env NODE_OPTIONS=--openssl-legacy-provider vue-cli-service build --mode=production"
"build": "vue-cli-service build --mode=production"
},
"dependencies": {
"@babel/polyfill": "^7.12.1",

View File

@@ -79,7 +79,7 @@ const router = new VueRouter({
routes: [...routes],
mode: Setting.routerMode,
});
router.addRoutes(supplierRoutes);
supplierRoutes.forEach((route) => router.addRoute(route));
setTimeout(() => {
console.log(router, "11");
}, 1000);
@@ -140,6 +140,8 @@ function handlePublicRoute(to, next) {
if (hasMenus || isLoginPage) {
return next();
}
// 无菜单且非登录页时,重定向到登录页(修复空白页:此前未调用 next() 导致导航挂起)
next({ path: `${Setting.roterPre}/login`, query: { redirect: to.fullPath } });
}
router.afterEach((to) => {
// if (Setting.showProgressBar) iView.LoadingBar.finish();

View File

@@ -27,11 +27,11 @@ module.exports = {
productionSourceMap: false, //关闭生产环境下的SourceMap映射文件
devServer: {
publicPath: Setting.publicPath,
port: 8080,
port: 8085,
proxy: {
'/adminapi': { target: 'http://127.0.0.1:20199', changeOrigin: true },
'/api': { target: 'http://127.0.0.1:20199', changeOrigin: true },
'/kefuapi': { target: 'http://127.0.0.1:20199', changeOrigin: true },
'/adminapi': { target: process.env.VUE_APP_API_URL ? new URL(process.env.VUE_APP_API_URL).origin : 'http://127.0.0.1:20199', changeOrigin: true },
'/api': { target: process.env.VUE_APP_API_URL ? new URL(process.env.VUE_APP_API_URL).origin : 'http://127.0.0.1:20199', changeOrigin: true },
'/kefuapi': { target: process.env.VUE_APP_API_URL ? new URL(process.env.VUE_APP_API_URL).origin : 'http://127.0.0.1:20199', changeOrigin: true },
},
},