修复关注人数,进入直播间退出bug

master
kanade 5 years ago
parent 05c8df1a1b
commit 2375eec7cb

@ -162,8 +162,9 @@ func (l *live) Stop(userId, liveItemId uint) error {
})
ImLogic.SendLiveGroupMessage(liveItem.RoomId, LiveGroupMsgTypeLiveStop, gin.H{
"praise": liveData.Praise,
"look": liveData.Look,
"liveItemId": liveItem.Id,
"praise": liveData.Praise,
"look": liveData.Look,
})
return nil
})

@ -80,11 +80,11 @@ func (u *UserFollow) RenewFollow(userId, followUserId uint) int64 {
Where("is_del = ?", 1).Update("is_Del", 0).RowsAffected
}
// @Title 获取会员离职关注数据
// @Title 获取会员被关注过数据
func (u *UserFollow) GetCountAll(userId uint) (result int64) {
if userId <= 0 {
return
}
u.GetDb().Model(u).Where(UserFollow{}).Where("user_id = ?", userId).Count(&result)
u.GetDb().Model(u).Where(UserFollow{}).Where("follow_user_id = ?", userId).Count(&result)
return
}

Loading…
Cancel
Save