From 7e4068b2f8b175f535851ed44dbd246aec79f6fe Mon Sep 17 00:00:00 2001 From: hujiebin Date: Wed, 22 Mar 2023 12:27:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=8A=BF=E5=8A=9B=E4=B8=8A?= =?UTF-8?q?=E9=BA=A6=E6=97=B6=E9=95=BF-=E5=A4=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- domain/model/groupPower_m/group_grade.go | 2 +- domain/service/group_mic_s/group_mic.go | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/domain/model/groupPower_m/group_grade.go b/domain/model/groupPower_m/group_grade.go index 963d738..b8212e2 100644 --- a/domain/model/groupPower_m/group_grade.go +++ b/domain/model/groupPower_m/group_grade.go @@ -237,7 +237,7 @@ func IncrGroupPowerExpOnMic(model *domain.Model, groupPowerId, userId mysql.ID, // 增加势力上麦时长-家族之星 // 事务操作 -func IncrGroupPowerStarOnMic(model *domain.Model, groupPowerId, userId mysql.ID, joinMicTimestamp int64) error { +func IncrGroupPowerStarOnMicMonth(model *domain.Model, groupPowerId, userId mysql.ID, joinMicTimestamp int64) error { return model.Transaction(func(model *domain.Model) error { // 月统计 star, err := GetGroupPowerMonthStar(model, groupPowerId, userId, groupPower_e.GroupPowerStarTypeActive) diff --git a/domain/service/group_mic_s/group_mic.go b/domain/service/group_mic_s/group_mic.go index 0b8f25c..ed150b6 100644 --- a/domain/service/group_mic_s/group_mic.go +++ b/domain/service/group_mic_s/group_mic.go @@ -318,9 +318,13 @@ func (s *GroupMicService) IncrGroupPowerOnMicExpAndTime(groupId string, userId u if err := groupPower_m.IncrGroupPowerExpOnMic(model, groupPowerId, userId, joinMicTimestamp); err != nil { model.Log.Errorf("IncrGroupPowerExpOnMic fail:%v", err) } - // 增加势力上麦时长 - if err := groupPower_m.IncrGroupPowerStarOnMic(model, groupPowerId, userId, joinMicTimestamp); err != nil { - model.Log.Errorf("IncrGroupPowerOnMicTime fail:%v", err) + // 增加势力上麦时长-月 + if err := groupPower_m.IncrGroupPowerStarOnMicMonth(model, groupPowerId, userId, joinMicTimestamp); err != nil { + model.Log.Errorf("IncrGroupPowerStarOnMicMonth fail:%v", err) + } + // 增加势力上麦时长-天 + if err := groupPower_m.IncrGroupPowerStarOnMicDay(model, groupPowerId, userId, joinMicTimestamp); err != nil { + model.Log.Errorf("IncrGroupPowerStarOnMicDay fail:%v", err) } return nil } -- 2.22.0