qa: Add tested exercices to Todo list
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
3434535f51
commit
2cf9723c6c
@ -64,7 +64,22 @@ func getQATodo(u QAUser, ps httprouter.Params, body []byte) (interface{}, error)
|
|||||||
if team, err := fic.GetTeam(u.TeamId); err != nil {
|
if team, err := fic.GetTeam(u.TeamId); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
} else {
|
} else {
|
||||||
return team.GetQATodo()
|
todo, err := team.GetQATodo()
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
if exercices, err := fic.GetExercices(); err != nil {
|
||||||
|
return todo, nil
|
||||||
|
} else {
|
||||||
|
for _, exercice := range exercices {
|
||||||
|
if cnt, _ := team.CountTries(exercice); cnt > 0 {
|
||||||
|
todo = append(todo, fic.QATodo{0, team.Id, exercice.Id})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return todo, nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user