Commit 2ada8061 authored by 邱旭's avatar 邱旭

m

parent 83f45667
......@@ -3,6 +3,9 @@
<component name="ChangeListManager">
<list default="true" id="0d3cb18d-e144-41a0-bc8b-4877c2e1fef1" name="默认的" comment="">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/output.js" beforeDir="false" afterPath="$PROJECT_DIR$/output.js" afterDir="false" />
<change beforePath="$PROJECT_DIR$/output.js.map" beforeDir="false" afterPath="$PROJECT_DIR$/output.js.map" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/TaoBaoNet.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/TaoBaoNet.ts" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/panels/HelpPanel.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/panels/HelpPanel.ts" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
......@@ -62,7 +65,7 @@
<recent name="$PROJECT_DIR$/lotties" />
</key>
</component>
<component name="RunManager" selected="npm.build">
<component name="RunManager" selected="npm.buildTS">
<configuration name="build" type="js.build_tools.npm" temporary="true" nameIsGenerated="true">
<package-json value="$PROJECT_DIR$/package.json" />
<command value="run" />
......@@ -111,10 +114,10 @@
</list>
<recent_temporary>
<list>
<item itemvalue="npm.buildTS" />
<item itemvalue="npm.build" />
<item itemvalue="npm.dev" />
<item itemvalue="npm.flushRes" />
<item itemvalue="npm.buildTS" />
</list>
</recent_temporary>
</component>
......@@ -131,7 +134,7 @@
<workItem from="1612662929222" duration="40609000" />
<workItem from="1613698993022" duration="22309000" />
<workItem from="1613785579125" duration="17751000" />
<workItem from="1613958457445" duration="16219000" />
<workItem from="1613958457445" duration="18038000" />
</task>
<task id="LOCAL-00001" summary="斐乐消消乐">
<created>1612581213298</created>
......@@ -462,7 +465,14 @@
<option name="project" value="LOCAL" />
<updated>1614070959025</updated>
</task>
<option name="localTasksCounter" value="48" />
<task id="LOCAL-00048" summary="m">
<created>1614074400505</created>
<option name="number" value="00048" />
<option name="presentableId" value="LOCAL-00048" />
<option name="project" value="LOCAL" />
<updated>1614074400505</updated>
</task>
<option name="localTasksCounter" value="49" />
<servers />
</component>
<component name="TypeScriptGeneratedFilesManager">
......
......@@ -11289,6 +11289,19 @@ var HelpPanel = (function (_super) {
configurable: true
});
HelpPanel.prototype.initUi = function () {
return __awaiter(this, void 0, void 0, function () {
var _a;
return __generator(this, function (_b) {
switch (_b.label) {
case 0:
_a = this;
return [4, this.queryVip()];
case 1:
_a.vip = _b.sent();
return [2];
}
});
});
};
HelpPanel.prototype.start = function (data) {
var _this = this;
......@@ -11307,30 +11320,34 @@ var HelpPanel = (function (_super) {
};
HelpPanel.prototype.doHelp = function () {
return __awaiter(this, void 0, void 0, function () {
var _a, vipSuc, vipInfo;
var _this = this;
return __generator(this, function (_b) {
switch (_b.label) {
return __generator(this, function (_a) {
switch (_a.label) {
case 0:
if (Tools_1.Tools.globalData.inviteId == Tools_1.Tools.globalData.openId) {
ctrls_1.showToast('自己不能给自己助力');
this.hidePanel();
return [2];
}
if (this.vip) {
this.hidePanel();
return [2];
}
return [4, TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.queryVipInfo)];
return [4, this.queryVip()];
case 1:
_a = _b.sent(), vipSuc = _a.success, vipInfo = _a.data;
if (vipSuc && vipInfo.isvip) {
if (_a.sent()) {
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.doHelp, { inviteId: Tools_1.Tools.globalData.inviteId }, function (success, res) {
if (!success) {
ctrls_1.showToast(res.message);
_this.hidePanel();
return;
}
ctrls_1.showToast('接受成功');
ctrls_1.showToast('接受邀请成功');
_this.hidePanel();
});
}
else {
ctrls_1.showToast('请入会后参与');
ctrls_1.showToast('请先加入会员');
setTimeout(function () {
TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.openMember);
}, 1500);
......@@ -11340,6 +11357,19 @@ var HelpPanel = (function (_super) {
});
});
};
HelpPanel.prototype.queryVip = function () {
return __awaiter(this, void 0, void 0, function () {
var _a, success, data;
return __generator(this, function (_b) {
switch (_b.label) {
case 0: return [4, TaoBaoNet_1.sendTbNet(TaoBaoNet_1.TbNetName.queryVipInfo)];
case 1:
_a = _b.sent(), success = _a.success, data = _a.data;
return [2, success && data.isvip];
}
});
});
};
HelpPanel.prototype.initEvents = function () {
_super.prototype.initEvents.call(this);
};
This diff is collapsed.
......@@ -18,7 +18,7 @@ export enum TbNetName {
doHelp = "feile.doHelp",
queryVipInfo = "feile.queryVipInfo",
getVipInfo = "feile.getVipInfo",
/**
* 活动基本信息
......
......@@ -68,7 +68,7 @@ export class HelpPanel extends Panel {
}
async queryVip() {
const { success, data } = await sendTbNet(TbNetName.queryVipInfo);
const { success, data } = await sendTbNet(TbNetName.getVipInfo);
return success && data.isvip;
}
......
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