feat: M3-M7 全模块落地 + 集成接线
- M3 认证/权限/审计/限流 + 全部 REST 接口 - M4 管理面板(MIUIx + 成绩录入/积分榜下钻/大屏控制) - M5a 大屏页面(六页 + 明细覆盖层 + 缩放适配) - M6 WebSocket 实时同步中心 - M7 xlsx 导出 + 赛事包 zip + 备份 - 规则包 YAML 导入导出(差异预览) - 字体 vendor 子集化(4 套 x2 字重) - 集成:realtime/export/rules 接入 main+httpapi;backup 子命令 - 修复:中间件包装 ResponseWriter 丢失 Hijacker,导致 WS 握手 501
This commit is contained in:
1 parent
d0e3b93e76
commit
bc8b1ee6c0
145 files changed
+25159
-321
No files matched your search
@@ -0,0 +1,106 @@
|
||||
import { createRouter, createWebHashHistory, type RouteRecordRaw } from 'vue-router'
|
||||
import AdminLayout from './layouts/AdminLayout.vue'
|
||||
|
||||
/**
|
||||
* 路由表。占位页统一走 PlaceholderPage,避免为每个未实现页面各写一个空组件。
|
||||
*/
|
||||
const routes: RouteRecordRaw[] = [
|
||||
{
|
||||
path: '/login',
|
||||
name: 'login',
|
||||
component: () => import('./pages/LoginPage.vue'),
|
||||
meta: { title: '登录' },
|
||||
},
|
||||
{
|
||||
path: '/',
|
||||
component: AdminLayout,
|
||||
children: [
|
||||
{ path: '', redirect: { name: 'dashboard' } },
|
||||
{
|
||||
path: 'dashboard',
|
||||
name: 'dashboard',
|
||||
component: () => import('./pages/DashboardPage.vue'),
|
||||
meta: { title: '仪表盘' },
|
||||
},
|
||||
{
|
||||
path: 'entry',
|
||||
name: 'entry',
|
||||
component: () => import('./pages/EntryPage.vue'),
|
||||
meta: { title: '成绩录入' },
|
||||
},
|
||||
{
|
||||
path: 'review',
|
||||
name: 'review',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '成绩审核', note: '草稿列表 → 对比 → 发布 / 退回' },
|
||||
},
|
||||
{
|
||||
path: 'records',
|
||||
name: 'records',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '破纪录', note: '疑似破纪录列表 → 确认 → 加分' },
|
||||
},
|
||||
{
|
||||
path: 'adjustments',
|
||||
name: 'adjustments',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '积分调整', note: '人工加减分(必填理由),本期规则关闭' },
|
||||
},
|
||||
{
|
||||
path: 'standings',
|
||||
name: 'standings',
|
||||
component: () => import('./pages/StandingsPage.vue'),
|
||||
meta: { title: '积分榜' },
|
||||
},
|
||||
{
|
||||
path: 'display',
|
||||
name: 'display',
|
||||
component: () => import('./pages/DisplayPage.vue'),
|
||||
meta: { title: '大屏控制' },
|
||||
},
|
||||
{
|
||||
path: 'base-data',
|
||||
name: 'base-data',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '基础数据', note: '单位 / 大项 / 小项 / 积分模板 / 运动员 / 报名导入' },
|
||||
},
|
||||
{
|
||||
path: 'export',
|
||||
name: 'export',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '导出', note: '积分榜 / 明细 / 成绩册 / 赛事项目包' },
|
||||
},
|
||||
{
|
||||
path: 'history',
|
||||
name: 'history',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '变更历史', note: '仿 Git Graph 的操作图谱(只读)' },
|
||||
},
|
||||
{
|
||||
path: 'logs',
|
||||
name: 'logs',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '日志', note: '审计日志:谁在什么时候改了什么' },
|
||||
},
|
||||
{
|
||||
path: 'system',
|
||||
name: 'system',
|
||||
component: () => import('./pages/PlaceholderPage.vue'),
|
||||
meta: { title: '系统', note: '用户管理 / 备份恢复 / 赛事信息' },
|
||||
},
|
||||
],
|
||||
},
|
||||
{ path: '/:pathMatch(.*)*', redirect: { name: 'dashboard' } },
|
||||
]
|
||||
|
||||
export const router = createRouter({
|
||||
// 服务端只在 /admin 精确路径返回 admin.html(见 httpapi/server.go 静态路由),
|
||||
// 用 hash 模式才能让刷新 / 深链(#/entry?eventId=101)不落到 404。
|
||||
history: createWebHashHistory(),
|
||||
routes,
|
||||
})
|
||||
|
||||
router.afterEach((to) => {
|
||||
const title = typeof to.meta.title === 'string' ? to.meta.title : ''
|
||||
document.title = title === '' ? '管理面板' : `${title} · 管理面板`
|
||||
})
|
||||
Reference in new issue
Block a user