Browse Source

Signed-off-by: liuboyan <632697560@qq.com>
bug

liuboyan 4 years ago
parent
commit
1cd9ab49f3
4 changed files with 16 additions and 12 deletions
  1. 4 6
      pages.json
  2. 5 5
      pages/index/index.vue
  3. 6 0
      pagesMain/openMember.vue
  4. 1 1
      utils/request.js

+ 4 - 6
pages.json

@@ -19,11 +19,9 @@
 		"style": {
 			"navigationBarTitleText": "个人"
 		}
-	}, {
+	}, {
 		"path": "pages/login/index",
-		"style": {
-			"navigationStyle": "custom"
-		}
+		"style": {}
 	}],
 	"subPackages": [{
 		"root": "pagesMember",
@@ -44,7 +42,7 @@
 			"style": {
 				"navigationBarTitleText": "添加信息"
 			}
-		},  {
+		}, {
 			"path": "subscribelSuccess",
 			"style": {
 				"navigationBarTitleText": "新增成功"
@@ -92,7 +90,7 @@
 			"style": {
 				"navigationBarTitleText": "分享有礼"
 			}
-		},  {
+		}, {
 			"path": "evaluateList",
 			"style": {
 				"navigationBarTitleText": "我的评价"

+ 5 - 5
pages/index/index.vue

@@ -108,11 +108,11 @@
 			});
 		},
 		onShow() {
-			if (!uni.getStorageSync('token')) {
-				uni.navigateTo({
-					url: '/pages/login/index'
-				});
-			}
+			// if (!uni.getStorageSync('token')) {
+			// 	uni.navigateTo({
+			// 		url: '/pages/login/index'
+			// 	});
+			// }
 		},
 		onPullDownRefresh() {
 			this.initialize()

+ 6 - 0
pagesMain/openMember.vue

@@ -148,6 +148,12 @@
 				this.memberInfo.typeValue = options.typeValue
 			}
 		},
+		onUnload(){
+			console.log('1111')
+		},
+		onBackPress(){
+			console.log('2222')
+		},
 		onShow() {
 			NET.request(API.getAllVenueList, uni.getStorageSync('locationData'), 'POST').then(res => {
 				this.venueList = res.data

+ 1 - 1
utils/request.js

@@ -24,7 +24,7 @@ const request = (url, data, method = 'GET') => {
 					let data = res.data
 					if (data.status == 30001) {
 						uni.removeStorageSync('token')
-						uni.navigateTo({
+						uni.reLaunch({
 							url: '/pages/login/index'
 						});
 						return false