diff --git a/common/currency.go b/common/currency.go index 4822605..1ddd446 100644 --- a/common/currency.go +++ b/common/currency.go @@ -34,6 +34,8 @@ const ( CurrencyResourceThirdRecharge // 第三次充 CurrencyResourceVipBonus // vip奖励 CurrencyResourceRechargeWithBonus // 一般充值(有bonus) + CurrencyResourceDayBack + CurrencyResourceAll ) diff --git a/modules/web/handler/activity.go b/modules/web/handler/activity.go index 4ee4147..491529f 100644 --- a/modules/web/handler/activity.go +++ b/modules/web/handler/activity.go @@ -656,7 +656,7 @@ func ActivityFirstRechargeBackInfo(c *gin.Context) { return } if data.Reward == 0 { // 计算奖励 - val := data.Amount - call.GetUserCurrencyTotal(a.UID, common.CurrencyINR) - rechargeInfo.WithdrawingCash + val := data.Amount - call.GetUserCurrencyTotal(a.UID, common.CurrencyINR) - rechargeInfo.TotalWithdraw - rechargeInfo.WithdrawingCash if val < 0 { val = 0 } @@ -716,7 +716,7 @@ func ActivityFirstRechargeBackDraw(c *gin.Context) { return } rechargeInfo := call.GetRechargeInfo(a.UID) - val := data.Amount - call.GetUserCurrencyTotal(a.UID, common.CurrencyINR) - rechargeInfo.WithdrawingCash + val := data.Amount - call.GetUserCurrencyTotal(a.UID, common.CurrencyINR) - rechargeInfo.TotalWithdraw - rechargeInfo.WithdrawingCash if val < 0 { val = 0 } @@ -736,7 +736,7 @@ func ActivityFirstRechargeBackDraw(c *gin.Context) { Type: common.CurrencyINR, Value: val, Event: common.CurrencyEventActivityFirstRechargeBack, - NeedBet: call.GetConfigCurrencyResourceNeedBet(common.CurrencyResourceBonus, val), + NeedBet: call.GetConfigCurrencyResourceNeedBet(common.CurrencyResourceDayBack, val), }, }) if err != nil { diff --git a/modules/web/handler/share.go b/modules/web/handler/share.go index 4d27827..3d264b7 100644 --- a/modules/web/handler/share.go +++ b/modules/web/handler/share.go @@ -892,7 +892,7 @@ func ShareWithdraw(c *gin.Context) { Value: req.Amount, Event: common.CurrencyEventShare, Type: common.CurrencyINR, - NeedBet: call.GetConfigCurrencyResourceNeedBet(common.CurrencyResourceBonus, req.Amount, 1), + NeedBet: call.GetConfigCurrencyResourceNeedBet(common.CurrencyResourceShare, req.Amount), }, }) if err != nil {