diff --git a/templates/admin/applications/list.tmpl b/templates/admin/applications/list.tmpl index a292051fd..cbb66b160 100644 --- a/templates/admin/applications/list.tmpl +++ b/templates/admin/applications/list.tmpl @@ -1,7 +1,7 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin config")}}

- {{.locale.Tr "settings.applications"}} + {{ctx.Locale.Tr "settings.applications"}}

{{template "user/settings/applications_oauth2_list" .}}
diff --git a/templates/admin/auth/edit.tmpl b/templates/admin/auth/edit.tmpl index 814bddd8a..25abefae0 100644 --- a/templates/admin/auth/edit.tmpl +++ b/templates/admin/auth/edit.tmpl @@ -1,7 +1,7 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin edit authentication")}}

- {{.locale.Tr "admin.auths.edit"}} + {{ctx.Locale.Tr "admin.auths.edit"}}

@@ -9,12 +9,12 @@ {{.CsrfTokenHtml}}
- + {{.Source.TypeName}}
- +
@@ -22,7 +22,7 @@ {{if or .Source.IsLDAP .Source.IsDLDAP}} {{$cfg:=.Source.Cfg}}
- +
- +
- +
- +
{{if .Source.IsLDAP}}
- +
- +
{{end}}
- +
{{if .Source.IsDLDAP}}
- +
{{end}}
- +
- +
- + -

{{.locale.Tr "admin.auths.restricted_filter_helper"}}

+

{{ctx.Locale.Tr "admin.auths.restricted_filter_helper"}}

- - + +
- +
- +
- +
- +
- +
- +
- +
- +
- +
- +
- +
- +
@@ -144,31 +144,31 @@ {{if .Source.IsLDAP}}
- +
- +
- +
{{end}}
- + -

