import { createRouter, createWebHistory } from "vue-router"; const routes = [ { path: "/", name: "root", component: function () { return import("../views/Root.vue"); }, children: [ { path: "/", component: function () { return import("../views/HomePage.vue"); }, }, { path: "/sksjgl", component: function () { return import("../views/Sksjgl.vue"); }, }, { path: "/wgn", name: "wgn", component: function () { return import("../views/Wgn.vue"); }, }, { path: "/sksjyl", name: "sksjyl", component: function () { return import("../views/wgn/sksj/index.vue"); }, }, { path: "skmh", component: function () { return import("../views/skmh/index.vue"); }, }, { path: "/yxgl", name: "yxgl", component: function () { return import("../views/Yxgl.vue"); }, children: [ // 子路由配置开始 { path: "StatisticalAnalysis", component: function () { return import("../views/yxgl/StatisticalAnalysis.vue"); }, }, ], // 子路由配置结束 }, //应用管理 { path: "/yygl", path: "yygl", component: function () { return import("../views/yygl/index.vue"); }, children: [ // 子路由配置开始 { path: "appCenter", component: function () { return import("../views/yygl/appCenter.vue"); }, }, ], }, //应用中心 { path: "appCenter", path: "appCenter", component: function () { return import("../views/yygl/appCenter.vue"); }, }, //任务管理 { path: "taskManger", path: "taskManger", component: function () { return import("../views/rwgl/Index.vue"); }, }, ], }, // { // path: '/example', // name: 'example', // component: function () { // return import('../views/Example.vue') // }, // children: [ // 子路由配置开始 // { // path: '/yygl', // path: 'yygl', // component: function () { // return import('../views/yygl/index.vue') // } // }, // //应用中心 // { // path: 'appCenter', // path: 'appCenter', // component: function () { // return import('../views/yygl/appCenter.vue') // } // }, // ], // }, /***************** 跳转单页面 ******************/ // 时空门户 // { // path: '/skmh', // name: 'skmh', // component: function () { // return import('../views/skmh/index.vue') // }, // children: [ // 子路由配置开始 // { // path: 'example', // component: function () { // return import('../views/skmh/Example.vue') // } // }, // { // path: 'index', // component: function () { // return import('../views/skmh/index.vue') // } // }, // { // path: 'scene', // component: function () { // return import('../views/skmh/scene/index.vue') // } // } // ], // 子路由配置结束 // }, // 微功能 { path: "/wgnSingle", name: "wgnSingle", component: function () { return import("../views/wgn/Example.vue"); }, }, { path: "/sksj", name: "sksj", component: function () { return import("../views/wgn/sksj/index.vue"); }, }, { path: "/sksjglyl", name: "sksjglyl", component: function () { return import("../views/Sksjglyl.vue"); }, }, // 文件预览功能 { path: "/fileView", name: "fileView", component: function () { return import("../components/filePreview/viewPreview.vue"); }, }, // 应用管理 // { // path: '/yygl', // name: 'yygl', // component: function () { // return import('../views/Yygl.vue') // }, // children: [ // 子路由配置开始 // { // path: 'example', // component: function () { // return import('../views/yygl/Example.vue') // }, // }, // ], // 子路由配置结束 // }, // 运行管理 // { // path: '/yxgl', // name: 'yxgl', // component: function () { // return import('../views/Yxgl.vue') // }, // children: [ // 子路由配置开始 // { // path: 'StatisticalAnalysis', // component: function () { // return import('../views/yxgl/StatisticalAnalysis.vue') // }, // } // ], // 子路由配置结束 // }, ]; const router = createRouter({ history: createWebHistory(process.env.BASE_URL), routes, }); export default router;