Browse Source

公众号

hurixing 1 year ago
parent
commit
bbb014cde1
4 changed files with 10 additions and 3 deletions
  1. 2 0
      package.json
  2. 1 0
      src/main.js
  3. 1 2
      src/permission.js
  4. 6 1
      src/router/index.js

+ 2 - 0
package.json

@@ -34,6 +34,8 @@
     "tim-js-sdk": "^2.27.5",
     "tim-profanity-filter-plugin": "^0.9.0",
     "tim-upload-plugin": "^1.3.0",
+    "vant": "^2.13.6",
+    "vant-green": "^1.0.44",
     "vue": "^2.7.9",
     "vue-count-to": "1.0.13",
     "vue-cropper": "0.5.5",

+ 1 - 0
src/main.js

@@ -68,6 +68,7 @@ Vue.prototype.download = download
 Vue.prototype.handleTree = handleTree
 Vue.prototype.$message = message
 
+
 // 全局组件挂载
 Vue.component('DictTag', DictTag)
 Vue.component('Pagination', Pagination)

+ 1 - 2
src/permission.js

@@ -8,7 +8,7 @@ import { isRelogin } from '@/utils/request'
 
 NProgress.configure({ showSpinner: false })
 
-const whiteList = ['/login', '/register']
+const whiteList = ['/login', '/register','/officialAccounts/patientData']
 
 router.beforeEach((to, from, next) => {
   NProgress.start()
@@ -23,7 +23,6 @@ router.beforeEach((to, from, next) => {
         isRelogin.show = true
         // 判断当前用户是否已拉取完user_info信息
         store.dispatch('GetInfo').then(() => {
-          console.log(store)
           isRelogin.show = false
           store.dispatch('GenerateRoutes').then(accessRoutes => {
             // 根据roles权限生成可访问的路由表

+ 6 - 1
src/router/index.js

@@ -85,7 +85,12 @@ export const constantRoutes = [
         meta: { title: '个人中心', icon: 'user' }
       }
     ]
-  }
+  },
+  {
+    path: '/officialAccounts/patientData',
+    component: () => import('@/views/officialAccounts/patientData'),
+    hidden: true
+  },
 ]
 
 // 动态路由,基于用户权限动态去加载