2015-03-04 21:07:02 +00:00
|
|
|
package db
|
|
|
|
|
2015-03-06 10:00:04 +00:00
|
|
|
type Team struct {
|
2015-03-06 11:18:15 +00:00
|
|
|
ID uint64 `json:"id"`
|
2015-03-06 10:00:04 +00:00
|
|
|
Owner string `json:"owner"`
|
|
|
|
Name string `json:"name"`
|
|
|
|
}
|
|
|
|
|
|
|
|
const orgTeamsQuery = `select * from teams where owner = ?`
|
|
|
|
|
|
|
|
func OrgTeams(login string) (teams []*Team) {
|
2015-03-06 11:29:52 +00:00
|
|
|
mustSelect(&teams, orgTeamsQuery, login)
|
2015-03-06 10:00:04 +00:00
|
|
|
return
|
|
|
|
}
|