张文飞 3 anni fa
parent
commit
d13bbf15c4
1 ha cambiato i file con 5 aggiunte e 3 eliminazioni
  1. 5 3
      App.vue

+ 5 - 3
App.vue

@@ -18,13 +18,13 @@
 				window.location.href = url;
 			}
 			this.globalData.BASE_URL = config.BASE_URL;
-		},
-		onShow: function() {
 			let shareToken  = this.getQueryString('shareToken');
 			let projectId  = this.getQueryString('projectId');
 			this.globalData.projectId = projectId||'';
 			this.globalData.shareToken = shareToken||'';
 			this.regist();
+		},
+		onShow: function() {
 			document.body.style.setProperty("background-color",this.globalData.color4);
 		},
 		onHide: function() {
@@ -59,7 +59,9 @@
 						uni.$emit('request')
 					}else{
 						//注册失败,去掉老的code,会进入onLaunch,重新获取新的code
-						let url = location.origin+location.pathname;
+						let projectId  = this.getQueryString('projectId'); 
+						let shareToken  = this.getQueryString('shareToken'); 
+						let url = location.origin+location.pathname + "?projectId="+projectId+"&shareToken="+shareToken;
 						window.location.href = url;
 					}
 				}