From de17dcc85fa19d669e5bf8d34798c08414ccacfd Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Thu, 12 Jan 2023 18:00:56 +0000 Subject: [PATCH] Bug 32618: Add 'page-section' to various administration pages This patch adds a "page-section" container div around the main section of administration pages which lack it. The SMS providers page required a small change to the associated JavaScript in order to target the right container, so you may need to clear your browser cache to get the correct behavior. This patch contains indentation changes, so please ignore whitespace when looking at the diff. To test, apply the patch and view the following pages to confirm that the main content is contained in a white box: - Acquisitions -> Vendor -> Contracts - Administration -> Budgets -> Budget details -> Planning - Administration -> Circulation desks - Administration -> OAI sets configuration -> Define mappings - Administration -> System preferences -> Search for 'OverDriveAuthName' -> OverDrive library authnames table - Administration -> SMS cellular providers - Confirm that the "Edit" buttons work correctly to show and hide the right content. Signed-off-by: David Nind Signed-off-by: Katrin Fischer Signed-off-by: Tomas Cohen Arazi (cherry picked from commit 2addd2879a0dc84775e594c354e2d7d4897b7df1) Signed-off-by: Jacob O'Mara --- .../prog/en/modules/admin/aqcontract.tt | 52 ++-- .../prog/en/modules/admin/aqplan.tt | 228 +++++++++--------- .../prog/en/modules/admin/desks.tt | 48 ++-- .../prog/en/modules/admin/oai_set_mappings.tt | 179 +++++++------- .../prog/en/modules/admin/overdrive.tt | 57 ++--- .../prog/en/modules/admin/sms_providers.tt | 54 ++--- .../intranet-tmpl/prog/js/sms_providers.js | 6 +- 7 files changed, 316 insertions(+), 308 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqcontract.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqcontract.tt index 3ff7488ee1..097b2c9c8c 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqcontract.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqcontract.tt @@ -109,7 +109,8 @@
Contract has not been deleted. Maybe a basket linked to this contract exists.
[% END %] - [% IF ( add_form ) %] + [% IF ( add_form ) %] +
@@ -150,6 +151,7 @@ Cancel
+
[% END %] [% IF ( add_validate ) %]

Data recorded

@@ -191,29 +193,31 @@ [% IF ( else ) %]

Contract(s) of [% booksellername | html %]

[% IF ( loop ) %] - - - - - - - - - [% FOREACH loo IN loop %] - - - - - - - - [% END %] -
NameDescriptionStart dateEnd dateActions
- [% loo.contractname | html %] - [% loo.contractdescription | html %][% loo.contractstartdate | html %][% loo.contractenddate | html %] - Edit - Delete -
+
+ + + + + + + + + [% FOREACH loo IN loop %] + + + + + + + + [% END %] +
NameDescriptionStart dateEnd dateActions
+ [% loo.contractname | html %] + [% loo.contractdescription | html %][% loo.contractstartdate | html %][% loo.contractenddate | html %] + Edit + Delete +
+
[% ELSE %]
There are no contracts with this vendor. diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqplan.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqplan.tt index 0c79852d07..a89abe7c61 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqplan.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqplan.tt @@ -48,131 +48,129 @@ - [% IF ( budget_lines ) %] +
- [% INCLUDE 'budgets-active-currency.inc' %] - [% IF ( show_actual ) %] -

Each cell contain both actual and estimated values.

- [% ELSE %] -

Cells contain estimated values only.

- [% END %] - -

- Show/hide columns: - [% FOREACH authvals_ro IN authvals_row %] - - [% END %] -

- - - - - + [% IF ( budget_lines ) %] - [% FOREACH authvals_ro IN authvals_row %] - [% IF ( authvals_ro.display ) %] - - [% END %] - - - - - - - - [% FOREACH budget_line IN budget_lines %] - - [% IF ( budget_line.budget_lock ) %] - - - - [% FOREACH line IN budget_line.lines %] - [% IF ( line.display ) %] - - [% END %] - - - - - [% END %] - -
Fund nameFund total - [% ELSE %] - Fund remainingActions
- [% ELSE %] - - [% END %] - [% budget_line.budget_name | html %][% budget_line.budget_amount | $Price %]  - - - - + [% INCLUDE 'budgets-active-currency.inc' %] + [% IF ( show_actual ) %] +

Each cell contain both actual and estimated values.

