Commit b5540360 authored by hujiebin's avatar hujiebin

fix:二级以上才有进场特效

parent f2f086fe
...@@ -304,10 +304,12 @@ func GetUserCpEntryEffect(c *gin.Context) (*mycontext.MyContext, error) { ...@@ -304,10 +304,12 @@ func GetUserCpEntryEffect(c *gin.Context) (*mycontext.MyContext, error) {
privilegeList[i].UserSwitch = userPrivileges[userId][v.Type] privilegeList[i].UserSwitch = userPrivileges[userId][v.Type]
} }
} }
// 我的特权,有开关并且打开才返回 // 二级以上才有进场特效
for _, v := range privilegeList { if cpLevel >= cp_e.CpLevel2 {
if v.Type == cp_e.CpPrivilegeRoomEffect && v.UserSwitch { for _, v := range privilegeList {
response.CpEntryEffect = true if v.Type == cp_e.CpPrivilegeRoomEffect && v.UserSwitch {
response.CpEntryEffect = true
}
} }
} }
if cpUser, _ := user_c.GetUserTinyById(model, cpUserId); cpUser != nil { if cpUser, _ := user_c.GetUserTinyById(model, cpUserId); cpUser != 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