diff --git a/domain/model/mic_m/mic.go b/domain/model/mic_m/mic.go index d83f144c4d8ad7973b2097256d3dd0f42673358b..36d51a5d75f62f1cd2e28cf28d3d8b8ef2bb0aef 100644 --- a/domain/model/mic_m/mic.go +++ b/domain/model/mic_m/mic.go @@ -25,7 +25,7 @@ type UserOnMic struct { // 允许返回gorm.ErrRecordNotFound func GetUserOnMic(model *domain.Model, userId mysql.ID, tz timezone_e.Timezone) (*UserOnMic, error) { res := new(UserOnMic) - day := time.Now().Format("2006-01-02") + day := time.Now().In(timezone_e.TimezoneLocMap[tz]).Format("2006-01-02") if err := model.DB().Where("date = ? AND user_id = ? AND tz = ?", day, userId, tz).First(res).Error; err != nil { return nil, err } diff --git a/domain/service/event_s/event_init.go b/domain/service/event_s/event_init.go index dcbfbd579f2f20e8b3314aa554f0693d07860332..ca3d376a6bc1a1d7350fa20e5a9b53e823d59ba6 100644 --- a/domain/service/event_s/event_init.go +++ b/domain/service/event_s/event_init.go @@ -553,6 +553,8 @@ func OnMic() { } else { model.Log.Infof("cron micIn IncrUserOnMic success,userId:%v", event.UserId) } + // 处理活动数据 + go rpc.AddActPoint(model, event.UserId, 1) return nil }) }