mirror of
https://github.com/go-gitea/gitea.git
synced 2026-09-08 14:03:24 +09:00
Backport #33549 - Find the runner before deleting - Move the main logic from `routers/web/repo/setting/runners.go` to `routers/web/shared/actions/runners.go`. Co-authored-by: Jason Song <i@wolfogre.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
co-authored by
Jason Song
wxiaoguang
parent
7c17d0a73e
commit
7794ff0874
+6
-6
@@ -460,11 +460,11 @@ func registerRoutes(m *web.Router) {
|
||||
|
||||
addSettingsRunnersRoutes := func() {
|
||||
m.Group("/runners", func() {
|
||||
m.Get("", repo_setting.Runners)
|
||||
m.Combo("/{runnerid}").Get(repo_setting.RunnersEdit).
|
||||
Post(web.Bind(forms.EditRunnerForm{}), repo_setting.RunnersEditPost)
|
||||
m.Post("/{runnerid}/delete", repo_setting.RunnerDeletePost)
|
||||
m.Post("/reset_registration_token", repo_setting.ResetRunnerRegistrationToken)
|
||||
m.Get("", shared_actions.Runners)
|
||||
m.Combo("/{runnerid}").Get(shared_actions.RunnersEdit).
|
||||
Post(web.Bind(forms.EditRunnerForm{}), shared_actions.RunnersEditPost)
|
||||
m.Post("/{runnerid}/delete", shared_actions.RunnerDeletePost)
|
||||
m.Post("/reset_registration_token", shared_actions.ResetRunnerRegistrationToken)
|
||||
})
|
||||
}
|
||||
|
||||
@@ -1133,7 +1133,7 @@ func registerRoutes(m *web.Router) {
|
||||
})
|
||||
})
|
||||
m.Group("/actions", func() {
|
||||
m.Get("", repo_setting.RedirectToDefaultSetting)
|
||||
m.Get("", shared_actions.RedirectToDefaultSetting)
|
||||
addSettingsRunnersRoutes()
|
||||
addSettingsSecretsRoutes()
|
||||
addSettingsVariablesRoutes()
|
||||
|
||||
Reference in New Issue
Block a user