Commit 5af5e654ef0ba6beaadd2569ddc7cde23bb92592
1 parent
c543d57f
Exists in
master
and in
4 other branches
提交
Showing
3 changed files
with
11 additions
and
0 deletions
Show diff stats
src/HttpServer/logic/datadef.go
@@ -353,6 +353,7 @@ type UserData struct { | @@ -353,6 +353,7 @@ type UserData struct { | ||
353 | UpLvCostTime int //上一个等级升级时间 | 353 | UpLvCostTime int //上一个等级升级时间 |
354 | UpLvCostTimeSec int //上一个等级升级的时间点时刻 | 354 | UpLvCostTimeSec int //上一个等级升级的时间点时刻 |
355 | ReadNum int //玩家微转发阅读量 | 355 | ReadNum int //玩家微转发阅读量 |
356 | + GetCashCnt int //当天提现次数 | ||
356 | WithDraw WithDrawInfo //提现记录信息 | 357 | WithDraw WithDrawInfo //提现记录信息 |
357 | Task TaskInfo //玩家任务完成相关信息 | 358 | Task TaskInfo //玩家任务完成相关信息 |
358 | Achieve AchieveMentInfo //玩家成就完成相关数据 | 359 | Achieve AchieveMentInfo //玩家成就完成相关数据 |
src/HttpServer/logic/function.go
@@ -668,6 +668,7 @@ func (u *UserData) HandlePassDay(uuid int, channel string) { | @@ -668,6 +668,7 @@ func (u *UserData) HandlePassDay(uuid int, channel string) { | ||
668 | u.WatchAddsTime = WATCH_ADD_DAY_LIMIT | 668 | u.WatchAddsTime = WATCH_ADD_DAY_LIMIT |
669 | //todo 重置任务相关的数据 | 669 | //todo 重置任务相关的数据 |
670 | u.GetFromGuanCnt = 0 | 670 | u.GetFromGuanCnt = 0 |
671 | + u.GetCashCnt = 0 | ||
671 | 672 | ||
672 | u.Task.GetGuanGold = 0 | 673 | u.Task.GetGuanGold = 0 |
673 | u.Task.GetRedbagCnt = 0 | 674 | u.Task.GetRedbagCnt = 0 |
src/HttpServer/logic/logic.go
@@ -179,6 +179,14 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { | @@ -179,6 +179,14 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { | ||
179 | } | 179 | } |
180 | } | 180 | } |
181 | 181 | ||
182 | + //如果是2.2.7版本开启提现次数限制 | ||
183 | + if rdata.Ver == "2.2.7" && uinfo.GetCashCnt > 0 { | ||
184 | + logger.Error("HandlerGetcash GetCashCnt err=%v", err) | ||
185 | + resp.Message = "当天已经提现过了,请明天再来" | ||
186 | + resp.Code = ERROR_PRENOTFINISH | ||
187 | + break | ||
188 | + } | ||
189 | + | ||
182 | //2.2.5版本开启自动审核 | 190 | //2.2.5版本开启自动审核 |
183 | checkcoin := 2 | 191 | checkcoin := 2 |
184 | if rdata.Ver == "2.2.5" { | 192 | if rdata.Ver == "2.2.5" { |
@@ -209,6 +217,7 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { | @@ -209,6 +217,7 @@ func HandlerGetcash(w http.ResponseWriter, data string, uuid int) { | ||
209 | break | 217 | break |
210 | }*/ | 218 | }*/ |
211 | 219 | ||
220 | + uinfo.GetCashCnt++ | ||
212 | if info.Isnew == 1 { | 221 | if info.Isnew == 1 { |
213 | uinfo.WithDraw.Cashdata[index].Isnew = 0 | 222 | uinfo.WithDraw.Cashdata[index].Isnew = 0 |
214 | } | 223 | } |