瀏覽代碼

配置文件

彭宇 1 年之前
父節點
當前提交
7f553e34e9
共有 4 個文件被更改,包括 15 次插入17 次删除
  1. 2 3
      manifest.json
  2. 2 2
      pages/login.vue
  3. 11 11
      permission.js
  4. 0 1
      utils/request.js

+ 2 - 3
manifest.json

@@ -1,5 +1,5 @@
 {
-    "name" : "wxf75b34dd1f737174",
+    "name" : "吉农宝",
     "appid" : "",
     "description" : "",
     "versionName" : "1.0.0",
@@ -51,7 +51,7 @@
     },
     "quickapp" : {},
     "mp-weixin" : {
-        "appid" : "wxf75b34dd1f737174",
+        "appid" : "wx0904bdfd9c082418",
         "setting" : {
             "urlCheck" : false
         },
@@ -62,7 +62,6 @@
             }
         },
         "plugins" : {}
-		
     },
     "mp-alipay" : {
         "usingComponents" : true

+ 2 - 2
pages/login.vue

@@ -30,7 +30,7 @@
 					 _this.$store.dispatch('Login', res.code).then(() => {
 					 	_this.$modal.closeLoading()
 					 	uni.switchTab({
-					 		url:'/pages/demo/index'
+					 		url:'/pages/index/index'
 					 	})
 					 })
 		           } else {
@@ -154,4 +154,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 11 - 11
permission.js

@@ -19,18 +19,18 @@ let list = ["navigateTo", "redirectTo", "reLaunch", "switchTab"]
 list.forEach(item => {
   uni.addInterceptor(item, {
     invoke(to) {
-      if (getToken()) {
-        if (to.url === loginPage) {
-          uni.reLaunch({ url: "/" })
-        }
+      // if (getToken()) {
+      //   if (to.url === loginPage) {
+      //     uni.reLaunch({ url: "/" })
+      //   }
         return true
-      } else {
-        if (checkWhite(to.url)) {
-          return true
-        }
-        uni.reLaunch({ url: loginPage })
-        return false
-      }
+      // } else {
+      //   if (checkWhite(to.url)) {
+      //     return true
+      //   }
+      //   uni.reLaunch({ url: loginPage })
+      //   return false
+      // }
     },
     fail(err) {
       console.log(err)

+ 0 - 1
utils/request.js

@@ -8,7 +8,6 @@ let timeout = 10000
 const baseUrl = config.baseUrl
 
 const request = config => {
-	debugger
   // 是否需要设置 token
   const isToken = (config.headers || {}).isToken === false
   config.header = config.header || {}