lilei 4 år sedan
förälder
incheckning
4e4a3e203e
1 ändrade filer med 8 tillägg och 9 borttagningar
  1. 8 9
      pages/login/login.vue

+ 8 - 9
pages/login/login.vue

@@ -84,7 +84,7 @@ export default {
 		AndroidCheckUpdate(){
 			let _this = this
 			getSysVersion().then(ret => {
-				// console.log(JSON.stringify(ret))
+				console.log(JSON.stringify(ret))
 				if(ret.status == 200){
 					this.$store.state.vuex_versionInfo = ret.data
 					let currTimeStamp = new Date(ret.data.publicDate).getTime();
@@ -98,16 +98,15 @@ export default {
 							// 强制更新
 							if(ret.data.forceUpgrade == 1){
 								tipTimeLength = 0
-							}
-							console.log(lastTimeStamp+tipTimeLength>currTimeStamp)
-							if((lastTimeStamp+tipTimeLength) > currTimeStamp){
-								//避免多次提醒,不要更新
-								console.log("避免多次提醒,不要更新");
-							}else{
-								//重新设置时间戳
-								setStorageForAppVersion(currTimeStamp);
 								//进行版本型号的比对 以及下载更新请求
 								checkVersionToLoadUpdate(ret.data,0,market);
+							}else{
+								if((lastTimeStamp+tipTimeLength) <= currTimeStamp){
+									//重新设置时间戳
+									setStorageForAppVersion(currTimeStamp);
+									//进行版本型号的比对 以及下载更新请求
+									checkVersionToLoadUpdate(ret.data,0,market);
+								}
 							}
 						},
 						fail:function(res){