mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-11 20:44:55 +00:00
Update checker setting updates
- revertc53f802778
- enable by default on install page - save checkbox state between form submissions Resolves https://codeberg.org/forgejo/forgejo/issues/2859 (cherry picked from commite498069fd5
)
This commit is contained in:
parent
f1016e8ddd
commit
71efe9b8fc
|
@ -159,6 +159,7 @@ func Install(ctx *context.Context) {
|
||||||
form.DefaultAllowCreateOrganization = setting.Service.DefaultAllowCreateOrganization
|
form.DefaultAllowCreateOrganization = setting.Service.DefaultAllowCreateOrganization
|
||||||
form.DefaultEnableTimetracking = setting.Service.DefaultEnableTimetracking
|
form.DefaultEnableTimetracking = setting.Service.DefaultEnableTimetracking
|
||||||
form.NoReplyAddress = setting.Service.NoReplyAddress
|
form.NoReplyAddress = setting.Service.NoReplyAddress
|
||||||
|
form.EnableUpdateChecker = true
|
||||||
form.PasswordAlgorithm = hash.ConfigHashAlgorithm(setting.PasswordHashAlgo)
|
form.PasswordAlgorithm = hash.ConfigHashAlgorithm(setting.PasswordHashAlgo)
|
||||||
|
|
||||||
middleware.AssignForm(form, ctx.Data)
|
middleware.AssignForm(form, ctx.Data)
|
||||||
|
|
|
@ -147,7 +147,7 @@ func registerUpdateGiteaChecker() {
|
||||||
}
|
}
|
||||||
RegisterTaskFatal("update_checker", &UpdateCheckerConfig{
|
RegisterTaskFatal("update_checker", &UpdateCheckerConfig{
|
||||||
BaseConfig: BaseConfig{
|
BaseConfig: BaseConfig{
|
||||||
Enabled: false,
|
Enabled: true,
|
||||||
RunAtStart: false,
|
RunAtStart: false,
|
||||||
Schedule: "@every 168h",
|
Schedule: "@every 168h",
|
||||||
},
|
},
|
||||||
|
|
|
@ -150,7 +150,7 @@
|
||||||
<div class="inline field">
|
<div class="inline field">
|
||||||
<div class="ui checkbox">
|
<div class="ui checkbox">
|
||||||
<label>{{ctx.Locale.Tr "install.enable_update_checker"}}</label>
|
<label>{{ctx.Locale.Tr "install.enable_update_checker"}}</label>
|
||||||
<input name="enable_update_checker" type="checkbox">
|
<input name="enable_update_checker" type="checkbox" {{if .enable_update_checker}}checked{{end}}>
|
||||||
</div>
|
</div>
|
||||||
<span class="help">{{ctx.Locale.Tr "install.enable_update_checker_helper_forgejo"}}</span>
|
<span class="help">{{ctx.Locale.Tr "install.enable_update_checker_helper_forgejo"}}</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue