diff options
author | JakobDev <jakobdev@gmx.de> | 2023-03-28 20:22:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-28 14:22:07 -0400 |
commit | f384b13f1cd44be3a87df5553a0099390dacd010 (patch) | |
tree | 08b2744df3a8792ef2f50e4d559d55e4a349c198 /routers/api/v1/api.go | |
parent | 5cd1d6c93ba9b8399f826e671b8940eb5294b872 (diff) | |
download | gitea-f384b13f1cd44be3a87df5553a0099390dacd010.tar.gz gitea-f384b13f1cd44be3a87df5553a0099390dacd010.zip |
Implement Issue Config (#20956)
Closes #20955
This PR adds the possibility to disable blank Issues, when the Repo has
templates. This can be done by creating the file
`.gitea/issue_config.yaml` with the content `blank_issues_enabled` in
the Repo.
Diffstat (limited to 'routers/api/v1/api.go')
-rw-r--r-- | routers/api/v1/api.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/routers/api/v1/api.go b/routers/api/v1/api.go index 7d1980baeb..8b13f5492c 100644 --- a/routers/api/v1/api.go +++ b/routers/api/v1/api.go @@ -1169,6 +1169,8 @@ func Routes(ctx gocontext.Context) *web.Route { }, reqAdmin()) }, reqAnyRepoReader()) m.Get("/issue_templates", context.ReferencesGitRepo(), repo.GetIssueTemplates) + m.Get("/issue_config", context.ReferencesGitRepo(), repo.GetIssueConfig) + m.Get("/issue_config/validate", context.ReferencesGitRepo(), repo.ValidateIssueConfig) m.Get("/languages", reqRepoReader(unit.TypeCode), repo.GetLanguages) }, repoAssignment()) }) |