gitea/routers/api/v1/org
zeripath 9c318a17f5
Add `GetUserTeams` (#18499) (#18531)
Backport #18499

* Correct use `UserID` in `SearchTeams`

- Use `UserID` in the `SearchTeams` function, currently it was useless
to pass such information. Now it does a INNER statement to `team_user`
which obtains UserID -> TeamID data.
- Make OrgID optional.
- Resolves #18484

* Seperate searching specific user

* Add condition back

* Use correct struct type

Co-authored-by: Gusted <williamzijl7@hotmail.com>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: techknowlogick <techknowlogick@gitea.io>
2022-02-02 08:40:04 +00:00
..
hook.go Use a standalone struct name for Organization (#17632) 2021-11-19 19:41:40 +08:00
label.go Use a standalone struct name for Organization (#17632) 2021-11-19 19:41:40 +08:00
member.go Remove unnecessary attributes of User struct (#17745) 2021-11-22 23:21:55 +08:00
org.go Move accessmode into models/perm (#17828) 2021-11-28 12:58:28 +01:00
team.go Add `GetUserTeams` (#18499) (#18531) 2022-02-02 08:40:04 +00:00