mzx16822 6 jaren geleden
bovenliggende
commit
fa1b5c7cd0
1 gewijzigde bestanden met toevoegingen van 2 en 1 verwijderingen
  1. 2 1
      public/h5/datigame/js/common.js

+ 2 - 1
public/h5/datigame/js/common.js

@@ -81,6 +81,7 @@ common={
  			case 'init':
  			 _this.data.client_id=data.client_id;
  			_this.bdSocket(function(res){
+ 				_this.data.isReady=1;
  				console.log(res.msg);
  			});
  			    break;
@@ -103,7 +104,7 @@ common={
  		}
  	 	//_this.data.question_id
  	},startGame:function(){
- 		if(this.userInfo.user_id)
+ 		if(this.data.isReady=="1")
  		this.Join();
  		else this.tips("登录失败");
  	},initSocket:function(){