diff --git a/route/group_r/group_list.go b/route/group_r/group_list.go index 8b60bba8baf3a357df1c5a828e01292824c3fe95..1bd231cbf3bc4d10700d2b4299d7355b72ac53ff 100644 --- a/route/group_r/group_list.go +++ b/route/group_r/group_list.go @@ -327,6 +327,16 @@ func GetPopularGroups(c *gin.Context) (*mycontext.MyContext, error) { } medals := make([]medal_cv.PicElement, 0) + + // 补上房间流水勋章 + var pe *medal_cv.PicElement + _, pe, err = medal_cv.GetGroupConsumeMedal(model, i.ImGroupId) + if err != nil { + model.Log.Infof("GetPopularGroups: GetGroupConsumeMedal: %s", err.Error()) + } else if pe != nil { + medals = append(medals, medal_cv.PicElement{PicUrl: pe.PicUrl}) + } + if m, ok := groupMedals[i.ImGroupId]; ok { for _, j := range m { mId := uint32(j) @@ -338,15 +348,6 @@ func GetPopularGroups(c *gin.Context) (*mycontext.MyContext, error) { } } - // 补上房间流水勋章 - var pe *medal_cv.PicElement - _, pe, err = medal_cv.GetGroupConsumeMedal(model, i.ImGroupId) - if err != nil { - model.Log.Infof("GetPopularGroups: GetGroupConsumeMedal: %s", err.Error()) - } else if pe != nil { - medals = append(medals, medal_cv.PicElement{PicUrl: pe.PicUrl}) - } - var password *string = nil if len(i.Password) > 0 && i.Owner != myUserId { emptyStr := ""