作者 xuqiang

提交

@@ -538,6 +538,18 @@ @@ -538,6 +538,18 @@
538 } 538 }
539 }, 539 },
540 onShow(){ 540 onShow(){
  541 + if(!this.isWechat()){
  542 + uni.showToast({
  543 + title:'请在微信内置浏览器里打开!',
  544 + icon:'none',
  545 + duration:3000
  546 + })
  547 + return
  548 + }
  549 + if(uni.getStorageSync('Token') == ''){
  550 + this.checkWeChatCode()//通过微信官方接口获取code之后,会重新刷新设置的回调地址【redirect_uri】]
  551 + return
  552 + }
541 innerAudioContext = uni.createInnerAudioContext(); 553 innerAudioContext = uni.createInnerAudioContext();
542 innerAudioContext.autoplay = true; 554 innerAudioContext.autoplay = true;
543 innerAudioContext.loop = true; 555 innerAudioContext.loop = true;
@@ -554,18 +566,6 @@ @@ -554,18 +566,6 @@
554 innerAudioContext.destroy() 566 innerAudioContext.destroy()
555 }, 567 },
556 onLoad(option) { 568 onLoad(option) {
557 - if(!this.isWechat()){  
558 - uni.showToast({  
559 - title:'请在微信内置浏览器里打开!',  
560 - icon:'none',  
561 - duration:3000  
562 - })  
563 - return  
564 - }  
565 - if(uni.getStorageSync('Token') == ''){  
566 - this.checkWeChatCode()//通过微信官方接口获取code之后,会重新刷新设置的回调地址【redirect_uri】]  
567 - return  
568 - }  
569 this.temp = parseInt(option.temp) 569 this.temp = parseInt(option.temp)
570 this.ob_id = option.ob_id 570 this.ob_id = option.ob_id
571 //On(发布状态:0=未发布,1=已发布 ) 571 //On(发布状态:0=未发布,1=已发布 )