From 2cac4a0f4ea0b1cf7bff4759fae8136c72792563 Mon Sep 17 00:00:00 2001
From: 闫增涛 <1829501689@qq.com>
Date: 星期一, 14 四月 2025 15:30:29 +0800
Subject: [PATCH] 番茄闹钟

---
 src/router/index.ts |  102 ++++++++++++++++++++++++++++++++++++++++----------
 1 files changed, 81 insertions(+), 21 deletions(-)

diff --git a/src/router/index.ts b/src/router/index.ts
index 9664723..997775c 100644
--- a/src/router/index.ts
+++ b/src/router/index.ts
@@ -1,37 +1,97 @@
 import { createRouter, createWebHashHistory, createWebHistory } from 'vue-router'
 import Layout from '@/layout/layout.vue'
-const Home = () => import('@/views/home.vue')
+const Reader = () => import('@/views/readerPages/home.vue')
 const Login = () => import('@/views/login.vue')
 
 const router = createRouter({
-  history: createWebHistory(import.meta.env.BASE_URL),
+  history: createWebHashHistory(import.meta.env.BASE_URL),
   routes: [
     {
       path: '/',
-      redirect: 'home'
+      component: Layout,
+      redirect:'/home',
+      children: [
+        {
+          path: '/index',
+          name: 'index',
+          redirect: "/bookshelfList",
+          meta: { auth: true },
+          component: () => import('@/views/index.vue'),
+          children: [
+            {
+              path: '/bookshelfList',
+              name: 'bookshelfList',
+              meta: { auth: true, name: '涔︽灦' },
+              component: () => import('@/views/bookshelfList/list.vue')
+            },
+            {
+              path: '/classeManagement',
+              name: 'classeManagement',
+              meta: { auth: true, name: '鐝骇' },
+              component: () => import('@/views/classeManagement/list.vue')
+            },
+            {
+              path: '/jobManagement',
+              name: 'jobManagement',
+              meta: { auth: true, name: '浣滀笟' },
+              component: () => import('@/views/jobManagement/list.vue')
+            },
+            {
+              path: '/personalCenter',
+              name: 'personalCenter',
+              meta: { auth: true, name: '涓汉涓績' },
+              component: () => import('@/views/personalCenter/index.vue')
+            },
+            {
+              path: '/messageList',
+              name: 'messageList',
+              meta: { auth: true, name: '娑堟伅' },
+              component: () => import('@/views/messageList/list.vue')
+            }
+          ]
+        },
+        {
+          path: '/dictionary',
+          name: 'dictionary',
+          meta: { auth: true, name: '璇嶅吀' },
+          component: () => import('@/views/components/dictionary.vue')
+        },
+        {
+          path: '/newWord',
+          name: 'newWord',
+          meta: { auth: true, name: '鐢熻瘝' },
+          component: () => import('@/views/components/newWord.vue')
+        },
+        {
+          path: '/wrongQuestion',
+          name: 'wrongQuestion',
+          meta: { auth: true, name: '閿欓' },
+          component: () => import('@/views/components/wrongQuestion.vue')
+        }
+      ]
+    },
+    {
+      path: '/home',
+      name: 'home',
+      meta: { auth: true, name: '闃呰鍣�' },
+      component: Reader
+    },
+    {
+      path: '/webHome',
+      name: 'webHome',
+      meta: { auth: true, name: 'web闃呰鍣�' },
+      component: () => import('@/views/readerPages/webHome.vue')
+    },
+    {
+      path: '/mobileHome',
+      name: 'mobileHome',
+      meta: { auth: true, name: '绉诲姩闃呰鍣�' },
+      component: () => import('@/views/readerPages/mobileHome.vue')
     },
     {
       path: '/login',
       name: 'login',
       component: Login
-    },
-    {
-      path: '/',
-      component: Layout,
-      children: [
-        {
-          path: '/home',
-          name: 'home',
-          meta: { auth: true },
-          component: Home
-        },
-        {
-          path: '/dictionary',
-          name: 'dictionary',
-          meta: { auth: true },
-          component: () =>import('@/views/components/dictionary.vue')
-        }
-      ]
     }
   ]
 })

--
Gitblit v1.9.1