Commit 5163e0f6 authored by wildfirecode13's avatar wildfirecode13

11

parent 6b9e17c8
......@@ -3,10 +3,10 @@
"data": {
"needPop":0,
"activityOver": false,
"surplusCount": 1,
"credits": 10,
"surplusCount": 0,
"credits": 222,
"needCredits": 111,
"type": 1,
"type": 2,
"options": [{
"degree": null,
"icon": "//yun.duiba.com.cn/images/202108/ma00scey0f.png",
......
......@@ -8,6 +8,8 @@ import getQueryParams from "../common/getQueryParams";
import TestButton from "../common/TestButton";
import { isMember } from "../isMember";
import { getTimesPanel } from "../panels/getTimes";
import { notEnoughMoneySharePanel } from "../panels/notEnoughMoneyShare";
import { notEnoughMoneyShareHasTimesPanel } from "../panels/notEnoughMoneyShareHasTimes";
import { RulePanel } from "../panels/RulePanel";
import { SharePanel } from "../panels/share";
import { timesNotEnoughPanel } from "../panels/timesNotEnough";
......@@ -185,10 +187,29 @@ export class IndexScene extends Scene {
}
handleShare = async () => {
if (indexData.data.type == 2 && indexData.data.surplusCount <= 0) {
showPanel(timesNotEnoughPanel);
// if (indexData.data.type == 2 && indexData.data.surplusCount <= 0) {
// showPanel(timesNotEnoughPanel);
// } else {
// showPanel(getTimesPanel);
// }
if (indexData.data.type == 1) {
if (indexData.data.surplusCount <= 0) { //没次数
showPanel(notEnoughMoneySharePanel);
} else {
if (indexData.data.needCredits > indexData.data.credits) {
showPanel(notEnoughMoneyShareHasTimesPanel);
} else {
}
}
} else {
showPanel(getTimesPanel);
if (indexData.data.surplusCount > 0) {//有次数
} else {
}
}
}
......@@ -228,6 +249,7 @@ export class IndexScene extends Scene {
getBoxButton.visible = true;
shareButton.visible = false;
if (result.data.needCredits > result.data.credits) {
hand.visible = true;
getBoxButton.visible = false;
shareButton.visible = true;
}
......
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