forgejo/modules/repository
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
..
commits.go Make AvatarRenderedSizeFactor configurable and set it to 3 (#17951) 2021-12-16 10:18:38 +08:00
commits_test.go Make AvatarRenderedSizeFactor configurable and set it to 3 (#17951) 2021-12-16 10:18:38 +08:00
create.go Some repository refactors (#17950) 2021-12-12 23:48:20 +08:00
create_test.go Add GetUserTeams (#18499) (#18531) 2022-02-02 08:40:04 +00:00
generate.go Some repository refactors (#17950) 2021-12-12 23:48:20 +08:00
hooks.go Move some functions into services/repository (#17677) 2021-11-17 23:17:31 +08:00
init.go Some repository refactors (#17950) 2021-12-12 23:48:20 +08:00
main_test.go Decouple unit test code from business code (#17623) 2021-11-12 22:36:47 +08:00
push.go Move repository model into models/repo (#17933) 2021-12-10 09:27:50 +08:00
repo.go Fix NPE on try to get tag reference via API (#18245) 2022-01-12 20:37:46 +00:00