diff options
-rw-r--r-- | routers/web/repo/repo.go | 2 | ||||
-rw-r--r-- | services/forms/repo_form.go | 8 | ||||
-rw-r--r-- | templates/repo/create.tmpl | 26 |
3 files changed, 2 insertions, 34 deletions
diff --git a/routers/web/repo/repo.go b/routers/web/repo/repo.go index cd5eac057e..b5c550ae45 100644 --- a/routers/web/repo/repo.go +++ b/routers/web/repo/repo.go @@ -288,7 +288,7 @@ func CreatePost(ctx *context.Context) { DefaultBranch: form.DefaultBranch, AutoInit: form.AutoInit, IsTemplate: form.Template, - TrustModel: repo_model.ToTrustModel(form.TrustModel), + TrustModel: repo_model.DefaultTrustModel, ObjectFormatName: form.ObjectFormatName, }) if err == nil { diff --git a/services/forms/repo_form.go b/services/forms/repo_form.go index 780fc88000..845eccf817 100644 --- a/services/forms/repo_form.go +++ b/services/forms/repo_form.go @@ -21,13 +21,6 @@ import ( "gitea.com/go-chi/binding" ) -// _______________________________________ _________.______________________ _______________.___. -// \______ \_ _____/\______ \_____ \ / _____/| \__ ___/\_____ \\______ \__ | | -// | _/| __)_ | ___// | \ \_____ \ | | | | / | \| _// | | -// | | \| \ | | / | \/ \| | | | / | \ | \\____ | -// |____|_ /_______ / |____| \_______ /_______ /|___| |____| \_______ /____|_ // ______| -// \/ \/ \/ \/ \/ \/ \/ - // CreateRepoForm form for creating repository type CreateRepoForm struct { UID int64 `binding:"Required"` @@ -50,7 +43,6 @@ type CreateRepoForm struct { Avatar bool Labels bool ProtectedBranch bool - TrustModel string ForkSingleBranch string ObjectFormatName string diff --git a/templates/repo/create.tmpl b/templates/repo/create.tmpl index 7b2e51130f..3b4b994be7 100644 --- a/templates/repo/create.tmpl +++ b/templates/repo/create.tmpl @@ -61,7 +61,7 @@ </div> <div class="inline field {{if .Err_Description}}error{{end}}"> <label for="description">{{ctx.Locale.Tr "repo.repo_desc"}}</label> - <textarea id="description" name="description" placeholder="{{ctx.Locale.Tr "repo.repo_desc_helper"}}" maxlength="2048">{{.description}}</textarea> + <textarea id="description" rows="2" name="description" placeholder="{{ctx.Locale.Tr "repo.repo_desc_helper"}}" maxlength="2048">{{.description}}</textarea> </div> <div class="inline field"> <label>{{ctx.Locale.Tr "repo.template"}}</label> @@ -186,29 +186,6 @@ <span class="help">{{ctx.Locale.Tr "repo.default_branch_helper"}}</span> </div> <div class="inline field"> - <label>{{ctx.Locale.Tr "repo.settings.trust_model"}}</label> - <div class="ui selection owner dropdown"> - <input type="hidden" id="trust_model" name="trust_model" value="default" required> - <div class="default text">{{ctx.Locale.Tr "repo.settings.trust_model"}}</div> - {{svg "octicon-triangle-down" 14 "dropdown icon"}} - <div class="menu"> - <div class="item" data-value="default">{{ctx.Locale.Tr "repo.settings.trust_model.default"}}</div> - <div class="item" data-value="collaborator">{{ctx.Locale.Tr "repo.settings.trust_model.collaborator"}}</div> - <div class="item" data-value="committer">{{ctx.Locale.Tr "repo.settings.trust_model.committer"}}</div> - <div class="item" data-value="collaboratorcommitter">{{ctx.Locale.Tr "repo.settings.trust_model.collaboratorcommitter"}}</div> - </div> - </div> - <div class="help"> - {{ctx.Locale.Tr "repo.trust_model_helper"}} - <ul> - <li>{{ctx.Locale.Tr "repo.trust_model_helper_collaborator"}}</li> - <li>{{ctx.Locale.Tr "repo.trust_model_helper_committer"}}</li> - <li>{{ctx.Locale.Tr "repo.trust_model_helper_collaborator_committer"}}</li> - <li>{{ctx.Locale.Tr "repo.trust_model_helper_default"}}</li> - </ul> - </div> - </div> - <div class="inline field"> <label>{{ctx.Locale.Tr "repo.template"}}</label> <div class="ui checkbox"> <input name="template" type="checkbox"> @@ -216,7 +193,6 @@ </div> </div> </div> - <br> <div class="inline field"> <label></label> |