{{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

+

{{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

- +
@@ -178,7 +178,7 @@ {{if .Source.IsSMTP}} {{$cfg:=.Source.Cfg}}
- +
- +
- +
- +
-

{{.locale.Tr "admin.auths.force_smtps_helper"}}

+

{{ctx.Locale.Tr "admin.auths.force_smtps_helper"}}

- +
- + -

{{.locale.Tr "admin.auths.helo_hostname_helper"}}

+

{{ctx.Locale.Tr "admin.auths.helo_hostname_helper"}}

- +
- + -

{{.locale.Tr "admin.auths.allowed_domains_helper"}}

+

{{ctx.Locale.Tr "admin.auths.allowed_domains_helper"}}

- + -

{{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

+

{{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

{{end}} @@ -240,18 +240,18 @@ {{if .Source.IsPAM}} {{$cfg:=.Source.Cfg}}
- +
- +
- + -

{{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

+

{{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

{{end}} @@ -260,7 +260,7 @@ {{if .Source.IsOAuth2}} {{$cfg:=.Source.Cfg}}
- +
- +
- +
- +
- +
- + -

{{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

+

{{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

- +
- +
- +
- +
- +
- +
@@ -332,37 +332,37 @@ {{end}}{{end}}
- +
- + -

{{.locale.Tr "admin.auths.oauth2_required_claim_name_helper"}}

+

{{ctx.Locale.Tr "admin.auths.oauth2_required_claim_name_helper"}}

- + -

{{.locale.Tr "admin.auths.oauth2_required_claim_value_helper"}}

+

{{ctx.Locale.Tr "admin.auths.oauth2_required_claim_value_helper"}}

- +
- +
- +
- +
- +
{{end}} @@ -372,32 +372,32 @@ {{$cfg:=.Source.Cfg}}
- + -

{{.locale.Tr "admin.auths.sspi_auto_create_users_helper"}}

+

{{ctx.Locale.Tr "admin.auths.sspi_auto_create_users_helper"}}

- + -

{{.locale.Tr "admin.auths.sspi_auto_activate_users_helper"}}

+

{{ctx.Locale.Tr "admin.auths.sspi_auto_activate_users_helper"}}

- + -

{{.locale.Tr "admin.auths.sspi_strip_domain_names_helper"}}

+

{{ctx.Locale.Tr "admin.auths.sspi_strip_domain_names_helper"}}

- + -

{{.locale.Tr "admin.auths.sspi_separator_replacement_helper"}}

+

{{ctx.Locale.Tr "admin.auths.sspi_separator_replacement_helper"}}

- +
-

{{.locale.Tr "admin.auths.sspi_default_language_helper"}}

+

{{ctx.Locale.Tr "admin.auths.sspi_default_language_helper"}}

{{end}} {{if .Source.IsLDAP}}
- +
{{end}}
- +
- - + +

- {{.locale.Tr "admin.auths.tips"}} + {{ctx.Locale.Tr "admin.auths.tips"}}

GMail Settings:

Host: smtp.gmail.com, Port: 587, Enable TLS Encryption: true

-
{{.locale.Tr "admin.auths.tips.oauth2.general"}}:
-

{{.locale.Tr "admin.auths.tips.oauth2.general.tip"}}

+
{{ctx.Locale.Tr "admin.auths.tips.oauth2.general"}}:
+

{{ctx.Locale.Tr "admin.auths.tips.oauth2.general.tip"}}

diff --git a/templates/admin/auth/list.tmpl b/templates/admin/auth/list.tmpl index c9f7c0d51..fd9f69aec 100644 --- a/templates/admin/auth/list.tmpl +++ b/templates/admin/auth/list.tmpl @@ -1,9 +1,9 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin authentication")}}

- {{.locale.Tr "admin.auths.auth_manage_panel"}} ({{.locale.Tr "admin.total" .Total}}) + {{ctx.Locale.Tr "admin.auths.auth_manage_panel"}} ({{.locale.Tr "admin.total" .Total}})

@@ -11,12 +11,12 @@ ID - {{.locale.Tr "admin.auths.name"}} - {{.locale.Tr "admin.auths.type"}} - {{.locale.Tr "admin.auths.enabled"}} - {{.locale.Tr "admin.auths.updated"}} - {{.locale.Tr "admin.users.created"}} - {{.locale.Tr "admin.users.edit"}} + {{ctx.Locale.Tr "admin.auths.name"}} + {{ctx.Locale.Tr "admin.auths.type"}} + {{ctx.Locale.Tr "admin.auths.enabled"}} + {{ctx.Locale.Tr "admin.auths.updated"}} + {{ctx.Locale.Tr "admin.users.created"}} + {{ctx.Locale.Tr "admin.users.edit"}} diff --git a/templates/admin/auth/new.tmpl b/templates/admin/auth/new.tmpl index 31efa62e7..f32f77d5d 100644 --- a/templates/admin/auth/new.tmpl +++ b/templates/admin/auth/new.tmpl @@ -1,7 +1,7 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin new authentication")}}

- {{.locale.Tr "admin.auths.new"}} + {{ctx.Locale.Tr "admin.auths.new"}}

@@ -9,7 +9,7 @@ {{.CsrfTokenHtml}}
- +
- +
@@ -34,16 +34,16 @@
- + - +
- + -

{{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

+

{{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

@@ -55,67 +55,67 @@
- +
- +
- +
- +

- {{.locale.Tr "admin.auths.tips"}} + {{ctx.Locale.Tr "admin.auths.tips"}}

GMail Settings:

Host: smtp.gmail.com, Port: 587, Enable TLS Encryption: true

-
{{.locale.Tr "admin.auths.tips.oauth2.general"}}:
-

{{.locale.Tr "admin.auths.tips.oauth2.general.tip"}}

+
{{ctx.Locale.Tr "admin.auths.tips.oauth2.general"}}:
+

{{ctx.Locale.Tr "admin.auths.tips.oauth2.general.tip"}}

-
{{.locale.Tr "admin.auths.tip.oauth2_provider"}}
+
{{ctx.Locale.Tr "admin.auths.tip.oauth2_provider"}}
  • Bitbucket
  • - {{.locale.Tr "admin.auths.tip.bitbucket"}} + {{ctx.Locale.Tr "admin.auths.tip.bitbucket"}}
  • Dropbox
  • - {{.locale.Tr "admin.auths.tip.dropbox"}} + {{ctx.Locale.Tr "admin.auths.tip.dropbox"}}
  • Facebook
  • - {{.locale.Tr "admin.auths.tip.facebook"}} + {{ctx.Locale.Tr "admin.auths.tip.facebook"}}
  • GitHub
  • - {{.locale.Tr "admin.auths.tip.github"}} + {{ctx.Locale.Tr "admin.auths.tip.github"}}
  • GitLab
  • - {{.locale.Tr "admin.auths.tip.gitlab"}} + {{ctx.Locale.Tr "admin.auths.tip.gitlab"}}
  • Google
  • - {{.locale.Tr "admin.auths.tip.google_plus"}} + {{ctx.Locale.Tr "admin.auths.tip.google_plus"}}
  • OpenID Connect
  • - {{.locale.Tr "admin.auths.tip.openid_connect"}} + {{ctx.Locale.Tr "admin.auths.tip.openid_connect"}}
  • Twitter
  • - {{.locale.Tr "admin.auths.tip.twitter"}} + {{ctx.Locale.Tr "admin.auths.tip.twitter"}}
  • Discord
  • - {{.locale.Tr "admin.auths.tip.discord"}} + {{ctx.Locale.Tr "admin.auths.tip.discord"}}
  • Gitea
  • - {{.locale.Tr "admin.auths.tip.gitea"}} + {{ctx.Locale.Tr "admin.auths.tip.gitea"}}
  • Nextcloud
  • - {{.locale.Tr "admin.auths.tip.nextcloud"}} + {{ctx.Locale.Tr "admin.auths.tip.nextcloud"}}
  • Yandex
  • - {{.locale.Tr "admin.auths.tip.yandex"}} + {{ctx.Locale.Tr "admin.auths.tip.yandex"}}
  • Mastodon
  • - {{.locale.Tr "admin.auths.tip.mastodon"}} + {{ctx.Locale.Tr "admin.auths.tip.mastodon"}}
    diff --git a/templates/admin/auth/source/ldap.tmpl b/templates/admin/auth/source/ldap.tmpl index a2bd37be0..a584ac762 100644 --- a/templates/admin/auth/source/ldap.tmpl +++ b/templates/admin/auth/source/ldap.tmpl @@ -1,6 +1,6 @@
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - + -

    {{.locale.Tr "admin.auths.restricted_filter_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.restricted_filter_helper"}}

    - - + +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    - +
    @@ -117,24 +117,24 @@
    - +
    - +
    - + -

    {{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

    - +
    diff --git a/templates/admin/auth/source/oauth.tmpl b/templates/admin/auth/source/oauth.tmpl index aaa8b7fe2..63ad77e67 100644 --- a/templates/admin/auth/source/oauth.tmpl +++ b/templates/admin/auth/source/oauth.tmpl @@ -1,6 +1,6 @@
    - +
    - +
    - +
    - +
    - +
    - + -

    {{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

    - +
    - +
    - +
    - +
    - +
    - +
    @@ -73,37 +73,37 @@ {{end}}{{end}}
    - +
    - + -

    {{.locale.Tr "admin.auths.oauth2_required_claim_name_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.oauth2_required_claim_name_helper"}}

    - + -

    {{.locale.Tr "admin.auths.oauth2_required_claim_value_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.oauth2_required_claim_value_helper"}}

    - +
    - +
    - +
    - +
    - +
    diff --git a/templates/admin/auth/source/smtp.tmpl b/templates/admin/auth/source/smtp.tmpl index e83f7afb6..c4b0b0e7e 100644 --- a/templates/admin/auth/source/smtp.tmpl +++ b/templates/admin/auth/source/smtp.tmpl @@ -1,6 +1,6 @@
    - +
    - +
    - +
    - + -

    {{.locale.Tr "admin.auths.force_smtps_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.force_smtps_helper"}}

    - +
    - + -

    {{.locale.Tr "admin.auths.helo_hostname_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.helo_hostname_helper"}}

    - +
    - + -

    {{.locale.Tr "admin.auths.allowed_domains_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.allowed_domains_helper"}}

    - + -

    {{.locale.Tr "admin.auths.skip_local_two_fa_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.skip_local_two_fa_helper"}}

    diff --git a/templates/admin/auth/source/sspi.tmpl b/templates/admin/auth/source/sspi.tmpl index 9608616e1..f835e89bd 100644 --- a/templates/admin/auth/source/sspi.tmpl +++ b/templates/admin/auth/source/sspi.tmpl @@ -1,32 +1,32 @@
    - + -

    {{.locale.Tr "admin.auths.sspi_auto_create_users_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.sspi_auto_create_users_helper"}}

    - + -

    {{.locale.Tr "admin.auths.sspi_auto_activate_users_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.sspi_auto_activate_users_helper"}}

    - + -

    {{.locale.Tr "admin.auths.sspi_strip_domain_names_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.sspi_strip_domain_names_helper"}}

    - + -

    {{.locale.Tr "admin.auths.sspi_separator_replacement_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.sspi_separator_replacement_helper"}}

    - +
    -

    {{.locale.Tr "admin.auths.sspi_default_language_helper"}}

    +

    {{ctx.Locale.Tr "admin.auths.sspi_default_language_helper"}}

    diff --git a/templates/admin/base/search.tmpl b/templates/admin/base/search.tmpl index 22f839bf0..d4bba8c04 100644 --- a/templates/admin/base/search.tmpl +++ b/templates/admin/base/search.tmpl @@ -2,22 +2,22 @@
    {{template "shared/searchinput" dict "Value" .Keyword "AutoFocus" true}} - +
    diff --git a/templates/admin/config.tmpl b/templates/admin/config.tmpl index c29d1dbf3..57722f989 100644 --- a/templates/admin/config.tmpl +++ b/templates/admin/config.tmpl @@ -1,82 +1,82 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin config")}}

    - {{.locale.Tr "admin.config.server_config"}} + {{ctx.Locale.Tr "admin.config.server_config"}}

    -
    {{.locale.Tr "admin.config.app_name"}}
    +
    {{ctx.Locale.Tr "admin.config.app_name"}}
    {{AppName}}
    -
    {{.locale.Tr "admin.config.app_ver"}}
    +
    {{ctx.Locale.Tr "admin.config.app_ver"}}
    {{AppVer}}{{.AppBuiltWith}}
    -
    {{.locale.Tr "admin.config.custom_conf"}}
    +
    {{ctx.Locale.Tr "admin.config.custom_conf"}}
    {{.CustomConf}}
    -
    {{.locale.Tr "admin.config.app_url"}}
    +
    {{ctx.Locale.Tr "admin.config.app_url"}}
    {{.AppUrl}}
    -
    {{.locale.Tr "admin.config.domain"}}
    +
    {{ctx.Locale.Tr "admin.config.domain"}}
    {{.Domain}}
    -
    {{.locale.Tr "admin.config.offline_mode"}}
    +
    {{ctx.Locale.Tr "admin.config.offline_mode"}}
    {{if .OfflineMode}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.disable_router_log"}}
    +
    {{ctx.Locale.Tr "admin.config.disable_router_log"}}
    {{if .DisableRouterLog}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.run_user"}}
    +
    {{ctx.Locale.Tr "admin.config.run_user"}}
    {{.RunUser}}
    -
    {{.locale.Tr "admin.config.run_mode"}}
    +
    {{ctx.Locale.Tr "admin.config.run_mode"}}
    {{.RunMode}}
    -
    {{.locale.Tr "admin.config.git_version"}}
    +
    {{ctx.Locale.Tr "admin.config.git_version"}}
    {{.GitVersion}}
    -
    {{.locale.Tr "admin.config.app_data_path"}}
    +
    {{ctx.Locale.Tr "admin.config.app_data_path"}}
    {{.AppDataPath}}
    -
    {{.locale.Tr "admin.config.repo_root_path"}}
    +
    {{ctx.Locale.Tr "admin.config.repo_root_path"}}
    {{.RepoRootPath}}
    -
    {{.locale.Tr "admin.config.custom_file_root_path"}}
    +
    {{ctx.Locale.Tr "admin.config.custom_file_root_path"}}
    {{.CustomRootPath}}
    -
    {{.locale.Tr "admin.config.log_file_root_path"}}
    +
    {{ctx.Locale.Tr "admin.config.log_file_root_path"}}
    {{.LogRootPath}}
    -
    {{.locale.Tr "admin.config.script_type"}}
    +
    {{ctx.Locale.Tr "admin.config.script_type"}}
    {{.ScriptType}}
    -
    {{.locale.Tr "admin.config.reverse_auth_user"}}
    +
    {{ctx.Locale.Tr "admin.config.reverse_auth_user"}}
    {{.ReverseProxyAuthUser}}

    - {{.locale.Tr "admin.config.ssh_config"}} + {{ctx.Locale.Tr "admin.config.ssh_config"}}

    -
    {{.locale.Tr "admin.config.ssh_enabled"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_enabled"}}
    {{if not .SSH.Disabled}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{if not .SSH.Disabled}} -
    {{.locale.Tr "admin.config.ssh_start_builtin_server"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_start_builtin_server"}}
    {{if .SSH.StartBuiltinServer}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.ssh_domain"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_domain"}}
    {{.SSH.Domain}}
    -
    {{.locale.Tr "admin.config.ssh_port"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_port"}}
    {{.SSH.Port}}
    -
    {{.locale.Tr "admin.config.ssh_listen_port"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_listen_port"}}
    {{.SSH.ListenPort}}
    {{if not .SSH.StartBuiltinServer}} -
    {{.locale.Tr "admin.config.ssh_root_path"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_root_path"}}
    {{.SSH.RootPath}}
    -
    {{.locale.Tr "admin.config.ssh_key_test_path"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_key_test_path"}}
    {{.SSH.KeyTestPath}}
    -
    {{.locale.Tr "admin.config.ssh_keygen_path"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_keygen_path"}}
    {{.SSH.KeygenPath}}
    -
    {{.locale.Tr "admin.config.ssh_minimum_key_size_check"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_minimum_key_size_check"}}
    {{if .SSH.MinimumKeySizeCheck}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{if .SSH.MinimumKeySizeCheck}} -
    {{.locale.Tr "admin.config.ssh_minimum_key_sizes"}}
    +
    {{ctx.Locale.Tr "admin.config.ssh_minimum_key_sizes"}}
    {{.SSH.MinimumKeySizes}}
    {{end}} {{end}} @@ -85,160 +85,160 @@

    - {{.locale.Tr "admin.config.lfs_config"}} + {{ctx.Locale.Tr "admin.config.lfs_config"}}

    -
    {{.locale.Tr "admin.config.lfs_enabled"}}
    +
    {{ctx.Locale.Tr "admin.config.lfs_enabled"}}
    {{if .LFS.StartServer}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{if .LFS.StartServer}} -
    {{.locale.Tr "admin.config.lfs_content_path"}}
    +
    {{ctx.Locale.Tr "admin.config.lfs_content_path"}}
    {{JsonUtils.EncodeToString .LFS.Storage.ToShadowCopy}}
    -
    {{.locale.Tr "admin.config.lfs_http_auth_expiry"}}
    +
    {{ctx.Locale.Tr "admin.config.lfs_http_auth_expiry"}}
    {{.LFS.HTTPAuthExpiry}}
    {{end}}

    - {{.locale.Tr "admin.config.db_config"}} + {{ctx.Locale.Tr "admin.config.db_config"}}

    -
    {{.locale.Tr "admin.config.db_type"}}
    +
    {{ctx.Locale.Tr "admin.config.db_type"}}
    {{.DbCfg.Type}}
    {{if not (eq .DbCfg.Type "sqlite3")}} -
    {{.locale.Tr "admin.config.db_host"}}
    +
    {{ctx.Locale.Tr "admin.config.db_host"}}
    {{if .DbCfg.Host}}{{.DbCfg.Host}}{{else}}-{{end}}
    -
    {{.locale.Tr "admin.config.db_name"}}
    +
    {{ctx.Locale.Tr "admin.config.db_name"}}
    {{if .DbCfg.Name}}{{.DbCfg.Name}}{{else}}-{{end}}
    -
    {{.locale.Tr "admin.config.db_user"}}
    +
    {{ctx.Locale.Tr "admin.config.db_user"}}
    {{if .DbCfg.User}}{{.DbCfg.User}}{{else}}-{{end}}
    {{end}} {{if eq .DbCfg.Type "postgres"}} -
    {{.locale.Tr "admin.config.db_schema"}}
    +
    {{ctx.Locale.Tr "admin.config.db_schema"}}
    {{if .DbCfg.Schema}}{{.DbCfg.Schema}}{{else}}-{{end}}
    -
    {{.locale.Tr "admin.config.db_ssl_mode"}}
    +
    {{ctx.Locale.Tr "admin.config.db_ssl_mode"}}
    {{if .DbCfg.SSLMode}}{{.DbCfg.SSLMode}}{{else}}-{{end}}
    {{end}} {{if eq .DbCfg.Type "sqlite3"}} -
    {{.locale.Tr "admin.config.db_path"}}
    +
    {{ctx.Locale.Tr "admin.config.db_path"}}
    {{if .DbCfg.Path}}{{.DbCfg.Path}}{{else}}-{{end}}
    {{end}}

    - {{.locale.Tr "admin.config.service_config"}} + {{ctx.Locale.Tr "admin.config.service_config"}}

    -
    {{.locale.Tr "admin.config.register_email_confirm"}}
    +
    {{ctx.Locale.Tr "admin.config.register_email_confirm"}}
    {{if .Service.RegisterEmailConfirm}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.disable_register"}}
    +
    {{ctx.Locale.Tr "admin.config.disable_register"}}
    {{if .Service.DisableRegistration}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.allow_only_internal_registration"}}
    +
    {{ctx.Locale.Tr "admin.config.allow_only_internal_registration"}}
    {{if .Service.AllowOnlyInternalRegistration}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.allow_only_external_registration"}}
    +
    {{ctx.Locale.Tr "admin.config.allow_only_external_registration"}}
    {{if .Service.AllowOnlyExternalRegistration}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.show_registration_button"}}
    +
    {{ctx.Locale.Tr "admin.config.show_registration_button"}}
    {{if .Service.ShowRegistrationButton}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.enable_openid_signup"}}
    +
    {{ctx.Locale.Tr "admin.config.enable_openid_signup"}}
    {{if .Service.EnableOpenIDSignUp}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.enable_openid_signin"}}
    +
    {{ctx.Locale.Tr "admin.config.enable_openid_signin"}}
    {{if .Service.EnableOpenIDSignIn}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.require_sign_in_view"}}
    +
    {{ctx.Locale.Tr "admin.config.require_sign_in_view"}}
    {{if .Service.RequireSignInView}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.mail_notify"}}
    +
    {{ctx.Locale.Tr "admin.config.mail_notify"}}
    {{if .Service.EnableNotifyMail}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.disable_key_size_check"}}
    +
    {{ctx.Locale.Tr "admin.config.disable_key_size_check"}}
    {{if .SSH.MinimumKeySizeCheck}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.enable_captcha"}}
    +
    {{ctx.Locale.Tr "admin.config.enable_captcha"}}
    {{if .Service.EnableCaptcha}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.default_keep_email_private"}}
    +
    {{ctx.Locale.Tr "admin.config.default_keep_email_private"}}
    {{if .Service.DefaultKeepEmailPrivate}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.default_allow_create_organization"}}
    +
    {{ctx.Locale.Tr "admin.config.default_allow_create_organization"}}
    {{if .Service.DefaultAllowCreateOrganization}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.enable_timetracking"}}
    +
    {{ctx.Locale.Tr "admin.config.enable_timetracking"}}
    {{if .Service.EnableTimetracking}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{if .Service.EnableTimetracking}} -
    {{.locale.Tr "admin.config.default_enable_timetracking"}}
    +
    {{ctx.Locale.Tr "admin.config.default_enable_timetracking"}}
    {{if .Service.DefaultEnableTimetracking}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.default_allow_only_contributors_to_track_time"}}
    +
    {{ctx.Locale.Tr "admin.config.default_allow_only_contributors_to_track_time"}}
    {{if .Service.DefaultAllowOnlyContributorsToTrackTime}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{end}} -
    {{.locale.Tr "admin.config.default_visibility_organization"}}
    +
    {{ctx.Locale.Tr "admin.config.default_visibility_organization"}}
    {{.Service.DefaultOrgVisibility}}
    -
    {{.locale.Tr "admin.config.no_reply_address"}}
    +
    {{ctx.Locale.Tr "admin.config.no_reply_address"}}
    {{if .Service.NoReplyAddress}}{{.Service.NoReplyAddress}}{{else}}-{{end}}
    -
    {{.locale.Tr "admin.config.default_enable_dependencies"}}
    +
    {{ctx.Locale.Tr "admin.config.default_enable_dependencies"}}
    {{if .Service.DefaultEnableDependencies}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.active_code_lives"}}
    -
    {{.Service.ActiveCodeLives}} {{.locale.Tr "tool.raw_minutes"}}
    -
    {{.locale.Tr "admin.config.reset_password_code_lives"}}
    -
    {{.Service.ResetPwdCodeLives}} {{.locale.Tr "tool.raw_minutes"}}
    +
    {{ctx.Locale.Tr "admin.config.active_code_lives"}}
    +
    {{.Service.ActiveCodeLives}} {{ctx.Locale.Tr "tool.raw_minutes"}}
    +
    {{ctx.Locale.Tr "admin.config.reset_password_code_lives"}}
    +
    {{.Service.ResetPwdCodeLives}} {{ctx.Locale.Tr "tool.raw_minutes"}}

    - {{.locale.Tr "admin.config.webhook_config"}} + {{ctx.Locale.Tr "admin.config.webhook_config"}}

    -
    {{.locale.Tr "admin.config.queue_length"}}
    +
    {{ctx.Locale.Tr "admin.config.queue_length"}}
    {{.Webhook.QueueLength}}
    -
    {{.locale.Tr "admin.config.deliver_timeout"}}
    -
    {{.Webhook.DeliverTimeout}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.skip_tls_verify"}}
    +
    {{ctx.Locale.Tr "admin.config.deliver_timeout"}}
    +
    {{.Webhook.DeliverTimeout}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.skip_tls_verify"}}
    {{if .Webhook.SkipTLSVerify}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}

    - {{.locale.Tr "admin.config.mailer_config"}} + {{ctx.Locale.Tr "admin.config.mailer_config"}}

    -
    {{.locale.Tr "admin.config.mailer_enabled"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_enabled"}}
    {{if .MailerEnabled}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{if .MailerEnabled}} -
    {{.locale.Tr "admin.config.mailer_name"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_name"}}
    {{.Mailer.Name}}
    {{if eq .Mailer.Protocol "sendmail"}} -
    {{.locale.Tr "admin.config.mailer_use_sendmail"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_use_sendmail"}}
    {{svg "octicon-check"}}
    -
    {{.locale.Tr "admin.config.mailer_sendmail_path"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_sendmail_path"}}
    {{.Mailer.SendmailPath}}
    -
    {{.locale.Tr "admin.config.mailer_sendmail_args"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_sendmail_args"}}
    {{.Mailer.SendmailArgs}}
    -
    {{.locale.Tr "admin.config.mailer_sendmail_timeout"}}
    -
    {{.Mailer.SendmailTimeout}} {{.locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_sendmail_timeout"}}
    +
    {{.Mailer.SendmailTimeout}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    {{else if eq .Mailer.Protocol "dummy"}} -
    {{.locale.Tr "admin.config.mailer_use_dummy"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_use_dummy"}}
    {{svg "octicon-check"}}
    {{else}}{{/* SMTP family */}} -
    {{.locale.Tr "admin.config.mailer_protocol"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_protocol"}}
    {{.Mailer.Protocol}}
    -
    {{.locale.Tr "admin.config.mailer_enable_helo"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_enable_helo"}}
    {{if .Mailer.EnableHelo}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.mailer_smtp_addr"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_smtp_addr"}}
    {{.Mailer.SMTPAddr}}
    -
    {{.locale.Tr "admin.config.mailer_smtp_port"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_smtp_port"}}
    {{.Mailer.SMTPPort}}
    {{end}} -
    {{.locale.Tr "admin.config.mailer_user"}}
    +
    {{ctx.Locale.Tr "admin.config.mailer_user"}}
    {{if .Mailer.User}}{{.Mailer.User}}{{else}}(empty){{end}}
    -
    {{.locale.Tr "admin.config.send_test_mail"}}
    +
    {{ctx.Locale.Tr "admin.config.send_test_mail"}}
    {{.CsrfTokenHtml}}
    - +
    - +
    {{end}} @@ -246,118 +246,118 @@

    - {{.locale.Tr "admin.config.cache_config"}} + {{ctx.Locale.Tr "admin.config.cache_config"}}

    -
    {{.locale.Tr "admin.config.cache_adapter"}}
    +
    {{ctx.Locale.Tr "admin.config.cache_adapter"}}
    {{.CacheAdapter}}
    {{if eq .CacheAdapter "memory"}} -
    {{.locale.Tr "admin.config.cache_interval"}}
    -
    {{.CacheInterval}} {{.locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.cache_interval"}}
    +
    {{.CacheInterval}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    {{end}} {{if .CacheConn}} -
    {{.locale.Tr "admin.config.cache_conn"}}
    +
    {{ctx.Locale.Tr "admin.config.cache_conn"}}
    {{.CacheConn}}
    -
    {{.locale.Tr "admin.config.cache_item_ttl"}}
    +
    {{ctx.Locale.Tr "admin.config.cache_item_ttl"}}
    {{.CacheItemTTL}}
    {{end}}

    - {{.locale.Tr "admin.config.session_config"}} + {{ctx.Locale.Tr "admin.config.session_config"}}

    -
    {{.locale.Tr "admin.config.session_provider"}}
    +
    {{ctx.Locale.Tr "admin.config.session_provider"}}
    {{.SessionConfig.Provider}}
    -
    {{.locale.Tr "admin.config.provider_config"}}
    +
    {{ctx.Locale.Tr "admin.config.provider_config"}}
    {{if .SessionConfig.ProviderConfig}}{{.SessionConfig.ProviderConfig}}{{else}}-{{end}}
    -
    {{.locale.Tr "admin.config.cookie_name"}}
    +
    {{ctx.Locale.Tr "admin.config.cookie_name"}}
    {{.SessionConfig.CookieName}}
    -
    {{.locale.Tr "admin.config.gc_interval_time"}}
    -
    {{.SessionConfig.Gclifetime}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.session_life_time"}}
    -
    {{.SessionConfig.Maxlifetime}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.https_only"}}
    +
    {{ctx.Locale.Tr "admin.config.gc_interval_time"}}
    +
    {{.SessionConfig.Gclifetime}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.session_life_time"}}
    +
    {{.SessionConfig.Maxlifetime}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.https_only"}}
    {{if .SessionConfig.Secure}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}

    - {{.locale.Tr "admin.config.picture_config"}} + {{ctx.Locale.Tr "admin.config.picture_config"}}

    -
    {{.locale.Tr "admin.config.disable_gravatar"}}
    +
    {{ctx.Locale.Tr "admin.config.disable_gravatar"}}
    - +
    -
    {{.locale.Tr "admin.config.enable_federated_avatar"}}
    +
    {{ctx.Locale.Tr "admin.config.enable_federated_avatar"}}
    - +

    - {{.locale.Tr "admin.config.git_config"}} + {{ctx.Locale.Tr "admin.config.git_config"}}

    -
    {{.locale.Tr "admin.config.git_disable_diff_highlight"}}
    +
    {{ctx.Locale.Tr "admin.config.git_disable_diff_highlight"}}
    {{if .Git.DisableDiffHighlight}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    -
    {{.locale.Tr "admin.config.git_max_diff_lines"}}
    +
    {{ctx.Locale.Tr "admin.config.git_max_diff_lines"}}
    {{.Git.MaxGitDiffLines}}
    -
    {{.locale.Tr "admin.config.git_max_diff_line_characters"}}
    +
    {{ctx.Locale.Tr "admin.config.git_max_diff_line_characters"}}
    {{.Git.MaxGitDiffLineCharacters}}
    -
    {{.locale.Tr "admin.config.git_max_diff_files"}}
    +
    {{ctx.Locale.Tr "admin.config.git_max_diff_files"}}
    {{.Git.MaxGitDiffFiles}}
    -
    {{.locale.Tr "admin.config.git_gc_args"}}
    +
    {{ctx.Locale.Tr "admin.config.git_gc_args"}}
    {{.Git.GCArgs}}
    -
    {{.locale.Tr "admin.config.git_migrate_timeout"}}
    -
    {{.Git.Timeout.Migrate}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.git_mirror_timeout"}}
    -
    {{.Git.Timeout.Mirror}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.git_clone_timeout"}}
    -
    {{.Git.Timeout.Clone}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.git_pull_timeout"}}
    -
    {{.Git.Timeout.Pull}} {{.locale.Tr "tool.raw_seconds"}}
    -
    {{.locale.Tr "admin.config.git_gc_timeout"}}
    -
    {{.Git.Timeout.GC}} {{.locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.git_migrate_timeout"}}
    +
    {{.Git.Timeout.Migrate}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.git_mirror_timeout"}}
    +
    {{.Git.Timeout.Mirror}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.git_clone_timeout"}}
    +
    {{.Git.Timeout.Clone}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.git_pull_timeout"}}
    +
    {{.Git.Timeout.Pull}} {{ctx.Locale.Tr "tool.raw_seconds"}}
    +
    {{ctx.Locale.Tr "admin.config.git_gc_timeout"}}
    +
    {{.Git.Timeout.GC}} {{ctx.Locale.Tr "tool.raw_seconds"}}

    - {{.locale.Tr "admin.config.log_config"}} + {{ctx.Locale.Tr "admin.config.log_config"}}

    {{if .Loggers.xorm.IsEnabled}} -
    {{$.locale.Tr "admin.config.xorm_log_sql"}}
    +
    {{ctx.Locale.Tr "admin.config.xorm_log_sql"}}
    {{if $.LogSQL}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}}
    {{end}} {{if .Loggers.access.IsEnabled}} -
    {{$.locale.Tr "admin.config.access_log_template"}}
    +
    {{ctx.Locale.Tr "admin.config.access_log_template"}}
    {{$.AccessLogTemplate}}
    {{end}} {{range $loggerName, $loggerDetail := .Loggers}} -
    {{$.locale.Tr "admin.config.logger_name_fmt" $loggerName}}
    +
    {{ctx.Locale.Tr "admin.config.logger_name_fmt" $loggerName}}
    {{if $loggerDetail.IsEnabled}}
    {{$loggerDetail.EventWriters | JsonUtils.EncodeToString | JsonUtils.PrettyIndent}}
    {{else}} -
    {{$.locale.Tr "admin.config.disabled_logger"}}
    +
    {{ctx.Locale.Tr "admin.config.disabled_logger"}}
    {{end}} {{end}}
    diff --git a/templates/admin/cron.tmpl b/templates/admin/cron.tmpl index 354cd18ed..1886b48d0 100644 --- a/templates/admin/cron.tmpl +++ b/templates/admin/cron.tmpl @@ -1,7 +1,7 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin monitor")}}

    - {{.locale.Tr "admin.monitor.cron"}} + {{ctx.Locale.Tr "admin.monitor.cron"}}

    @@ -9,19 +9,19 @@ - {{.locale.Tr "admin.monitor.name"}} - {{.locale.Tr "admin.monitor.schedule"}} - {{.locale.Tr "admin.monitor.next"}} - {{.locale.Tr "admin.monitor.previous"}} - {{.locale.Tr "admin.monitor.execute_times"}} - {{.locale.Tr "admin.monitor.last_execution_result"}} + {{ctx.Locale.Tr "admin.monitor.name"}} + {{ctx.Locale.Tr "admin.monitor.schedule"}} + {{ctx.Locale.Tr "admin.monitor.next"}} + {{ctx.Locale.Tr "admin.monitor.previous"}} + {{ctx.Locale.Tr "admin.monitor.execute_times"}} + {{ctx.Locale.Tr "admin.monitor.last_execution_result"}} {{range .Entries}} - - {{$.locale.Tr (printf "admin.dashboard.%s" .Name)}} + + {{ctx.Locale.Tr (printf "admin.dashboard.%s" .Name)}} {{.Spec}} {{DateTime "full" .Next}} {{if gt .Prev.Year 1}}{{DateTime "full" .Prev}}{{else}}-{{end}} diff --git a/templates/admin/dashboard.tmpl b/templates/admin/dashboard.tmpl index 69c0376d6..6cb6c38e1 100644 --- a/templates/admin/dashboard.tmpl +++ b/templates/admin/dashboard.tmpl @@ -2,11 +2,11 @@
    {{if .NeedUpdate}}
    -

    {{(.locale.Tr "admin.dashboard.new_version_hint" .RemoteVersion AppVer) | Str2html}}

    +

    {{(ctx.Locale.Tr "admin.dashboard.new_version_hint" .RemoteVersion AppVer) | Str2html}}

    {{end}}

    - {{.locale.Tr "admin.dashboard.operations"}} + {{ctx.Locale.Tr "admin.dashboard.operations"}}

    @@ -14,56 +14,56 @@ - - + + - - + + - - + + - - + + {{if and (not .SSH.Disabled) (not .SSH.StartBuiltinServer)}} - - + + - - + + {{end}} - - + + - - + + - - + + - - + + - - + + - - + +
    {{.locale.Tr "admin.dashboard.delete_inactive_accounts"}}{{ctx.Locale.Tr "admin.dashboard.delete_inactive_accounts"}}
    {{.locale.Tr "admin.dashboard.delete_repo_archives"}}{{ctx.Locale.Tr "admin.dashboard.delete_repo_archives"}}
    {{.locale.Tr "admin.dashboard.delete_missing_repos"}}{{ctx.Locale.Tr "admin.dashboard.delete_missing_repos"}}
    {{.locale.Tr "admin.dashboard.git_gc_repos"}}{{ctx.Locale.Tr "admin.dashboard.git_gc_repos"}}
    {{.locale.Tr "admin.dashboard.resync_all_sshkeys"}}
    - {{.locale.Tr "admin.dashboard.resync_all_sshkeys.desc"}}
    {{ctx.Locale.Tr "admin.dashboard.resync_all_sshkeys"}}
    + {{ctx.Locale.Tr "admin.dashboard.resync_all_sshkeys.desc"}}
    {{.locale.Tr "admin.dashboard.resync_all_sshprincipals"}}
    - {{.locale.Tr "admin.dashboard.resync_all_sshprincipals.desc"}}
    {{ctx.Locale.Tr "admin.dashboard.resync_all_sshprincipals"}}
    + {{ctx.Locale.Tr "admin.dashboard.resync_all_sshprincipals.desc"}}
    {{.locale.Tr "admin.dashboard.resync_all_hooks"}}{{ctx.Locale.Tr "admin.dashboard.resync_all_hooks"}}
    {{.locale.Tr "admin.dashboard.reinit_missing_repos"}}{{ctx.Locale.Tr "admin.dashboard.reinit_missing_repos"}}
    {{.locale.Tr "admin.dashboard.sync_external_users"}}{{ctx.Locale.Tr "admin.dashboard.sync_external_users"}}
    {{.locale.Tr "admin.dashboard.repo_health_check"}}{{ctx.Locale.Tr "admin.dashboard.repo_health_check"}}
    {{.locale.Tr "admin.dashboard.delete_generated_repository_avatars"}}{{ctx.Locale.Tr "admin.dashboard.delete_generated_repository_avatars"}}
    {{.locale.Tr "admin.dashboard.sync_repo_branches"}}{{ctx.Locale.Tr "admin.dashboard.sync_repo_branches"}}
    @@ -71,69 +71,69 @@

    - {{.locale.Tr "admin.dashboard.system_status"}} + {{ctx.Locale.Tr "admin.dashboard.system_status"}}

    -
    {{.locale.Tr "admin.dashboard.server_uptime"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.server_uptime"}}
    {{.SysStatus.StartTime}}
    -
    {{.locale.Tr "admin.dashboard.current_goroutine"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.current_goroutine"}}
    {{.SysStatus.NumGoroutine}}
    -
    {{.locale.Tr "admin.dashboard.current_memory_usage"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.current_memory_usage"}}
    {{.SysStatus.MemAllocated}}
    -
    {{.locale.Tr "admin.dashboard.total_memory_allocated"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.total_memory_allocated"}}
    {{.SysStatus.MemTotal}}
    -
    {{.locale.Tr "admin.dashboard.memory_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.memory_obtained"}}
    {{.SysStatus.MemSys}}
    -
    {{.locale.Tr "admin.dashboard.pointer_lookup_times"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.pointer_lookup_times"}}
    {{.SysStatus.Lookups}}
    -
    {{.locale.Tr "admin.dashboard.memory_allocate_times"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.memory_allocate_times"}}
    {{.SysStatus.MemMallocs}}
    -
    {{.locale.Tr "admin.dashboard.memory_free_times"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.memory_free_times"}}
    {{.SysStatus.MemFrees}}
    -
    {{.locale.Tr "admin.dashboard.current_heap_usage"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.current_heap_usage"}}
    {{.SysStatus.HeapAlloc}}
    -
    {{.locale.Tr "admin.dashboard.heap_memory_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.heap_memory_obtained"}}
    {{.SysStatus.HeapSys}}
    -
    {{.locale.Tr "admin.dashboard.heap_memory_idle"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.heap_memory_idle"}}
    {{.SysStatus.HeapIdle}}
    -
    {{.locale.Tr "admin.dashboard.heap_memory_in_use"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.heap_memory_in_use"}}
    {{.SysStatus.HeapInuse}}
    -
    {{.locale.Tr "admin.dashboard.heap_memory_released"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.heap_memory_released"}}
    {{.SysStatus.HeapReleased}}
    -
    {{.locale.Tr "admin.dashboard.heap_objects"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.heap_objects"}}
    {{.SysStatus.HeapObjects}}
    -
    {{.locale.Tr "admin.dashboard.bootstrap_stack_usage"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.bootstrap_stack_usage"}}
    {{.SysStatus.StackInuse}}
    -
    {{.locale.Tr "admin.dashboard.stack_memory_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.stack_memory_obtained"}}
    {{.SysStatus.StackSys}}
    -
    {{.locale.Tr "admin.dashboard.mspan_structures_usage"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.mspan_structures_usage"}}
    {{.SysStatus.MSpanInuse}}
    -
    {{.locale.Tr "admin.dashboard.mspan_structures_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.mspan_structures_obtained"}}
    {{.SysStatus.MSpanSys}}
    -
    {{.locale.Tr "admin.dashboard.mcache_structures_usage"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.mcache_structures_usage"}}
    {{.SysStatus.MCacheInuse}}
    -
    {{.locale.Tr "admin.dashboard.mcache_structures_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.mcache_structures_obtained"}}
    {{.SysStatus.MCacheSys}}
    -
    {{.locale.Tr "admin.dashboard.profiling_bucket_hash_table_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.profiling_bucket_hash_table_obtained"}}
    {{.SysStatus.BuckHashSys}}
    -
    {{.locale.Tr "admin.dashboard.gc_metadata_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.gc_metadata_obtained"}}
    {{.SysStatus.GCSys}}
    -
    {{.locale.Tr "admin.dashboard.other_system_allocation_obtained"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.other_system_allocation_obtained"}}
    {{.SysStatus.OtherSys}}
    -
    {{.locale.Tr "admin.dashboard.next_gc_recycle"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.next_gc_recycle"}}
    {{.SysStatus.NextGC}}
    -
    {{.locale.Tr "admin.dashboard.last_gc_time"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.last_gc_time"}}
    {{.SysStatus.LastGC}}
    -
    {{.locale.Tr "admin.dashboard.total_gc_pause"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.total_gc_pause"}}
    {{.SysStatus.PauseTotalNs}}
    -
    {{.locale.Tr "admin.dashboard.last_gc_pause"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.last_gc_pause"}}
    {{.SysStatus.PauseNs}}
    -
    {{.locale.Tr "admin.dashboard.gc_times"}}
    +
    {{ctx.Locale.Tr "admin.dashboard.gc_times"}}
    {{.SysStatus.NumGC}}
    diff --git a/templates/admin/emails/list.tmpl b/templates/admin/emails/list.tmpl index 0acd112e2..89ea849da 100644 --- a/templates/admin/emails/list.tmpl +++ b/templates/admin/emails/list.tmpl @@ -1,27 +1,27 @@ {{template "admin/layout_head" (dict "ctxData" . "pageClass" "admin user")}}

    - {{.locale.Tr "admin.emails.email_manage_panel"}} ({{.locale.Tr "admin.total" .Total}}) + {{ctx.Locale.Tr "admin.emails.email_manage_panel"}} ({{.locale.Tr "admin.total" .Total}})

    @@ -31,16 +31,16 @@ - {{.locale.Tr "admin.users.name"}} + {{ctx.Locale.Tr "admin.users.name"}} {{SortArrow "username" "reverseusername" $.SortType false}} - {{.locale.Tr "admin.users.full_name"}} + {{ctx.Locale.Tr "admin.users.full_name"}} - {{.locale.Tr "email"}} + {{ctx.Locale.Tr "email"}} {{SortArrow "email" "reverseemail" $.SortType true}} - {{.locale.Tr "admin.emails.primary"}} - {{.locale.Tr "admin.emails.activated"}} + {{ctx.Locale.Tr "admin.emails.primary"}} + {{ctx.Locale.Tr "admin.emails.activated"}} @@ -72,10 +72,10 @@