2020-04-17 09:13:40 +08:00
|
|
|
import Vue from 'vue';
|
2019-07-04 10:59:40 +08:00
|
|
|
import Router from 'vue-router';
|
2019-11-13 09:06:57 +08:00
|
|
|
// import VueRouter from 'vue-router';
|
2019-07-02 16:29:52 +08:00
|
|
|
|
2020-04-17 09:13:40 +08:00
|
|
|
Vue.use(Router);
|
2019-07-02 16:29:52 +08:00
|
|
|
|
|
|
|
/* Layout */
|
2019-11-12 17:20:23 +08:00
|
|
|
const Layout = () => import('@/layout');
|
|
|
|
const Login = () => import('@/views/login/index');
|
|
|
|
|
|
|
|
const Jlmap3dedit = () => import('@/views/jlmap3d/edit/jlmap3dedit');
|
2020-06-23 10:07:52 +08:00
|
|
|
const Jlmap3dAssetManager = () => import('@/views/jlmap3d/jl3dassetmanager/assetmanager');
|
2019-11-12 17:20:23 +08:00
|
|
|
const Jlmap3d = () => import('@/views/jlmap3d/drive/jl3ddrive');
|
2019-12-03 13:48:15 +08:00
|
|
|
const Jlmap3dSandbox = () => import('@/views/jlmap3d/simulation/jl3dsimulation');
|
2020-02-14 18:22:11 +08:00
|
|
|
const Jlmap3dPassFlow = () => import('@/views/jlmap3d/passflow/jl3dpassflow');
|
2019-12-11 10:47:24 +08:00
|
|
|
const Jlmap3dModel = () => import('@/views/jlmap3d/device/jl3ddevice');
|
|
|
|
const Jlmap3dTrain = () => import('@/views/jlmap3d/devicetrain/jl3ddevicetrain');
|
2020-08-13 15:55:25 +08:00
|
|
|
const Jlmap3dMaintainer = () => import('@/views/jlmap3d/maintainer/jl3dmaintainer');
|
2020-07-30 15:08:17 +08:00
|
|
|
const Jlmap3dMaintainerVr = () => import('@/views/jlmap3d/maintainer/jl3dmaintainervr');
|
2020-09-23 16:20:50 +08:00
|
|
|
const Jl3dTrainRescueVr = () => import('@/views/jlmap3d/maintainer/jl3dTrainRescueVr')
|
2020-08-26 13:54:44 +08:00
|
|
|
const Jlmap3dOtherVR = () => import('@/views/jlmap3d/maintainer/jl3dothervr');
|
2020-05-21 15:51:56 +08:00
|
|
|
// const Jl3dMaintainer = () => import('@/views/jlmap3d/maintainer/jl3dmaintainer');
|
2020-05-19 16:49:56 +08:00
|
|
|
|
2020-07-30 17:49:20 +08:00
|
|
|
const Display = () => import('@/views/oldMap/display/index');
|
2019-12-30 09:00:16 +08:00
|
|
|
const DisplayNew = () => import('@/views/newMap/displayNew/index');
|
2020-07-30 17:49:20 +08:00
|
|
|
const DesignDisplay = () => import('@/views/oldMap/display/designIndex');
|
2020-08-18 16:29:23 +08:00
|
|
|
const DesignDisplayNew = () => import('@/views/newMap/displayNew/scriptDisplay/scriptPreview/index');
|
2019-11-12 17:20:23 +08:00
|
|
|
|
|
|
|
const TrainRoom = () => import('@/views/trainRoom/index');
|
2020-07-30 17:49:20 +08:00
|
|
|
const JointTraining = () => import('@/views/oldMap/jointTraining/index');
|
2020-03-17 14:54:03 +08:00
|
|
|
const JointTrainingNew = () => import('@/views/newMap/jointTrainingNew/index');
|
2019-11-12 17:20:23 +08:00
|
|
|
|
|
|
|
const Errpr404 = () => import('@/views/error-page/404');
|
|
|
|
|
|
|
|
const Dictionary = () => import('@/views/system/dictionary/index');
|
|
|
|
const DictionaryDetail = () => import('@/views/system/dictionaryDetail/index');
|
|
|
|
const UserControl = () => import('@/views/system/userControl/index');
|
|
|
|
const UserTraining = () => import('@/views/system/userTraining/index');
|
|
|
|
const UserExam = () => import('@/views/system/userExam/index');
|
|
|
|
const UserSimulation = () => import('@/views/system/userSimulation/index');
|
|
|
|
const ExistingSimulation = () => import('@/views/system/existingSimulation/index');
|
|
|
|
const CacheControl = () => import('@/views/system/cacheControl/index');
|
|
|
|
const SystemGenerate = () => import('@/views/system/systemGenerate/index');
|
2019-11-14 14:10:20 +08:00
|
|
|
const News = () => import('@/views/system/news/index');
|
2019-11-15 16:31:48 +08:00
|
|
|
const CommandDictionary = () => import('@/views/system/commandDictionary/index');
|
2019-11-18 14:29:43 +08:00
|
|
|
const CommandDictionaryDetail = () => import('@/views/system/commandDictionary/edit');
|
2019-12-19 18:04:28 +08:00
|
|
|
const configLine = () => import('@/views/system/configLine/index');
|
2020-09-09 11:25:31 +08:00
|
|
|
const Notification = () => import('@/views/system/notification/index');
|
2019-11-12 17:20:23 +08:00
|
|
|
|
2020-01-20 09:20:09 +08:00
|
|
|
const IscsSystem = () => import('@/views/iscs/iscsSystem/index');
|
|
|
|
const IscsDraw = () => import('@/views/iscs/iscsDraw/index');
|
|
|
|
const IscsDesign = () => import('@/views/iscs/iscsDesign/index');
|
|
|
|
const IscsConfig = () => import('@/views/iscs/iscsSystem/config/index');
|
2020-09-22 11:31:18 +08:00
|
|
|
const IscsStationConfig = () => import('@/views/iscs/iscsSystem/stationConfig/index');
|
2020-01-20 09:20:09 +08:00
|
|
|
|
2019-11-29 12:51:58 +08:00
|
|
|
const NewMapDraft = () => import('@/views/newMap/newMapdraft/index');
|
|
|
|
const NewDesignPlatformUser = () => import('@/views/newMap/newDesignUser/index');
|
|
|
|
|
2019-11-12 17:20:23 +08:00
|
|
|
const Taskmanage = () => import('@/views/lesson/taskmanage/list');
|
|
|
|
const TrainingRuleList = () => import('@/views/lesson/trainingRule/list');
|
|
|
|
const TrainingRuleEdit = () => import('@/views/lesson/trainingRule/detail/index');
|
|
|
|
const Trainingmanage = () => import('@/views/lesson/trainingmanage/index');
|
2020-04-09 16:11:36 +08:00
|
|
|
const TrainingmanageOld = () => import('@/views/lesson/trainingmanage/oldMap');
|
2019-11-12 17:20:23 +08:00
|
|
|
const LessonEdit = () => import('@/views/lesson/lessoncategory/index');
|
|
|
|
const LessonHome = () => import('@/views/lesson/home');
|
|
|
|
const LessonDetail = () => import('@/views/lesson/details');
|
|
|
|
|
|
|
|
const ScriptmanageHome = () => import('@/views/scriptManage/home');
|
2020-08-03 09:18:27 +08:00
|
|
|
const ScriptDisplay = () => import('@/views/oldMap/scriptManage/display/index');
|
2020-05-27 09:56:59 +08:00
|
|
|
const PracticeDisplayNew = () => import('@/views/competitionManage/practiceList/display/index');
|
2019-11-12 17:20:23 +08:00
|
|
|
|
2020-03-13 18:19:04 +08:00
|
|
|
const IbpHome = () => import('@/views/ibp/home');
|
2020-03-16 11:02:33 +08:00
|
|
|
const IbpDraw = () => import('@/views/ibp/ibpDraw/index');
|
2020-09-16 10:10:13 +08:00
|
|
|
const IbpShow = () => import('@/views/ibp/ibpsystem/index');
|
2020-03-13 18:19:04 +08:00
|
|
|
|
2019-11-12 17:20:23 +08:00
|
|
|
const TeachDetail = () => import('@/views/teach/detail/index');
|
|
|
|
const TeachHome = () => import('@/views/teach/index');
|
|
|
|
const Pay = () => import('@/views/components/pay/index');
|
|
|
|
|
|
|
|
const ExamHome = () => import('@/views/exam/index');
|
|
|
|
const ExamResult = () => import('@/views/exam/result');
|
|
|
|
const ExamDetail = () => import('@/views/exam/detail/examDetail');
|
|
|
|
const ExamCourseDetail = () => import('@/views/exam/detail/courseDetail');
|
|
|
|
|
|
|
|
const DemonstrationDetail = () => import('@/views/demonstration/detail/index');
|
|
|
|
|
|
|
|
const PlanMonitorEditTool = () => import('@/views/planMonitor/editTool/index');
|
|
|
|
const PlanMonitorEditUserTool = () => import('@/views/planMonitor/editTool/userindex');
|
|
|
|
const PlanMonitorDetail = () => import('@/views/planMonitor/detail');
|
|
|
|
|
|
|
|
const DesignPlatformHome = () => import('@/views/designPlatform/home');
|
|
|
|
const DesignPlatform = () => import('@/views/designPlatform/index');
|
|
|
|
const MapPreview = () => import('@/views/designPlatform/mapPreview');
|
2019-12-23 10:36:32 +08:00
|
|
|
const MapPreviewNew = () => import('@/views/designPlatform/mapPreviewNew');
|
2020-05-06 16:57:07 +08:00
|
|
|
const BigScreen = () => import('@/views/designPlatform/bigScreen');
|
2020-07-06 17:02:13 +08:00
|
|
|
const BigSplitScreen = () => import('@/views/designPlatform/bigSplitScreen');
|
2019-11-12 17:20:23 +08:00
|
|
|
|
2020-05-15 14:50:05 +08:00
|
|
|
// const DesignPlatformUser = () => import('@/views/designUser/index');
|
2019-11-12 17:20:23 +08:00
|
|
|
|
|
|
|
const Package = () => import('@/views/package/index');
|
|
|
|
|
|
|
|
const PublishMap = () => import('@/views/publish/publishMap/index');
|
|
|
|
const PublishMapDetail = () => import('@/views/publish/publishMap/list'); // 发布历史
|
|
|
|
const PublishLesson = () => import('@/views/publish/publishLesson/index');
|
|
|
|
const RunPlanTemplate = () => import('@/views/publish/runPlanTemplate/index');
|
|
|
|
const RunPlanCommon = () => import('@/views/publish/runPlanCommon/index');
|
|
|
|
const RunPlanCommonDraft = () => import('@/views/publish/runPlanCommon/draft');
|
|
|
|
const RunPlanEveryDay = () => import('@/views/publish/runPlanEveryDay/index');
|
|
|
|
const RunplanView = () => import('@/views/publish/runPlanEveryDay/runPlanView');
|
|
|
|
const PublishExamRule = () => import('@/views/publish/examRule/index');
|
|
|
|
const PublishExamRuleDraft = () => import('@/views/publish/examRule/draft/index');
|
|
|
|
|
|
|
|
const TrainingPlatform = () => import('@/views/trainingPlatform/index');
|
|
|
|
|
|
|
|
const Commodity = () => import('@/views/orderauthor/commodity/index');
|
|
|
|
const OrderList = () => import('@/views/orderauthor/order/list');
|
|
|
|
const OrderDraft = () => import('@/views/orderauthor/order/draft');
|
|
|
|
const Author = () => import('@/views/orderauthor/author/index');
|
|
|
|
const Permission = () => import('@/views/orderauthor/permission/index');
|
|
|
|
const PermissionDetail = () => import('@/views/orderauthor/permission/detail');
|
|
|
|
const PermissionCreate = () => import('@/views/orderauthor/permission/create/index');
|
|
|
|
const UserRules = () => import('@/views/orderauthor/rules/index');
|
|
|
|
const UserRulesDetail = () => import('@/views/orderauthor/rules/detail');
|
|
|
|
|
2020-01-02 17:01:11 +08:00
|
|
|
const DeviceManage = () => import('@/views/system/deviceManage/index');
|
2020-03-03 18:47:32 +08:00
|
|
|
const MapSort = () => import('@/views/publish/publishMap/mapSort');
|
2020-05-12 19:07:48 +08:00
|
|
|
const StudentManage = () => import('@/views/studentManage');
|
2020-05-26 17:55:11 +08:00
|
|
|
const RaceManage = () => import('@/views/competitionManage/competition/index');
|
2020-05-26 15:59:11 +08:00
|
|
|
const BankManage = () => import('@/views/competitionManage/bankList/index');
|
2020-05-26 17:55:11 +08:00
|
|
|
const PracticeManage = () => import('@/views/competitionManage/practiceList/index');
|
2020-05-26 15:59:11 +08:00
|
|
|
const QuestionCreatePage = () => import('@/views/competitionManage/bankList/question-create-page');
|
|
|
|
const QuestionUpdatePage = () => import('@/views/competitionManage/bankList/question-update-page');
|
2020-05-26 17:33:19 +08:00
|
|
|
const GeneratePaper = () => import('@/views/competitionManage/generatePaper');
|
2019-10-17 17:11:15 +08:00
|
|
|
|
2020-05-19 10:18:01 +08:00
|
|
|
const CompetitionDetail = () => import('@/views/jsxt/competition/examDetail');
|
2020-05-19 09:03:38 +08:00
|
|
|
const CompetitionManage = () => import('@/views/jsxt/competition/index');
|
2020-05-19 10:30:27 +08:00
|
|
|
const CompetitionHome = () => import('@/views/jsxt/competition/home');
|
2020-05-19 13:10:45 +08:00
|
|
|
const Refereedetail = () => import('@/views/jsxt/competition/theory/quiz/index');
|
2020-05-29 16:55:25 +08:00
|
|
|
const RefereeResult = () => import('@/views/jsxt/competition/theory/result');
|
2020-05-21 15:18:00 +08:00
|
|
|
const JsxtExamResult = () => import('@/views/jsxt/competition/result');
|
2020-05-19 16:56:36 +08:00
|
|
|
const JsxtApply = () => import('@/views/jsxt/apply/index');
|
|
|
|
// const theoryManage = () => import('@/views/jsxt/competition/theory/index');
|
2020-05-19 09:03:38 +08:00
|
|
|
const RefereeList = () => import('@/views/jsxt/refereeList/index');
|
2020-06-04 10:22:02 +08:00
|
|
|
const RefereeDisplay = () => import('@/views/jsxt/refereeList/display');
|
2020-08-10 17:40:17 +08:00
|
|
|
const Approval = () => import('@/views/approval/index');
|
2020-05-15 14:50:05 +08:00
|
|
|
|
2020-05-20 13:25:31 +08:00
|
|
|
import { GenerateRouteProjectList } from '@/scripts/ProjectConfig';
|
2020-05-22 17:10:07 +08:00
|
|
|
// import { getSessionStorage } from '@/utils/auth';
|
2019-10-11 08:55:02 +08:00
|
|
|
|
2019-07-02 16:29:52 +08:00
|
|
|
/**
|
|
|
|
* Note: sub-menu only appear when route children.length >= 1
|
|
|
|
* Detail see: https://panjiachen.github.io/vue-element-admin-site/guide/essentials/router-and-nav.html
|
|
|
|
*
|
|
|
|
* hidden: true if set true, item will not show in the sidebar(default is false)
|
|
|
|
* alwaysShow: true if set true, will always show the root menu
|
|
|
|
* if not set alwaysShow, when item has more than one children route,
|
|
|
|
* it will becomes nested mode, otherwise not show the root menu
|
|
|
|
* redirect: noRedirect if set noRedirect will no redirect in the breadcrumb
|
|
|
|
* name:'router-name' the name is used by <keep-alive> (must set!!!)
|
|
|
|
* meta : {
|
|
|
|
roles: ['admin','editor'] control the page roles (you can set multiple roles)
|
|
|
|
title: 'title' the name show in sidebar and breadcrumb (recommend set)
|
|
|
|
icon: 'svg-name' the icon show in the sidebar
|
|
|
|
breadcrumb: false if set false, the item will hidden in breadcrumb(default is true)
|
|
|
|
activeMenu: '/example/list' if set path, the sidebar will highlight the path you set
|
|
|
|
}
|
|
|
|
*/
|
|
|
|
|
|
|
|
export const user = '01'; // 普通用户
|
|
|
|
export const mapCreater = '02'; // 地图创建权限
|
|
|
|
export const lessonCreater = '03'; // 课程创建权限
|
|
|
|
export const admin = '04'; // 管理员
|
|
|
|
export const superAdmin = '05'; // 超级管理员
|
2020-05-20 13:25:31 +08:00
|
|
|
// export const referee = '07'; // 裁判员
|
2019-07-02 16:29:52 +08:00
|
|
|
|
2020-05-20 13:25:31 +08:00
|
|
|
export const projectTrain = '011'; // 城市轨道项目
|
|
|
|
export const projectXian = '012'; // 西安地铁项目
|
|
|
|
export const projectXty = '013'; // 西铁院
|
|
|
|
export const projectGzzb = '014'; // 贵州装备
|
|
|
|
export const projectJsxt = '015'; // 竞赛系统
|
2020-07-03 09:26:17 +08:00
|
|
|
export const projectJyd = '017'; // 竞业达
|
|
|
|
export const projectTky = '018'; // 铁科院
|
2020-07-09 18:04:11 +08:00
|
|
|
export const projectHeb = '019'; // 哈盈达
|
2020-08-26 13:25:22 +08:00
|
|
|
export const projectDrts = '020'; // 行调实训
|
2020-05-20 13:25:31 +08:00
|
|
|
|
|
|
|
export const userTrainingPlatform = '016'; // 实训系统
|
|
|
|
// export const refereePlatform = '017'; // 裁判系统
|
2019-07-02 16:29:52 +08:00
|
|
|
|
|
|
|
export const constantRoutes = [
|
2019-10-29 13:15:57 +08:00
|
|
|
// 实训平台登录
|
|
|
|
{
|
|
|
|
path: '/login',
|
|
|
|
component: Login,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
// 设计平台登录
|
|
|
|
{
|
|
|
|
path: '/design/login',
|
|
|
|
component: Login,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/design/jlmap3d/edit',
|
|
|
|
component: Jlmap3dedit,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-06-23 10:07:52 +08:00
|
|
|
{
|
|
|
|
path: '/design/jlmap3d/assetmanager',
|
|
|
|
component: Jlmap3dAssetManager,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-12-03 13:48:15 +08:00
|
|
|
{
|
|
|
|
path: '/jlmap3d/sandbox',
|
|
|
|
component: Jlmap3dSandbox,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-02-14 18:22:11 +08:00
|
|
|
{
|
|
|
|
path: '/jlmap3d/passengerflow',
|
|
|
|
component: Jlmap3dPassFlow,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-04-24 18:00:12 +08:00
|
|
|
|
2019-12-05 16:04:36 +08:00
|
|
|
{
|
|
|
|
path: '/jlmap3d/devicemodel',
|
|
|
|
component: Jlmap3dModel,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-12-11 10:47:24 +08:00
|
|
|
{
|
2020-07-09 10:16:33 +08:00
|
|
|
path: '/gzzbxy/relay/:deviceid', // 贵阳 继电器
|
2019-12-11 10:47:24 +08:00
|
|
|
component: Jlmap3dTrain,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-07-30 15:08:17 +08:00
|
|
|
{
|
2020-08-13 15:55:25 +08:00
|
|
|
path: '/jlmap3d/maintainer',
|
|
|
|
component: Jlmap3dMaintainer,
|
|
|
|
hidden: true
|
|
|
|
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/jlmap3d/maintainervr',
|
2020-07-30 17:49:20 +08:00
|
|
|
component: Jlmap3dMaintainerVr,
|
|
|
|
hidden: true
|
2020-07-30 15:08:17 +08:00
|
|
|
|
2020-09-23 16:20:50 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/jlmap3d/trainrescuevr',
|
|
|
|
component: Jl3dTrainRescueVr,
|
|
|
|
hidden: true
|
|
|
|
|
2020-07-30 15:08:17 +08:00
|
|
|
},
|
2020-08-26 13:54:44 +08:00
|
|
|
{
|
|
|
|
path: '/jlmap3d/othervr',
|
|
|
|
component: Jlmap3dOtherVR,
|
|
|
|
hidden: true
|
|
|
|
|
|
|
|
},
|
|
|
|
|
2020-05-19 16:56:36 +08:00
|
|
|
{ // 竞赛系统报名
|
|
|
|
path: '/jsxtApply',
|
|
|
|
component: JsxtApply,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-29 13:15:57 +08:00
|
|
|
{
|
|
|
|
path: '/404',
|
|
|
|
component: Errpr404,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ path: '*', redirect: '/404', hidden: true }
|
2019-07-04 10:59:40 +08:00
|
|
|
];
|
2020-04-16 15:52:56 +08:00
|
|
|
// 项目登录路径
|
|
|
|
GenerateRouteProjectList.forEach(item => {
|
|
|
|
constantRoutes.push({
|
|
|
|
path: `/${item}/login`,
|
|
|
|
component: Login,
|
|
|
|
hidden: true
|
|
|
|
});
|
|
|
|
constantRoutes.push({
|
|
|
|
path: `/${item}`,
|
|
|
|
redirect: `/${item}/login`,
|
|
|
|
hidden: true
|
|
|
|
});
|
|
|
|
});
|
2020-05-20 13:25:31 +08:00
|
|
|
// 公共路由不需要过滤 直接可以访问
|
|
|
|
export const publicAsyncRoute = [
|
|
|
|
{ // 全屏战场图
|
|
|
|
path: '/display/:mode',
|
|
|
|
component: Display,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-09-16 10:10:13 +08:00
|
|
|
{
|
|
|
|
path: '/ibpShow',
|
2020-09-16 14:26:04 +08:00
|
|
|
component: IbpShow,
|
2020-09-16 10:10:13 +08:00
|
|
|
hidden: true
|
|
|
|
},
|
2020-05-20 13:25:31 +08:00
|
|
|
{
|
|
|
|
path: '/displayNew/:mode',
|
|
|
|
component: DisplayNew,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/design/display/:mode',
|
|
|
|
component: DesignDisplay,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/design/displayNew/:mode',
|
|
|
|
component: DesignDisplayNew,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 剧本编辑 战场图
|
|
|
|
path: '/scriptDisplay/:mode',
|
|
|
|
component: ScriptDisplay,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 剧本编辑 战场图
|
|
|
|
path: '/scriptDisplayNew/:mode',
|
2020-07-28 13:56:36 +08:00
|
|
|
component: DisplayNew,
|
2020-05-20 13:25:31 +08:00
|
|
|
hidden: true
|
|
|
|
},
|
2020-05-27 09:56:59 +08:00
|
|
|
{ // 实操试题编辑 战场图
|
|
|
|
path: '/practiceDisplayNew/:mode',
|
|
|
|
component: PracticeDisplayNew,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-05-20 13:25:31 +08:00
|
|
|
{
|
|
|
|
path: '/displayBigScreen/:mapId',
|
|
|
|
component: BigScreen,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-07-06 18:16:49 +08:00
|
|
|
{ // 大屏切分
|
|
|
|
path: '/bigSplitScreen/:mapId',
|
|
|
|
component: BigSplitScreen,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-05-20 13:25:31 +08:00
|
|
|
{ // 综合演练室
|
|
|
|
path: '/trainroom',
|
|
|
|
component: TrainRoom,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/jointTraining',
|
|
|
|
component: JointTraining,
|
|
|
|
hidden: true
|
2020-06-04 10:22:02 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/refereeJsxtDisplay',
|
|
|
|
component: RefereeDisplay,
|
|
|
|
hidden: true
|
2020-05-20 13:25:31 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/jointTrainingNew',
|
|
|
|
component: JointTrainingNew,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/jlmap3d',
|
|
|
|
component: Jlmap3d,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-05-20 18:32:52 +08:00
|
|
|
{ // 运行图编辑
|
|
|
|
path: '/plan/usertool',
|
|
|
|
component: PlanMonitorEditUserTool,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 运行图编辑
|
|
|
|
path: '/plan/tool',
|
|
|
|
component: PlanMonitorEditTool,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-05-20 13:25:31 +08:00
|
|
|
{
|
|
|
|
path: '/displayIscs/system',
|
|
|
|
component: IscsSystem,
|
|
|
|
hidden: true,
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'config/:mode',
|
|
|
|
component: IscsConfig,
|
|
|
|
hidden: true
|
2020-09-22 11:31:18 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'stationConfig/:mode',
|
|
|
|
component: IscsStationConfig,
|
|
|
|
hidden: true
|
2020-05-20 13:25:31 +08:00
|
|
|
}
|
|
|
|
]
|
2020-08-13 11:23:07 +08:00
|
|
|
},
|
|
|
|
{
|
2020-08-14 10:55:32 +08:00
|
|
|
path: '/device/teachDetail',
|
|
|
|
component: TeachDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/device/course',
|
|
|
|
component: ExamCourseDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/device/examRule/manage',
|
|
|
|
component: PublishExamRule,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/device/examRule/draft/:mode/:ruleId/:lessonId',
|
|
|
|
component: PublishExamRuleDraft,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 试卷详情
|
|
|
|
path: '/device/exam/:examId',
|
|
|
|
component: ExamDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 考试结果
|
|
|
|
path: '/device/result/:userExamId',
|
|
|
|
component: ExamResult,
|
2020-08-13 11:23:07 +08:00
|
|
|
hidden: true
|
2020-05-20 13:25:31 +08:00
|
|
|
}
|
|
|
|
];
|
|
|
|
// 城市轨道项目
|
2019-07-26 13:32:43 +08:00
|
|
|
export const asyncRouter = [
|
2019-10-30 13:58:34 +08:00
|
|
|
{ // 公共地图
|
2019-10-29 13:15:57 +08:00
|
|
|
path: '/design',
|
|
|
|
component: Layout,
|
|
|
|
redirect: '/design/home',
|
|
|
|
meta: {
|
2019-11-14 16:31:31 +08:00
|
|
|
roles: [admin, user]
|
2019-10-29 13:15:57 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: '',
|
|
|
|
redirect: '/design/home',
|
|
|
|
component: DesignPlatform,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.designhomePage',
|
|
|
|
icon: 'design'
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'home',
|
|
|
|
component: DesignPlatformHome,
|
|
|
|
meta: {
|
|
|
|
}
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 运行图设计
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'runPlan/detail/:mapId',
|
|
|
|
component: PlanMonitorDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 剧本
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'script/home/:mapId',
|
|
|
|
component: ScriptmanageHome,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.scriptManage'
|
|
|
|
},
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 课程列表
|
2019-10-31 13:56:42 +08:00
|
|
|
path: 'lesson/home/:mapId',
|
2019-10-29 13:15:57 +08:00
|
|
|
component: LessonHome,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 操作定义
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'lesson/trainingRule',
|
|
|
|
component: TrainingRuleList,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 操作定义步骤
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'lesson/trainingRule/detail',
|
|
|
|
hidden: true,
|
|
|
|
component: TrainingRuleEdit
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 任务管理
|
|
|
|
path: 'lesson/taskManage',
|
|
|
|
component: Taskmanage,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 实训管理
|
2019-10-31 15:56:07 +08:00
|
|
|
path: 'lesson/trainingManage',
|
2019-10-29 13:15:57 +08:00
|
|
|
component: Trainingmanage,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-04-09 16:11:36 +08:00
|
|
|
{// 老地图实训管理
|
|
|
|
path: 'lesson/TrainingmanageOld',
|
|
|
|
component: TrainingmanageOld,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 创建课程
|
|
|
|
path: 'lesson/edit/:type',
|
|
|
|
component: LessonEdit,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 课程详情
|
|
|
|
path: 'lesson/details',
|
|
|
|
component: LessonDetail,
|
|
|
|
hidden: true,
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'edit/:type',
|
|
|
|
component: LessonEdit,
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{ // 地图预览
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'mapPreview/:mapId',
|
|
|
|
component: MapPreview,
|
|
|
|
hidden: true
|
2019-10-24 18:11:58 +08:00
|
|
|
|
2019-12-23 10:36:32 +08:00
|
|
|
},
|
|
|
|
{ // 新版地图预览
|
|
|
|
path: 'mapPreviewNew/:mapId',
|
|
|
|
component: MapPreviewNew,
|
|
|
|
hidden: true
|
2020-03-13 18:19:04 +08:00
|
|
|
},
|
2020-05-06 16:57:07 +08:00
|
|
|
{
|
|
|
|
path: 'bigScreen/:mapId',
|
|
|
|
component: BigScreen,
|
|
|
|
hidden: true
|
|
|
|
},
|
2020-03-13 18:19:04 +08:00
|
|
|
{ // ibp列表
|
|
|
|
path: 'ibp/home/:mapId',
|
|
|
|
component: IbpHome,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'ibp/edit',
|
|
|
|
component: IbpDraw,
|
|
|
|
hidden: true
|
2019-10-29 13:15:57 +08:00
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2019-10-30 10:15:18 +08:00
|
|
|
{ // 实训平台
|
2019-10-29 13:15:57 +08:00
|
|
|
path: '/trainingPlatform',
|
|
|
|
component: Layout,
|
|
|
|
hidden: true,
|
|
|
|
meta: {
|
2020-05-20 13:25:31 +08:00
|
|
|
roles: [admin, user, userTrainingPlatform]
|
2019-10-29 13:15:57 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: '',
|
|
|
|
component: TrainingPlatform,
|
|
|
|
meta: {
|
|
|
|
},
|
|
|
|
children: [
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 仿真详情
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'detail/:subSystem',
|
|
|
|
component: DemonstrationDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 教学系统 课程列表
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'teachHome/:subSystem',
|
|
|
|
component: TeachHome,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 15:44:43 +08:00
|
|
|
{ // 课程详情
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'teach/:subSystem',
|
|
|
|
component: TeachDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 17:30:24 +08:00
|
|
|
{ // 试卷列表
|
|
|
|
path: 'course/:subSystem',
|
|
|
|
component: ExamCourseDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 考试系统 课程列表
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'examHome/:subSystem',
|
|
|
|
component: ExamHome,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 17:30:24 +08:00
|
|
|
{ // 试卷详情
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'exam/:examId',
|
|
|
|
component: ExamDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 17:30:24 +08:00
|
|
|
{ // 试卷列表
|
|
|
|
path: 'examRule/manage',
|
|
|
|
component: PublishExamRule,
|
2019-10-29 13:15:57 +08:00
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 17:30:24 +08:00
|
|
|
{ // 创建试卷
|
|
|
|
path: 'examRule/draft/:mode/:ruleId/:lessonId',
|
|
|
|
component: PublishExamRuleDraft,
|
2019-10-29 13:15:57 +08:00
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 17:30:24 +08:00
|
|
|
{ // 购买
|
|
|
|
path: 'pay/:lessonId',
|
|
|
|
component: Pay,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 考试结果
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'result/:userExamId',
|
|
|
|
component: ExamResult,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 17:30:24 +08:00
|
|
|
{ // 线路权限列表
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'permission/:mapId',
|
|
|
|
component: Package,
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2019-10-30 13:58:34 +08:00
|
|
|
{ // 发布内容管理
|
2019-10-29 13:15:57 +08:00
|
|
|
path: '/publish',
|
|
|
|
component: Layout,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.pulishManage',
|
2019-11-14 16:31:31 +08:00
|
|
|
roles: [admin]
|
2019-10-29 13:15:57 +08:00
|
|
|
},
|
|
|
|
children: [
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 发布地图
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'map',
|
|
|
|
component: PublishMap,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.publishMapManage'
|
|
|
|
}
|
|
|
|
},
|
2020-03-03 18:47:32 +08:00
|
|
|
{
|
|
|
|
path: '/publish/mapSort',
|
|
|
|
component: MapSort,
|
|
|
|
hidden: true
|
|
|
|
},
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 发布历史
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'map/detail',
|
|
|
|
hidden: true,
|
|
|
|
component: PublishMapDetail
|
|
|
|
},
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 发布课程
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'lesson',
|
|
|
|
component: PublishLesson,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.publishLessonManage'
|
|
|
|
}
|
|
|
|
},
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 模板运行图
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'runPlan/template',
|
|
|
|
component: RunPlanTemplate,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.runPlanTemplateManage'
|
|
|
|
}
|
|
|
|
},
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 加载运行图管理
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'runPlan/common',
|
|
|
|
component: RunPlanCommon,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.runPlanCommonManage'
|
|
|
|
}
|
|
|
|
},
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 新增加载运行图
|
|
|
|
path: 'runPlan/common/:mode',
|
|
|
|
component: RunPlanCommonDraft,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 运行图预览
|
|
|
|
path: 'runPlan/view/:mode',
|
|
|
|
component: RunplanView,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{ // 每日运行图
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'runPlan/everyDay',
|
|
|
|
component: RunPlanEveryDay,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.runPlanEveryDayManage'
|
|
|
|
}
|
|
|
|
},
|
2019-10-31 18:43:05 +08:00
|
|
|
{ // 考试规则列表
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'examRule/manage',
|
|
|
|
component: PublishExamRule,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.examRuleManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'examRule/draft/:mode/:ruleId/:lessonId',
|
|
|
|
component: PublishExamRuleDraft,
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2019-10-30 13:58:34 +08:00
|
|
|
{ // 订单权限管理
|
2019-10-29 13:15:57 +08:00
|
|
|
path: '/orderauthor',
|
|
|
|
component: Layout,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.orderAuthorityManage',
|
2019-11-14 16:31:31 +08:00
|
|
|
roles: [admin]
|
2019-10-29 13:15:57 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'author/manage',
|
|
|
|
component: Author,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.authorityManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'commodity/manage',
|
|
|
|
component: Commodity,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.commodityManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'order/manage',
|
|
|
|
component: OrderList,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.orderManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'transfer/manage',
|
|
|
|
component: Permission,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.authorityTransferManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'rules/manage',
|
|
|
|
component: UserRules,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.userRulesManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'rules/manage/detail/:id',
|
|
|
|
hidden: true,
|
|
|
|
component: UserRulesDetail,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.userRulesManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'order/draft/:mode/:orderId',
|
|
|
|
hidden: true,
|
|
|
|
component: OrderDraft,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.addOrder'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'transfer/detail/:permissionId',
|
|
|
|
component: PermissionDetail,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'transfer/create',
|
|
|
|
component: PermissionCreate,
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2019-10-30 13:58:34 +08:00
|
|
|
{ // 系统管理
|
2019-10-29 13:15:57 +08:00
|
|
|
path: '/system',
|
|
|
|
component: Layout,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.systemManage',
|
2019-11-14 16:31:31 +08:00
|
|
|
roles: [admin]
|
2019-10-29 13:15:57 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'dictionary',
|
|
|
|
component: Dictionary,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.dataDictionary'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'dictionary/detail',
|
|
|
|
hidden: true,
|
|
|
|
component: DictionaryDetail,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.dataDictionaryDetails'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2019-11-01 15:12:00 +08:00
|
|
|
// 用户管理
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'userManage',
|
|
|
|
component: UserControl,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.userManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2019-11-01 15:12:00 +08:00
|
|
|
// 缓存管理
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'cache',
|
|
|
|
component: CacheControl,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.cacheManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'userTrainingManage',
|
|
|
|
component: UserTraining,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.userTrainingManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'userExamManage',
|
|
|
|
component: UserExam,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.userExamManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'userSimulationManage',
|
|
|
|
component: UserSimulation,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.userSimulationManage'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'existingSimulation',
|
|
|
|
component: ExistingSimulation,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.existingSimulation'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2019-11-01 15:12:00 +08:00
|
|
|
// 子系统生成
|
2019-10-29 13:15:57 +08:00
|
|
|
path: 'systemGenerate',
|
|
|
|
component: SystemGenerate,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.subsystemGeneration'
|
|
|
|
}
|
|
|
|
},
|
2019-11-15 16:31:48 +08:00
|
|
|
{ // 消息公告
|
2019-11-05 16:40:36 +08:00
|
|
|
path: 'news',
|
|
|
|
component: News,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.newsBulletin'
|
|
|
|
}
|
2019-11-15 16:31:48 +08:00
|
|
|
},
|
2020-09-09 11:25:31 +08:00
|
|
|
{ // 系统通知
|
|
|
|
path: 'notification',
|
|
|
|
component: Notification,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.notificationBulletin'
|
|
|
|
}
|
|
|
|
},
|
2019-11-15 16:31:48 +08:00
|
|
|
{ // 命令管理
|
|
|
|
path: 'commands',
|
|
|
|
component: CommandDictionary,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.commandDictionary'
|
|
|
|
}
|
2019-11-18 14:29:43 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'commands/Detail',
|
|
|
|
hidden: true,
|
|
|
|
component: CommandDictionaryDetail
|
2019-12-19 18:04:28 +08:00
|
|
|
},
|
|
|
|
{ // 线路管理
|
|
|
|
path: 'configLine',
|
|
|
|
component: configLine,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.configLine'
|
|
|
|
}
|
2020-08-10 17:40:17 +08:00
|
|
|
},
|
|
|
|
{// 发布申请
|
|
|
|
path: 'approval',
|
|
|
|
component: Approval,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.releaseApplication'
|
|
|
|
}
|
2019-10-29 13:15:57 +08:00
|
|
|
}
|
2020-06-19 18:02:50 +08:00
|
|
|
// {
|
|
|
|
// path: 'deviceManage',
|
|
|
|
// component: DeviceManage,
|
|
|
|
// meta: {
|
|
|
|
// i18n: 'router.deviceManage'
|
|
|
|
// }
|
|
|
|
// }
|
2019-10-29 13:15:57 +08:00
|
|
|
]
|
|
|
|
},
|
2019-11-29 12:51:58 +08:00
|
|
|
{ // 新个人地图
|
2020-05-13 18:59:28 +08:00
|
|
|
path: '/design',
|
2019-11-29 12:51:58 +08:00
|
|
|
component: Layout,
|
|
|
|
meta: {
|
2020-05-13 18:59:28 +08:00
|
|
|
i18n: 'router.newDesignUserPage',
|
2020-04-01 16:24:03 +08:00
|
|
|
roles: [admin, user]
|
2019-11-29 12:51:58 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
2020-05-13 18:59:28 +08:00
|
|
|
path: 'usermap',
|
2019-11-29 12:51:58 +08:00
|
|
|
redirect: '/design/usermap/home',
|
|
|
|
component: NewDesignPlatformUser,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.newDesignUserPage',
|
|
|
|
icon: 'design'
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'home',
|
|
|
|
component: DesignPlatformHome,
|
2020-05-13 18:59:28 +08:00
|
|
|
hidden: true,
|
2019-11-29 12:51:58 +08:00
|
|
|
meta: {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
2020-04-23 17:11:51 +08:00
|
|
|
},
|
|
|
|
{ // 新地图绘制
|
2020-05-13 18:59:28 +08:00
|
|
|
path: 'usermap/map/draw/:mapId/:view',
|
2020-04-23 17:11:51 +08:00
|
|
|
component: NewMapDraft,
|
|
|
|
hidden: true
|
2020-05-13 18:59:28 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path:'iscs/design',
|
|
|
|
redirect: '/iscs/design',
|
|
|
|
component: IscsDesign,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.iscsDraw',
|
|
|
|
roles: [admin]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
2020-06-24 15:02:09 +08:00
|
|
|
path: 'edit',
|
2020-05-13 18:59:28 +08:00
|
|
|
component: IscsDraw,
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'iscs/system',
|
|
|
|
redirect: '/iscs/system',
|
|
|
|
component: IscsSystem,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.iscsSystem',
|
|
|
|
roles: [admin]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'config/:mode',
|
|
|
|
component: IscsConfig,
|
|
|
|
hidden: true
|
2020-09-22 11:31:18 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'stationConfig/:mode',
|
|
|
|
component: IscsStationConfig,
|
|
|
|
hidden: true
|
2020-05-13 18:59:28 +08:00
|
|
|
}
|
|
|
|
]
|
2019-11-29 12:51:58 +08:00
|
|
|
}
|
|
|
|
]
|
2020-01-19 18:36:17 +08:00
|
|
|
},
|
|
|
|
{ // iscs系统
|
|
|
|
path: '/iscs',
|
|
|
|
component: Layout,
|
2020-05-13 18:59:28 +08:00
|
|
|
hidden: true,
|
2020-01-19 18:36:17 +08:00
|
|
|
meta: {
|
2020-03-19 14:33:54 +08:00
|
|
|
i18n: 'router.iscsSystem',
|
|
|
|
roles: [admin]
|
2020-01-19 18:36:17 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path:'design',
|
|
|
|
component: IscsDesign,
|
|
|
|
meta: {
|
2020-01-20 10:55:33 +08:00
|
|
|
i18n: 'router.iscsDraw',
|
|
|
|
roles: [admin]
|
2020-01-19 18:36:17 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
2020-06-24 15:02:09 +08:00
|
|
|
path: 'edit',
|
2020-01-19 18:36:17 +08:00
|
|
|
component: IscsDraw,
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'system',
|
|
|
|
component: IscsSystem,
|
|
|
|
meta: {
|
2020-01-20 10:55:33 +08:00
|
|
|
i18n: 'router.iscsSystem',
|
|
|
|
roles: [admin, user]
|
2020-01-20 09:20:09 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'config/:mode',
|
|
|
|
component: IscsConfig,
|
|
|
|
hidden: true
|
2020-09-22 11:31:18 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'stationConfig/:mode',
|
|
|
|
component: IscsStationConfig,
|
|
|
|
hidden: true
|
2020-01-20 09:20:09 +08:00
|
|
|
}
|
|
|
|
]
|
2020-01-19 18:36:17 +08:00
|
|
|
}
|
|
|
|
]
|
2020-05-20 14:46:26 +08:00
|
|
|
},
|
|
|
|
{
|
2020-05-26 15:59:11 +08:00
|
|
|
path: '/design/race', // 竞赛管理
|
2020-05-20 14:46:26 +08:00
|
|
|
component: Layout,
|
|
|
|
meta: {
|
2020-05-26 15:59:11 +08:00
|
|
|
i18n: 'router.raceManage',
|
2020-05-20 14:46:26 +08:00
|
|
|
roles: [admin]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'manage',
|
|
|
|
component: RaceManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.raceManage',
|
|
|
|
icon: 'design'
|
|
|
|
}
|
2020-05-26 15:59:11 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'bank',
|
|
|
|
component: BankManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.bankManage',
|
|
|
|
icon: 'design'
|
|
|
|
}
|
|
|
|
},
|
2020-05-26 17:55:11 +08:00
|
|
|
{
|
|
|
|
path: 'practice',
|
|
|
|
component: PracticeManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.practiceManage',
|
|
|
|
icon: 'design'
|
|
|
|
}
|
|
|
|
},
|
2020-05-26 15:59:11 +08:00
|
|
|
{
|
|
|
|
path: 'questionCreate',
|
|
|
|
component: QuestionCreatePage,
|
|
|
|
hidden: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'questionUpdate/:questionId',
|
|
|
|
component: QuestionUpdatePage,
|
|
|
|
hidden: true
|
2020-05-26 17:33:19 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: 'generate',
|
|
|
|
component: GeneratePaper,
|
|
|
|
hidden: true
|
2020-05-20 14:46:26 +08:00
|
|
|
}
|
|
|
|
]
|
2019-11-29 13:10:18 +08:00
|
|
|
}
|
2019-07-04 10:59:40 +08:00
|
|
|
];
|
2020-06-19 18:02:50 +08:00
|
|
|
/* merge 是否再路由处理中与asyncRouter进行合并 mergeIndex合并进入asyncRouter【mergeIndex】 慎重调整asyncRouter顺序 */
|
2020-05-18 17:59:38 +08:00
|
|
|
export const projectRoute = {
|
|
|
|
designgzb: [
|
|
|
|
{
|
|
|
|
path: '/design/student',
|
|
|
|
redirect: '/design/student/home',
|
|
|
|
component: Layout,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.studentManage',
|
|
|
|
roles: [admin, lessonCreater]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'home',
|
|
|
|
component: StudentManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.studentManage',
|
|
|
|
icon: 'design',
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
2020-06-19 18:02:50 +08:00
|
|
|
},
|
|
|
|
{ // 系统管理
|
|
|
|
path: '/system',
|
|
|
|
component: Layout,
|
|
|
|
merge: true,
|
|
|
|
mergeIndex: 4,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.systemManage',
|
|
|
|
roles: [admin]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'deviceManage',
|
|
|
|
component: DeviceManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.deviceManage'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
],
|
|
|
|
designxty: [
|
|
|
|
{ // 系统管理
|
|
|
|
path: '/system',
|
|
|
|
component: Layout,
|
|
|
|
merge: true,
|
|
|
|
mergeIndex: 4,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.systemManage',
|
|
|
|
roles: [admin]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'deviceManage',
|
|
|
|
component: DeviceManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.deviceManage'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
2020-05-18 17:59:38 +08:00
|
|
|
}
|
2020-07-09 15:46:52 +08:00
|
|
|
],
|
2020-07-09 18:04:11 +08:00
|
|
|
designheb: [
|
2020-07-09 15:46:52 +08:00
|
|
|
{ // 系统管理
|
|
|
|
path: '/system',
|
|
|
|
component: Layout,
|
|
|
|
merge: true,
|
|
|
|
mergeIndex: 4,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.systemManage',
|
|
|
|
roles: [admin]
|
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'deviceManage',
|
|
|
|
component: DeviceManage,
|
|
|
|
meta: {
|
|
|
|
i18n: 'router.deviceManage'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
2020-05-18 17:59:38 +08:00
|
|
|
]
|
|
|
|
};
|
2020-05-20 13:25:31 +08:00
|
|
|
// 竞赛系统
|
2020-05-18 13:08:45 +08:00
|
|
|
export const JSXT = [
|
2020-05-15 14:50:05 +08:00
|
|
|
{
|
|
|
|
path: '/jsxt',
|
2020-05-19 10:30:27 +08:00
|
|
|
redirect: '/jsxt/home',
|
2020-05-15 14:50:05 +08:00
|
|
|
component: Layout,
|
|
|
|
meta: {
|
2020-05-20 13:25:31 +08:00
|
|
|
roles: [user, admin, userTrainingPlatform]
|
2020-05-15 14:50:05 +08:00
|
|
|
},
|
2020-05-22 15:41:35 +08:00
|
|
|
hidden: true,
|
2020-05-15 14:50:05 +08:00
|
|
|
children: [
|
|
|
|
{
|
2020-05-19 10:30:27 +08:00
|
|
|
path: '',
|
|
|
|
redirect: '/jsxt/home',
|
2020-05-15 14:50:05 +08:00
|
|
|
component: CompetitionManage,
|
|
|
|
meta: {
|
2020-05-19 10:30:27 +08:00
|
|
|
},
|
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'home',
|
|
|
|
component: CompetitionHome,
|
2020-05-22 15:41:35 +08:00
|
|
|
hidden: true
|
2020-05-19 10:30:27 +08:00
|
|
|
},
|
2020-05-19 16:56:36 +08:00
|
|
|
// {
|
|
|
|
// path: 'theory/:id',
|
|
|
|
// component: theoryManage,
|
2020-05-22 15:41:35 +08:00
|
|
|
// hidden: true
|
2020-05-19 16:56:36 +08:00
|
|
|
// },
|
2020-05-19 10:32:07 +08:00
|
|
|
{
|
|
|
|
path: 'examDetail',
|
|
|
|
component: CompetitionDetail,
|
2020-05-22 15:41:35 +08:00
|
|
|
hidden: true
|
2020-05-21 14:59:18 +08:00
|
|
|
},
|
|
|
|
{ // 考试结果
|
2020-05-21 15:18:00 +08:00
|
|
|
path: 'result',
|
2020-05-21 14:59:18 +08:00
|
|
|
component: JsxtExamResult,
|
|
|
|
hidden: true
|
2020-05-19 10:30:27 +08:00
|
|
|
}
|
|
|
|
]
|
2020-05-15 14:50:05 +08:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2020-05-19 13:10:45 +08:00
|
|
|
{
|
2020-05-29 16:55:25 +08:00
|
|
|
path: '/jsxt/theory/detail',
|
2020-05-19 13:10:45 +08:00
|
|
|
component: Refereedetail,
|
2020-05-22 15:41:35 +08:00
|
|
|
hidden: true
|
2020-05-29 16:55:25 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
path: '/jsxt/theory/result', // 考试结果页面
|
|
|
|
component: RefereeResult,
|
|
|
|
hidden: true
|
2020-05-19 13:10:45 +08:00
|
|
|
},
|
2020-05-22 16:26:59 +08:00
|
|
|
// 裁判系统
|
2020-05-15 14:50:05 +08:00
|
|
|
{
|
|
|
|
path: '/refereeJsxt',
|
2020-05-22 16:26:59 +08:00
|
|
|
redirect: '/refereeJsxt/home',
|
2020-05-15 14:50:05 +08:00
|
|
|
component: Layout,
|
2020-05-19 09:03:38 +08:00
|
|
|
meta: {
|
|
|
|
i18n: 'router.homeJsxt',
|
2020-05-20 13:25:31 +08:00
|
|
|
roles: [user, admin]
|
2020-05-19 09:03:38 +08:00
|
|
|
},
|
2020-05-22 16:26:59 +08:00
|
|
|
hidden: true,
|
2020-05-12 19:07:48 +08:00
|
|
|
children: [
|
|
|
|
{
|
|
|
|
path: 'home',
|
2020-05-15 16:01:16 +08:00
|
|
|
component: RefereeList,
|
2020-05-12 19:07:48 +08:00
|
|
|
meta: {
|
2020-05-15 14:50:05 +08:00
|
|
|
i18n: 'router.refereeJManage',
|
2020-05-12 19:07:48 +08:00
|
|
|
icon: 'design',
|
|
|
|
hidden: true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
2019-11-29 13:10:18 +08:00
|
|
|
}
|
2019-07-04 10:59:40 +08:00
|
|
|
];
|
2019-07-02 16:29:52 +08:00
|
|
|
const createRouter = () => new Router({
|
2019-10-29 13:15:57 +08:00
|
|
|
mode: 'history', // require service support
|
|
|
|
scrollBehavior: () => ({ y: 0 }),
|
|
|
|
routes: constantRoutes
|
2019-07-04 10:59:40 +08:00
|
|
|
});
|
2019-07-02 16:29:52 +08:00
|
|
|
|
2019-07-04 10:59:40 +08:00
|
|
|
const router = createRouter();
|
2019-07-02 16:29:52 +08:00
|
|
|
|
2019-11-19 17:42:36 +08:00
|
|
|
// 兼容 vue-router在3.1.0版本以上的路由跳转使用的是 promise 的方式
|
|
|
|
const originalPush = Router.prototype.push;
|
2020-07-29 14:14:34 +08:00
|
|
|
const originalReplace = Router.prototype.replace;
|
2019-11-19 17:42:36 +08:00
|
|
|
Router.prototype.push = function push(location) {
|
|
|
|
return originalPush.call(this, location).catch(err => err);
|
|
|
|
};
|
2020-07-29 14:14:34 +08:00
|
|
|
Router.prototype.replace = function replace(location) {
|
|
|
|
return originalReplace.call(this, location).catch(err => err);
|
|
|
|
};
|
2019-07-04 10:59:40 +08:00
|
|
|
export default router;
|