Jelajahi Sumber

修改/admin提交时的访问界面

“yueshang” 2 tahun lalu
induk
melakukan
3a3610b340
2 mengubah file dengan 18 tambahan dan 2 penghapusan
  1. 1 0
      src/layout/indexCommon.vue
  2. 17 2
      src/router/index.js

+ 1 - 0
src/layout/indexCommon.vue

@@ -11,6 +11,7 @@
               v-model="input3"
               class="w-50 m-2"
               size="small"
+              placeholder="搜索文件"
               suffix-icon="Search"
             />
           </div>

+ 17 - 2
src/router/index.js

@@ -73,12 +73,26 @@ export const constantRoutes = [
         path:'swagger',
         component:() => import('@/views/tool/swagger/index.vue'),
         name:'swagger',
-        meta:{ title:'接口',icon: 'dashboard' },
-        
+        meta:{ title:'接口',icon: 'dashboard' },      
       }
     ]
   },
   {
+    path: '/admin',
+    component:Layout,
+    redirect: '/admin/index',
+    children: [
+      {
+        path: 'index',
+        // component: () => import('@/layout/index.vue'),
+        name: 'adminIndex',
+        meta: { title: '首页', icon: 'dashboard', affix: true },
+      },
+      // 其他 admin 下的子路由
+    ]
+  },
+  
+  {
     path: '/file',
     component: Layout,
     redirect: '/index',
@@ -211,6 +225,7 @@ const router = createRouter({
     } else {
       return { top: 0 }
     }
+    console.log(savedPosition,'savedPosition');
   },
 });