This commit is contained in:
yangduo 2024-12-10 14:25:57 +08:00
parent b431f02ab0
commit bc1517797c
2 changed files with 7 additions and 4 deletions

View File

@ -51,6 +51,7 @@ func (this *UserApi) Login(c *gin.Context) {
return return
} }
f5.GetMsgQueue().FireEvent(constant.MSG_CREATE_USER, q5.Args{user}) f5.GetMsgQueue().FireEvent(constant.MSG_CREATE_USER, q5.Args{user})
service.Task.List(s.GetAccountId(), nil)
} else { } else {
earning := service.Chip.CalcScore(s.GetAccountId()) earning := service.Chip.CalcScore(s.GetAccountId())
if earning > 0 { if earning > 0 {

View File

@ -110,10 +110,12 @@ func (this *task) List(accountId string, data *[]*vo.Mission) (errcode int32, ms
tasksupdate = false tasksupdate = false
} }
for _, taskitem := range tasks { if data != nil {
missionVo := new(vo.Mission) for _, taskitem := range tasks {
missionVo.FromModel(taskitem) missionVo := new(vo.Mission)
q5.AppendSlice(data, missionVo) missionVo.FromModel(taskitem)
q5.AppendSlice(data, missionVo)
}
} }
if tasksupdate { if tasksupdate {