Commit 399b3d5a authored by wildfirecode's avatar wildfirecode

1

parent 40294174
......@@ -53,7 +53,7 @@
<script>
// window['pageID'] = 'TeamShareScene';
// window['pageID'] = 'JoinShareScene';
window['pageID'] = 'TransScene';
// window['pageID'] = 'TransScene';
// window['pageID'] = 'Share2Scene';
window['TransLink']='';
window['projectId'] = "1";
......
......@@ -1552,7 +1552,14 @@ export class NetManager extends ABNetManager {
// }
// }
stopPolling(){
if(this._pollingTimer) {
clearTimeout(this._pollingTimer);
this._pollingTimer = 0;
}
}
// onNotSuccess: Function;
_pollingTimer;
onResponse(net, result) {
var _this = this;
//数据处理
......@@ -1561,7 +1568,7 @@ export class NetManager extends ABNetManager {
if (net.pollingCount && net.pollingCheck(data)) {
net.pollingCount -= 1;
//轮询接口特殊处理
setTimeout(function () {
this._pollingTimer = setTimeout(function () {
_this.send(net);
}, 500);
}
......
......@@ -7,6 +7,7 @@
<e:Image id="shareTips" source="transfer _toast3_png" horizontalCenter="0" x="139" scaleX="1" scaleY="1" verticalCenter="0" y="10" visible="false"/>
</e:Group>
<e:Image id="transbtn" source="sharestarter_btn_png" x="622" y="27"/>
<e:Button id="backBtn" label="Button" skinName="ui.IconButtonSkin" icon="backstartBtn_png" width="104" height="40" scaleX="1" scaleY="1" anchorOffsetX="52" anchorOffsetY="20" x="52" y="50"/>
<e:Group id="tipsWrapper" x="142" bottom="55">
<e:Image id="sharebtn" source="sharestarter_sharebtn_png" x="38" y="0"/>
<e:Label text="每传递一个新用户, 可获得100分数" y="117" x="0"/>
......
......@@ -14,6 +14,7 @@ export default class ShareStarterScene extends Scene {
_standby: SVGA.EgretMovieClip;
_trans: SVGA.EgretMovieClip;
_shareCode;
_playingAni=false;
protected get skinKey() { return 'ShareStarter' }
constructor(data) {
super();
......@@ -101,6 +102,7 @@ export default class ShareStarterScene extends Scene {
}
this['matchingTips'].visible = true;
this._playingAni=true;
NetManager.ins.yyh_pollingAnimationState((success) => {
const data = DataManager.ins.getData('yyh_pollingAnimationState').data;
if (data.state == 3) {//摇一摇
......@@ -122,7 +124,16 @@ export default class ShareStarterScene extends Scene {
})
}, window['projectId'])
}
onTap_backbtn(){
if(this._playingAni) {
NetManager.ins.stopPolling();
}else {
yzwNet.homeBaseInfo((s) => {
let data = DataManager.ins.getData("homeBaseInfo").data;
SceneCtrl.instance.change(ModuleTypes.START_SCENE, data);
}, window['projectId'])
}
}
onTap_transbtn() {
PanelCtrl.instance.show(ModuleTypes.TransRecordPanel)
}
......@@ -130,5 +141,8 @@ export default class ShareStarterScene extends Scene {
initEvents() {
this.onTap(this['transbtn'], this.onTap_transbtn);
this.onTap(this['sharebtn'], this.onTap_sharebtn);
this.onTap(this['backBtn'], this.onTap_backbtn);
}
}
\ No newline at end of file
......@@ -3,7 +3,7 @@
"data": {
"inviterUserId": "500412018",
"inviteeUserId": "500412019",
"state": "3",
"state": "0",
"inviterPhone": 123,
"inviteePhone": 456
},
......
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