Commit 7b8238b4 authored by chenweijian's avatar chenweijian

群组优化

parent 9eaa60e5
...@@ -105,7 +105,7 @@ func groupSupportAddConsume(model *domain.Model, sendGiftEvent *gift_ev.SendGift ...@@ -105,7 +105,7 @@ func groupSupportAddConsume(model *domain.Model, sendGiftEvent *gift_ev.SendGift
} }
_, _, period := group_m.GetSupportLevelTime(time.Now()) _, _, period := group_m.GetSupportLevelTime(time.Now())
// 钻石数 // 钻石数
diamond := sendGiftEvent.GiftN * sendGiftEvent.ResGift.DiamondNum diamond := sendGiftEvent.GiftN * sendGiftEvent.ResGift.DiamondNum * mysql.Num(len(sendGiftEvent.ReceiveUserIds))
keyDiamond := rediskey.GetGroupSupportConsumeSummary(period) keyDiamond := rediskey.GetGroupSupportConsumeSummary(period)
_, err := model.RedisCluster.ZIncrBy(context.Background(), keyDiamond, float64(diamond), sendGiftEvent.SceneUid).Result() _, err := model.RedisCluster.ZIncrBy(context.Background(), keyDiamond, float64(diamond), sendGiftEvent.SceneUid).Result()
if err != nil { if err != nil {
......
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