美食城图鉴红点
This commit is contained in:
parent
ae9f9f42b7
commit
a38670f4c5
@ -486,6 +486,9 @@ const (
|
|||||||
Reddot24101 ReddotType = 24101 // 主线章节有奖励没领取
|
Reddot24101 ReddotType = 24101 // 主线章节有奖励没领取
|
||||||
// 好友
|
// 好友
|
||||||
Reddot21101 ReddotType = 21101 //当好友申请存在时,一级位置:好友界面左边申请列表图标上右上角位置 当好友申请处理完红点消失
|
Reddot21101 ReddotType = 21101 //当好友申请存在时,一级位置:好友界面左边申请列表图标上右上角位置 当好友申请处理完红点消失
|
||||||
|
|
||||||
|
//23101 烹饪
|
||||||
|
Reddot23101 ReddotType = 23101 // 烹饪奖励菜谱图鉴图标
|
||||||
)
|
)
|
||||||
|
|
||||||
type TaskType int32
|
type TaskType int32
|
||||||
|
@ -44,3 +44,15 @@ func (this *modelAtlas) getGourmetAtlasList(uid string) (result *pb.DBGourmetAtl
|
|||||||
func (this *modelAtlas) modifyGourmetAtlasByObjId(uid string, data map[string]interface{}) error {
|
func (this *modelAtlas) modifyGourmetAtlasByObjId(uid string, data map[string]interface{}) error {
|
||||||
return this.Change(uid, data)
|
return this.Change(uid, data)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 美食城图鉴红点
|
||||||
|
func (this *modelAtlas) checkReddot2301(uid string) bool {
|
||||||
|
if rst, err := this.getGourmetAtlasList(uid); err == nil {
|
||||||
|
for _, v := range rst.Atlas {
|
||||||
|
if v == -1 {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
@ -44,7 +44,17 @@ func (this *Gourmet) OnInstallComp() {
|
|||||||
|
|
||||||
//红点查询
|
//红点查询
|
||||||
func (this *Gourmet) Reddot(session comm.IUserSession, rid ...comm.ReddotType) (reddot map[comm.ReddotType]*pb.ReddotItem) {
|
func (this *Gourmet) Reddot(session comm.IUserSession, rid ...comm.ReddotType) (reddot map[comm.ReddotType]*pb.ReddotItem) {
|
||||||
|
reddot = make(map[comm.ReddotType]*pb.ReddotItem)
|
||||||
|
for _, v := range rid {
|
||||||
|
switch v {
|
||||||
|
case comm.Reddot23101: // 铁匠铺手册台
|
||||||
|
reddot[comm.Reddot23101] = &pb.ReddotItem{
|
||||||
|
Rid: int32(comm.Reddot23101),
|
||||||
|
Activated: this.modelAtlas.checkReddot2301(session.GetUserId()),
|
||||||
|
}
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user