[% ELSE %] -
- - - [% IF show_actual %] - [% IF ( budget_line.act_negative ) %] - - [% END %] - - [% IF ( budget_line.est_negative ) %] - - +
- [% ELSIF ( budget_line.act_positive ) %] - - [% ELSE %] - - [% END %] - [% budget_line.budget_act_remain | html %] - - [% ELSIF ( budget_line.est_positive ) %] - - [% ELSE %] - - [% END %] - [% budget_line.budget_est_remain | $Price %]  -
-
- [% UNLESS ( budget_line.budget_lock ) %] - - - [% ELSE %] -
not owned
- [% END %] -
- - - [% IF ( budget_period_locked ) %] - - [% ELSE %] - -
- [% END %] + + [% IF ( budget_period_locked ) %] + + [% ELSE %] + +
+ [% END %] +
[% FOREACH authvals_ro IN authvals_row %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt index 4e47aa340c..56a739507f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt @@ -182,29 +182,31 @@ [% END %] [% IF desks.count %] - - - - - - - - - - - [% FOREACH desk IN desks %] - - - - - - - [% END %] - -
Desk IDDeskLibraryAction
[% desk.desk_id | html %][% desk.desk_name | html %][% Branches.GetName( desk.branchcode ) | html %] - Edit - Delete -
+
+ + + + + + + + + + + [% FOREACH desk IN desks %] + + + + + + + [% END %] + +
Desk IDDeskLibraryAction
[% desk.desk_id | html %][% desk.desk_name | html %][% Branches.GetName( desk.branchcode ) | html %] + Edit + Delete +
+
[% ELSE %]
There are no desks defined. Create a new desk. diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/oai_set_mappings.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/oai_set_mappings.tt index ac18f8c388..096b8be666 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/oai_set_mappings.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/oai_set_mappings.tt @@ -45,94 +45,97 @@ [% UNLESS ( mappings ) %]

Warning: No mappings have been defined for this set

[% END %] -
- - - - - - - - - - - - - - [% IF ( mappings ) %] - [% FOREACH mapping IN mappings %] - - - - - - - - - - [% END %] - [% ELSE %] - - - - - - - - - - [% END %] - -
Rule operatorFieldSubfieldOperatorValue  
- - - [% IF ( loop.last ) %] - - [% END %] -
- - - -
- - -
- Cancel -
-
+ +
+
+ + + + + + + + + + + + + + [% IF ( mappings ) %] + [% FOREACH mapping IN mappings %] + + + + + + + + + + [% END %] + [% ELSE %] + + + + + + + + + + [% END %] + +
Rule operatorFieldSubfieldOperatorValue  
+ + + [% IF ( loop.last ) %] + + [% END %] +
+ + + +
+ + +
+ Cancel +
+
+
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/overdrive.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/overdrive.tt index f616939da9..dd9b47907e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/overdrive.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/overdrive.tt @@ -37,35 +37,36 @@

OverDrive library authnames

-
- - - - - - - - - - - [% FOREACH b IN branches %] - - - - - [% END %] - -
LibraryAuthname
- [% Branches.GetName( b.branchcode ) | html %] - - - -
-
- -
-
+
+
+ + + + + + + + + + [% FOREACH b IN branches %] + + + + + [% END %] + +
LibraryAuthname
+ [% Branches.GetName( b.branchcode ) | html %] + + + +
+
+ +
+
+
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/sms_providers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/sms_providers.tt index 56c562dff3..8daf280a12 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/sms_providers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/sms_providers.tt @@ -41,36 +41,36 @@

SMS cellular providers

[% IF providers.count %] - - - - - - - - - - - - - [% FOREACH p IN providers %] +
+
NameDomainPatrons 
+ - - - - + + + + - [% END %] - -
[% p.name | html %][% p.domain | html %][% p.patrons_using | html %] - - Edit - - - Delete - - NameDomainPatrons 
+ + + [% FOREACH p IN providers %] + + [% p.name | html %] + [% p.domain | html %] + [% p.patrons_using | html %] + + + Edit + + + Delete + + + + [% END %] + + +
[% ELSE %]
diff --git a/koha-tmpl/intranet-tmpl/prog/js/sms_providers.js b/koha-tmpl/intranet-tmpl/prog/js/sms_providers.js index 47b20e4ffe..7dd10af030 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/sms_providers.js +++ b/koha-tmpl/intranet-tmpl/prog/js/sms_providers.js @@ -34,7 +34,7 @@ function add_provider(){ clear_form(); $(".dialog").hide(); $("legend").text( __("Add an SMS cellular provider") ); - $("#toolbar,#submit_update,#providerst").hide(); + $("#toolbar,#submit_update,#providers").hide(); $("#sms_add_form,#submit_save").show(); $("#name").focus(); } @@ -48,7 +48,7 @@ function edit_provider( id ) { $("#name").val( $("#name_" + id).text() ); $("#domain").val( $("#domain_" + id).text() ); - $("#toolbar,#submit_save,#providerst").hide(); + $("#toolbar,#submit_save,#providers").hide(); $("#name").focus(); } @@ -58,7 +58,7 @@ function cancel_edit() { clear_form(); $(".dialog").show(); $("#sms_add_form,#submit_update").hide(); - $("#toolbar,#submit_save,#providerst").show(); + $("#toolbar,#submit_save,#providers").show(); } function delete_provider( id, users ) { -- 2.39.5