Przeglądaj źródła

修改路由为history模式

yangdr 6 miesięcy temu
rodzic
commit
976c596b08
2 zmienionych plików z 4 dodań i 12 usunięć
  1. 2 2
      src/main.js
  2. 2 10
      src/routes.js

+ 2 - 2
src/main.js

@@ -23,8 +23,8 @@ Vue.use(UTable);
 Vue.use(UxGrid);
 Vue.use(UxTableColumn);
 const router = new VueRouter({
-  // mode: 'history',
-  mode: 'hash',
+  mode: 'history',
+  // mode: 'hash',
   routes
 });
 

+ 2 - 10
src/routes.js

@@ -42,18 +42,10 @@ import SonHospital from '@components/icss/sonhospital/SonHospital.vue';  //子
 import CallRecordManager from '@components/callRecord/CallRecordManager.vue';  //知识库规则维护
 
 export default [
-  {
-    path: '/',
-    name: 'login',
-    component: Login,
-  },
+  { path: '/', name: 'login', component: Login, },
   {
     //朗通后台
-    path: '/admin',
-    component: HomePage,
-    meta: {
-      requireAuth: false,
-    },
+    path: '/admin', component: HomePage, meta: { requireAuth: false, },
     children: [
       { path: 'YXSYK-JTZSWH', component: MedicinePrompt, meta: { requireAuth: true, }, name: 'MedicinePrompt' }, //医学术语提示信息维护
       { path: 'LT-YXSYKWH-TJYXSYJTZS', meta: { requireAuth: true, }, component: AddMedicinePrompt, name: 'AddMedicinePrompt' }, //医学术语提示信息维护添加