1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-03 09:07:19 +00:00

Extract common code to new template (#26933)

Same as #26903
This commit is contained in:
Kerwin Bryant
2023-09-06 18:11:06 +08:00
committed by GitHub
parent 7812ce86dc
commit 9b0743ae33
5 changed files with 32 additions and 46 deletions

View File

@ -1,5 +1,7 @@
{{template "user/settings/layout_head" (dict "ctxData" . "pageClass" "user settings new webhook")}}
<div class="user-setting-content">
{{template "webhook/new" .}}
{{$CustomHeaderTitle := .locale.Tr "repo.settings.update_webhook"}}
{{if .PageIsSettingsHooksNew}}{{$CustomHeaderTitle = .locale.Tr "repo.settings.add_webhook"}}{{end}}
{{template "webhook/new" (dict "ctxData" . "CustomHeaderTitle" $CustomHeaderTitle)}}
</div>
{{template "user/settings/layout_footer" .}}