diff --git a/src/HttpServer/logic/datadef.go b/src/HttpServer/logic/datadef.go index f967dd9..3a1f5c7 100644 --- a/src/HttpServer/logic/datadef.go +++ b/src/HttpServer/logic/datadef.go @@ -730,16 +730,16 @@ type LimitListDesc struct { } type GetMainPageInfoData struct { - LimitCatList []LimitListDesc `json:"limitCatList"` - CatList []CatPosInfo `json:"catList"` - Coin DoBuyCatCoin `json:"coin"` - AdRate adRateData `json:"adRate"` - Level int `json:"level"` - TotalCashReward float32 `json:"totalCashReward"` - Guide bool `json:"guide"` - Redbagnum int `json:"redbagnum"` - Flyboxnum int `json:"flyboxnum"` - Leftredbagnum int `json:"leftredbagnum"` + LimitCatList []int `json:"limitCatList"` + CatList []CatPosInfo `json:"catList"` + Coin DoBuyCatCoin `json:"coin"` + AdRate adRateData `json:"adRate"` + Level int `json:"level"` + TotalCashReward float32 `json:"totalCashReward"` + Guide bool `json:"guide"` + Redbagnum int `json:"redbagnum"` + Flyboxnum int `json:"flyboxnum"` + Leftredbagnum int `json:"leftredbagnum"` } type GetMainPageInfoResp struct { diff --git a/src/HttpServer/logic/function.go b/src/HttpServer/logic/function.go index 4e88ee2..7ca1b4f 100644 --- a/src/HttpServer/logic/function.go +++ b/src/HttpServer/logic/function.go @@ -1019,8 +1019,8 @@ func (u *UserData) CalcHigestCatName() string { } //获取红包猫列表 -func (u *UserData) GetRedCatIdList() []LimitListDesc { - var rtsl []LimitListDesc +func (u *UserData) GetRedCatIdList() []int { + var rtsl []int nowtime := int(time.Now().Unix()) for _, val := range u.PosInfo { if val.Cat > REDCATIDEXTRA && val.Cat < BOXGIFTEXTRA { @@ -1031,7 +1031,7 @@ func (u *UserData) GetRedCatIdList() []LimitListDesc { var tmp LimitListDesc tmp.Cat = val.Cat tmp.Money = val.RedPacket - rtsl = append(rtsl, tmp) + rtsl = append(rtsl, val.Cat) //需要删除 u.CleadPos(val.Position) } -- libgit2 0.21.0