From 078324d151f4fba9df290cc138b1761caf7c9dac 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 (cherry picked from commit fb47d04efd0987bb173fb78d12c439d82e4e83ab) Signed-off-by: Fridolin Somers --- .../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 cc1b47f0c7..9cf5ff82ee 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 @@ -142,6 +142,9 @@ [% IF op == 'edit_form' %]

Edit SMTP server

+ [% UNLESS smtp_server.is_default %] + [% PROCESS default_server_info %] + [% END %]
@@ -222,19 +225,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 %]
@@ -252,17 +242,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 %]
@@ -485,4 +465,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