瀏覽代碼

幸运星抓手逻辑修改

guessPrice
sui 5 年之前
父節點
當前提交
51b139aade
共有 1 個文件被更改,包括 9 次插入10 次删除
  1. +9
    -10
      496_dongfengqichen/pages/luckyStar/luckyStar.js

+ 9
- 10
496_dongfengqichen/pages/luckyStar/luckyStar.js 查看文件

gameSign: null, //游戏结束时需要 gameSign: null, //游戏结束时需要
gameState:false,//游戏状态 gameState:false,//游戏状态
endGameData:null,//中奖数据 endGameData:null,//中奖数据
isRegister:false,//是否已注册
isAddress:false,//是否有地址
}, },


/** /**
onLoad: function (options) { onLoad: function (options) {
app.globalData.nowPage = 3; app.globalData.nowPage = 3;
if (app.globalData.openid) { if (app.globalData.openid) {
this.getOrderInfo();
this.endGame();
this.getAddress();
} else { } else {
app.globalData.openidSuccessFuc = this.getOrderInfo;
app.globalData.openidSuccessFuc = this.getAddress;
} }
}, },


pizeTip: 1 pizeTip: 1
}) })
} else { } else {
if (this.data.isRegister) {
if (this.data.isAddress) {
this.setData({ this.setData({
pizeTip: 2 pizeTip: 2
}) })
}) })
} }
}, },
getOrderInfo: function () {//查询是否已注册
app.wxRequest(app.globalData.urlRoot +"userInfo/getOrderInfo",{},res=>{
if(res.code==200){
getAddress: function () {//获取地址
app.wxRequest(app.globalData.urlRoot + "userInfo/getOrderInfo", {}, res => {
if (res.code == 200) {
if (res.data) { if (res.data) {
this.data.isRegister = true;
this.data.isAddress = true;
} }
} }
},this)
}, this)
}, },
receive:function(){//立即领取 receive:function(){//立即领取
wx.redirectTo({ wx.redirectTo({

Loading…
取消
儲存