feat: 新增思想实验室模块与配套功能
- 新增5个物理仿真实验室:黑洞模拟、日地轨道、3D太阳系、π推导、拉格朗日点 - 新增思想实验室后端路由与鉴权逻辑 - 首页新增思想实验室页签与前端渲染逻辑 - 修复中韩半导体监控标的配置错误 - 新增市场技能推送白名单过滤逻辑与单元测试
This commit is contained in:
@@ -83,6 +83,7 @@ const boxBackup = require('./box_backup')
|
||||
const yuanzhupai = require('./yuanzhupai')
|
||||
const shortLink = require('./short_link')
|
||||
const dataGateway = require('./data_gateway')
|
||||
const thoughtLab = require('./thought_lab')
|
||||
const ossFileCabinet = require('./oss_file_cabinet')
|
||||
yuanzhupai.initDb()
|
||||
|
||||
@@ -6495,6 +6496,16 @@ app.use('/tools/investment_ledger', (req, res, next) => {
|
||||
} catch { return res.status(401).send('未授权') }
|
||||
})
|
||||
|
||||
// ============================================================
|
||||
// 思想实验室:纯导航鉴权(nav_gate)+ lab 静态资源 + lab 列表 API
|
||||
// 必须注册在下方全局 express.static 之前,否则静态资源会绕过鉴权中间件
|
||||
// ============================================================
|
||||
try {
|
||||
thoughtLab.bindRoutes(app)
|
||||
} catch (e) {
|
||||
try { logJSON('thought_lab.bind_routes.error', { error: String(e.message || e) }, 'thought_lab') } catch {}
|
||||
}
|
||||
|
||||
app.get(['/package.json', '/package-lock.json', '/pnpm-lock.yaml', '/yarn.lock', '/robots.txt'], (_req, res) => {
|
||||
res.status(404).send('Not Found')
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user