Commit 9a8973dc authored by haiyoucuv's avatar haiyoucuv

init

parent 1cc93271
...@@ -8,6 +8,7 @@ export default [ ...@@ -8,6 +8,7 @@ export default [
message: "", message: "",
timeStamp: Date.now(), timeStamp: Date.now(),
data: { data: {
drawEndTime: Date.now() + 999999,
titleImg: "titleImg", titleImg: "titleImg",
interval: "interval", interval: "interval",
amount: Math.random() * 100000 >> 0, amount: Math.random() * 100000 >> 0,
......
...@@ -36,9 +36,12 @@ class TurnTable extends React.Component { ...@@ -36,9 +36,12 @@ class TurnTable extends React.Component {
// 开始抽奖 // 开始抽奖
drawHandle = _asyncThrottle(async () => { drawHandle = _asyncThrottle(async () => {
if (!store.judgeActTime()) return
if (this.btnStarting) return false; if (this.btnStarting) return false;
if (store.indexData.currentTime >= resStore.info.drawEndTime) {
return Toast.show("活动已结束");
}
if (resStore.info.remainDrawTime <= 0) { if (resStore.info.remainDrawTime <= 0) {
return Toast.show("已抽过奖哦"); return Toast.show("已抽过奖哦");
} }
......
...@@ -15,6 +15,7 @@ class ResStore { ...@@ -15,6 +15,7 @@ class ResStore {
profit: 0, profit: 0,
cycle: "", cycle: "",
remainDrawTime: 0, remainDrawTime: 0,
drawEndTime: 0,
prizeInfo: [], prizeInfo: [],
cycleStartTime: 0, cycleStartTime: 0,
cycleEndTime: 0, cycleEndTime: 0,
......
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