forked from vikunja/vikunja
/namespaces/{namespaceID}/teams now also returns the team right
This commit is contained in:
parent
db54309df4
commit
5fbf63bddc
@ -12,10 +12,9 @@ func (tn *TeamNamespace) ReadAll(user *User) (interface{}, error) {
|
||||
}
|
||||
|
||||
// Get the teams
|
||||
all := []*Team{}
|
||||
all := []*teamWithRight{}
|
||||
|
||||
err = x.Select("teams.*").
|
||||
Table("teams").
|
||||
err = x.Table("teams").
|
||||
Join("INNER", "team_namespaces", "team_id = teams.id").
|
||||
Where("team_namespaces.namespace_id = ?", tn.NamespaceID).
|
||||
Find(&all)
|
||||
|
Loading…
x
Reference in New Issue
Block a user