Commit 02d91a2e authored by 邱旭's avatar 邱旭

1

parent aa72728f
...@@ -2211,7 +2211,7 @@ export class NetManager extends ABNetManager { ...@@ -2211,7 +2211,7 @@ export class NetManager extends ABNetManager {
const net: INetData = { const net: INetData = {
name: NetName.HBRAIN_BASEINFO, name: NetName.HBRAIN_BASEINFO,
uri: window['duiba'] +'/customActivity/happyclear/redRain/doJoin', uri: window['duiba'] +'/customActivity/happyclear/redRain/doJoin',
type: 'get', type: 'post',
dataType: 'json', dataType: 'json',
hideMsg: true, hideMsg: true,
param: { param: {
......
...@@ -6,8 +6,8 @@ ...@@ -6,8 +6,8 @@
<e:Image id="money" source="signprize元宝_png" y="423.2" horizontalCenter="1" scaleX="0.8" scaleY="0.8" visible="false"/> <e:Image id="money" source="signprize元宝_png" y="423.2" horizontalCenter="1" scaleX="0.8" scaleY="0.8" visible="false"/>
<e:Image id="blood" source="singprize体力_png" y="385.8" horizontalCenter="1" visible="false"/> <e:Image id="blood" source="singprize体力_png" y="385.8" horizontalCenter="1" visible="false"/>
<e:Group id="numsgroup" x="397.38" y="431.4" visible="false"> <e:Group id="numsgroup" x="397.38" y="431.4" visible="false">
<e:Image id="numsbg0" source="signprize_numsbg_png" x="0" y="0"/> <e:Image id="numsbg" source="signprize_numsbg_png" x="0" y="0"/>
<e:Label id="propnums0" text="X8" size="22" horizontalCenter="0" verticalCenter="0" verticalAlign="middle" textAlign="center"/> <e:Label id="propnums" text="X8" size="22" horizontalCenter="0" verticalCenter="0" verticalAlign="middle" textAlign="center"/>
</e:Group> </e:Group>
<e:Image id="prizeImg" y="422.5" source="" horizontalCenter="0" visible="false"/> <e:Image id="prizeImg" y="422.5" source="" horizontalCenter="0" visible="false"/>
<e:Button id="closeBtn" label="" x="597" y="284.33"> <e:Button id="closeBtn" label="" x="597" y="284.33">
......
...@@ -36,11 +36,11 @@ export default class HbCutTime extends Panel { ...@@ -36,11 +36,11 @@ export default class HbCutTime extends Panel {
return; return;
} }
let data = res.data; let data = res.data;
this.cutTimer = new CutTimer(this.cutTimeLabel, 'hh时mm分ss秒', () => this.hbRainBaseInfo()); this.cutTimer = new CutTimer(this.cutTimeLabel, 'hh时mm分ss秒', () => this.hidePanel());
let sysTime = res.timestamp; // 当前系统事件 let sysTime = res.timestamp; // 当前系统事件
let time; let time;
if(data.currentSession) { if(data.currentSession) {
time = data.currentSession.endTime - sysTime; time = data.currentSession.endTime - sysTime + 3000;
if(data.canJoin) { if(data.canJoin) {
this.ok_btn.source = 'hbCutTime_btn_enable_png'; this.ok_btn.source = 'hbCutTime_btn_enable_png';
this.ok_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this); this.ok_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
...@@ -54,7 +54,7 @@ export default class HbCutTime extends Panel { ...@@ -54,7 +54,7 @@ export default class HbCutTime extends Panel {
this.cutTimer.start(time); this.cutTimer.start(time);
} }
} else if(data.nextSession) { } else if(data.nextSession) {
time = data.nextSession.startTime - sysTime; time = data.nextSession.startTime - sysTime + 3000;
this.ok_btn.source = 'hbCutTime_btn_disable_png'; this.ok_btn.source = 'hbCutTime_btn_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this); this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
this.tipImage.source = 'hbCutTime_cutLine_disable_png'; this.tipImage.source = 'hbCutTime_cutLine_disable_png';
...@@ -70,11 +70,18 @@ export default class HbCutTime extends Panel { ...@@ -70,11 +70,18 @@ export default class HbCutTime extends Panel {
}) })
} }
destroy() {
this.cutTimer.stop();
super.destroy();
}
protected onSkinComplete() { protected onSkinComplete() {
} }
initEvents() { initEvents() {
super.initEvents(); super.initEvents();
this.addEventListener(egret.Event.REMOVED_FROM_STAGE, this.destroy, this);
this.closeBtn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchTap_closeBtn, this); this.closeBtn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchTap_closeBtn, this);
this.ok_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this); this.ok_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
this.rule_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.tapRuleBtn, this); this.rule_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.tapRuleBtn, this);
...@@ -86,6 +93,7 @@ export default class HbCutTime extends Panel { ...@@ -86,6 +93,7 @@ export default class HbCutTime extends Panel {
removeEvents() { removeEvents() {
super.removeEvents(); super.removeEvents();
this.removeEventListener(egret.Event.REMOVED_FROM_STAGE, this.destroy, this);
this.closeBtn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchTap_closeBtn, this); this.closeBtn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchTap_closeBtn, this);
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this); this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
this.rule_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.tapRuleBtn, this); this.rule_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.tapRuleBtn, this);
......
...@@ -112,10 +112,10 @@ export default class HbGame extends Panel { ...@@ -112,10 +112,10 @@ export default class HbGame extends Panel {
return; return;
} }
if(!data.option || data.categoryType == 1) { if(!data || !data.option || data.categoryType == 1) {
PanelCtrl.instance.show("HbNoPrize"); PanelCtrl.instance.show("HbNoPrize");
} else { } else {
PanelCtrl.instance.show('TurnPrizePanel', data); PanelCtrl.instance.show('HbPrize', data);
} }
}, session, this.score); }, session, this.score);
} }
......
{ {
"success": true,
"code": "0000000000", "code": "0000000000",
"desc": "OK",
"timestamp": 1572945948033,
"data": { "data": {
"option": { "option": {
"appItemId": 2322, "id": "218",
"categoryType": 1, "day": null,
"coinType": 1, "categoryType": 2,
"img": "//yun.dui88.com/images/201910/s0yhv1nlil.jpeg", "title": "10",
"maxValue": 2, "rate": "10",
"minValue": 1, "minValue": null,
"name": "测试商品", "maxValue": null,
"num": 3, "coinType": null,
"propType": 2, "realValue": null,
"rate": "概率", "propType": null,
"title": "商品信息", "num": 4,
"value": "虚拟商品标识符" "img": "",
}, "appItemId": null,
"orderNum": "1234232546" "name": "",
"value": ""
}, },
"desc": "OK", "orderNum": null
"success": true, }
"timestamp": 1572921692831
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment