From fb47d04efd0987bb173fb78d12c439d82e4e83ab Mon Sep 17 00:00:00 2001 From: Pedro Amorim Date: Fri, 25 Aug 2023 16:41:12 +0000 Subject: [PATCH] Bug 34616: Move default server info outside the
Also DRY current default information dialog block Signed-off-by: Owen Leonard Signed-off-by: Jonathan Druart Signed-off-by: Tomas Cohen Arazi --- .../prog/en/modules/admin/smtp_servers.tt | 42 ++++++++----------- 1 file changed, 18 insertions(+), 24 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smtp_servers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smtp_servers.tt index 779434cb1b..1c69265791 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smtp_servers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smtp_servers.tt @@ -146,6 +146,9 @@ [% IF op == 'edit_form' %]

Edit SMTP server

+ [% UNLESS smtp_server.is_default %] + [% PROCESS default_server_info %] + [% END %]
@@ -226,19 +229,6 @@ [% END %] Sets this SMTP server as the default SMTP server. - [% UNLESS smtp_server.is_default %] -
-

Current default configuration:

- -
    -
  • Host: [%- default_config.host | html -%]
  • -
  • Port: [%- default_config.port | html -%]
  • -
  • Timeout (secs): [%- default_config.timeout | html -%]
  • -
  • SSL: [%- IF default_config.ssl_mode == 'disabled' -%]Disabled[%- ELSIF default_config.ssl_mode == 'ssl' -%]SSL[%- ELSE -%]STARTTLS[%- END -%]
  • -
  • Debug mode: [%- IF default_config.debug -%]Yes[%- ELSE -%]No[%- END -%]
  • -
-
- [% END %]
@@ -256,17 +246,7 @@

SMTP servers

-
-

Default configuration:

- -
    -
  • Host: [%- default_config.host | html -%]
  • -
  • Port: [%- default_config.port | html -%]
  • -
  • Timeout (secs): [%- default_config.timeout | html -%]
  • -
  • SSL: [%- IF default_config.ssl_mode == 'disabled' -%]Disabled[%- ELSIF default_config.ssl_mode == 'ssl' -%]SSL[%- ELSE -%]STARTTLS[%- END -%]
  • -
  • Debug mode: [%- IF default_config.debug -%]Yes[%- ELSE -%]No[%- END -%]
  • -
-
+ [% PROCESS default_server_info %] [% IF servers_count > 0 %]
@@ -489,4 +469,18 @@ [% END %] +[% BLOCK default_server_info %] +
+

Current default configuration:

+ +
    +
  • Host: [%- default_config.host | html -%]
  • +
  • Port: [%- default_config.port | html -%]
  • +
  • Timeout (secs): [%- default_config.timeout | html -%]
  • +
  • SSL: [%- IF default_config.ssl_mode == 'disabled' -%]Disabled[%- ELSIF default_config.ssl_mode == 'ssl' -%]SSL[%- ELSE -%]STARTTLS[%- END -%]
  • +
  • Debug mode: [%- IF default_config.debug -%]Yes[%- ELSE -%]No[%- END -%]
  • +
+
+[% END %] + [% INCLUDE 'intranet-bottom.inc' %] -- 2.39.5