mirror of
https://github.com/go-gitea/gitea.git
synced 2024-06-29 01:45:30 +00:00
Change private/public to visibility
This commit is contained in:
parent
7365adaef7
commit
872ff2aa5d
|
@ -940,7 +940,7 @@ func SettingsPost(ctx *context.Context) {
|
|||
log.Trace("Repository was un-archived: %s/%s", ctx.Repo.Owner.Name, repo.Name)
|
||||
ctx.Redirect(ctx.Repo.RepoLink + "/settings")
|
||||
|
||||
case "private", "public":
|
||||
case "visibility":
|
||||
if repo.IsFork {
|
||||
ctx.Flash.Error(ctx.Tr("repo.settings.visibility.fork_error"))
|
||||
ctx.Redirect(ctx.Repo.RepoLink + "/settings")
|
||||
|
|
|
@ -1036,7 +1036,7 @@
|
|||
</div>
|
||||
<form action="{{.Link}}" method="post">
|
||||
{{.CsrfTokenHtml}}
|
||||
<input type="hidden" name="action" value="{{if .Repository.IsPrivate}}public{{else}}private{{end}}">
|
||||
<input type="hidden" name="action" value="visibility">
|
||||
<input type="hidden" name="repo_id" value="{{.Repository.ID}}">
|
||||
{{template "base/modal_actions_confirm" .}}
|
||||
</form>
|
||||
|
|
Loading…
Reference in New Issue
Block a user