lilei 4 年 前
コミット
a366d89f9e
2 ファイル変更4 行追加4 行削除
  1. 2 2
      src/permission.js
  2. 2 2
      vue.config.js

+ 2 - 2
src/permission.js

@@ -28,9 +28,9 @@ router.beforeEach((to, from, next) => {
     } else {
       const userInfo = Vue.ls.get('userName')
       console.log(userInfo)
-      if (userInfo) {
+      if (userInfo && token != 'null') {
         store.dispatch('SetInfo', userInfo)
-        if (store.getters.roles.permissionList.length === 0 && (token != 'null')) {
+        if (store.getters.roles.permissionList.length === 0) {
           store
             .dispatch('GetInfo', token)
             .then(res => {

+ 2 - 2
vue.config.js

@@ -108,8 +108,8 @@ const vueConfig = {
     // If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
     proxy: {
       '/api': {
-        // target: 'http://192.168.16.102:8301/gc-admin/',
-        target: 'https://lese.test.sxzxyj.net/gc-admin/',
+        target: 'http://192.168.16.103:8301/gc-admin/',
+        // target: 'https://lese.test.sxzxyj.net/gc-admin/',
         ws: false,
         changeOrigin: true,
         pathRewrite: {