2023-07-21 16:34:06 +07:00
|
|
|
import { createRouter, createWebHistory } from "vue-router"
|
2023-07-07 16:54:53 +07:00
|
|
|
|
2023-07-21 16:34:06 +07:00
|
|
|
const MainLayout = () => import("@/views/MainLayout.vue")
|
|
|
|
|
const Dashboard = () => import("@/modules/01_dashboard/views/Dashboard.vue")
|
2023-07-07 16:54:53 +07:00
|
|
|
|
2023-07-21 16:34:06 +07:00
|
|
|
import ModuleTransfer from "@/modules/02_transfer/router.ts"
|
|
|
|
|
import ModuleLeave from "@/modules/03_leave/router.ts"
|
2023-07-07 16:54:53 +07:00
|
|
|
|
|
|
|
|
const router = createRouter({
|
2023-07-21 16:34:06 +07:00
|
|
|
history: createWebHistory(import.meta.env.BASE_URL),
|
|
|
|
|
routes: [
|
|
|
|
|
{
|
|
|
|
|
path: "/",
|
|
|
|
|
name: "home",
|
|
|
|
|
component: MainLayout,
|
|
|
|
|
children: [
|
|
|
|
|
{
|
|
|
|
|
path: "/",
|
|
|
|
|
name: "dashboard",
|
|
|
|
|
component: Dashboard,
|
|
|
|
|
},
|
|
|
|
|
...ModuleTransfer,
|
|
|
|
|
...ModuleLeave,
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
],
|
2023-07-07 16:54:53 +07:00
|
|
|
})
|
|
|
|
|
|
2023-07-21 16:34:06 +07:00
|
|
|
export default router
|