diff options
author | Jonas Franz <info@jonasfranz.software> | 2019-04-17 10:18:16 +0200 |
---|---|---|
committer | Lunny Xiao <xiaolunwen@gmail.com> | 2019-04-17 16:18:16 +0800 |
commit | 7a4c29c739fa9b08f901220ebcb2948daf491692 (patch) | |
tree | 73e44404a6c13061b832624582e230eedb801c3c /routers/routes/routes.go | |
parent | 34548369e1d78eb1141aecd4ab02acf59f2949ae (diff) | |
download | gitea-7a4c29c739fa9b08f901220ebcb2948daf491692.tar.gz gitea-7a4c29c739fa9b08f901220ebcb2948daf491692.zip |
OAuth2 Grant UI (#6625)
* Add oauth2 grants ui
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Add delete functionality
Add translations
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Fix unit tests
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Fix unit tests
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Refactor DeleteOAuth2Grant
Use results.Close()
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Refactor DeleteOAuth2Grant (again)
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Check if user ID is zero
Signed-off-by: Jonas Franz <info@jonasfranz.software>
* Check if grant ID is zero
Signed-off-by: Jonas Franz <info@jonasfranz.software>
Diffstat (limited to 'routers/routes/routes.go')
-rw-r--r-- | routers/routes/routes.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/routers/routes/routes.go b/routers/routes/routes.go index 5c6d36befa..9602bbed4a 100644 --- a/routers/routes/routes.go +++ b/routers/routes/routes.go @@ -344,6 +344,7 @@ func RegisterRoutes(m *macaron.Macaron) { m.Post("/:id/regenerate_secret", userSetting.OAuthApplicationsRegenerateSecret) m.Post("", bindIgnErr(auth.EditOAuth2ApplicationForm{}), userSetting.OAuthApplicationsPost) m.Post("/delete", userSetting.DeleteOAuth2Application) + m.Post("/revoke", userSetting.RevokeOAuth2Grant) }) m.Combo("/applications").Get(userSetting.Applications). Post(bindIgnErr(auth.NewAccessTokenForm{}), userSetting.ApplicationsPost) |