1
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-11-04 08:17:24 -05:00
gitea/routers
Cirno the Strongest 0159851cc3
Rework api/user/repos for pagination (#11827)
* Add count to `GetUserRepositories` so that pagination can be supported for `/user/{username}/repos`
* Rework ListMyRepos to use models.SearchRepository

ListMyRepos was an odd one. It first fetched all user repositories and then tried to supplement them with accessible map. The end result was that:

* Limit for pagination did not work because accessible repos would always be appended
* The amount of pages was incorrect if one were to calculate it
* When paginating, all accessible repos would be shown on every page

Hopefully it should now work properly. Fixes #11800 and does not require any change on Drone-side as it can properly interpret and act on Link header which we now set.

Co-authored-by: Lauris BH <lauris@nix.lv>
2020-06-13 12:35:59 +01:00
..
admin Refactor Cron and merge dashboard tasks (#10745) 2020-05-16 19:31:38 -04:00
api/v1 Rework api/user/repos for pagination (#11827) 2020-06-13 12:35:59 +01:00
dev
events Add EventSource support (#11235) 2020-05-07 22:49:00 +01:00
org Fix visibility of forked public repos from private orgs (#11717) 2020-06-06 20:45:12 -04:00
private Protect default branch against deletion (#11115) 2020-05-06 12:08:45 +01:00
repo Handle more pathological branch and tag names (#11843) 2020-06-11 19:49:47 -04:00
routes Move serviceworker to workbox and fix SSE interference (#11538) 2020-05-21 21:45:34 -04:00
user Add hide activity option (#11353) 2020-06-05 16:01:53 -04:00
utils
home.go Ensure public repositories in private organizations are visible and fix admin organizations list (#11465) 2020-05-18 00:27:54 +01:00
init.go Refactor Cron and merge dashboard tasks (#10745) 2020-05-16 19:31:38 -04:00
install.go Whenever the ctx.Session is updated, release it to save it before sending the redirect (#11456) 2020-05-17 15:43:29 +03:00
metrics.go
swagger_json.go