From 57342f0fd065af53d24a499c6bd11392cf8b0e10 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Tue, 10 Jun 2025 18:24:22 +0000 Subject: [PATCH] Bug 40113: Update accounting admin pages to use grid layout for forms This patch updates four administration templates to use new structure and CSS for layout forms using CSS grids. To test, apply the patch and go to Administration. Check the following pages, confirming that the "New" and "Edit" versions of the form look correct in each case: - Administration -> Debit types - Administration -> Credit types - Administration -> Cash registers - Administration -> Desks Sponsored-by: Athens County Public Libraries --- .../prog/en/modules/admin/cash_registers.tt | 53 ++++++++---- .../prog/en/modules/admin/credit_types.tt | 78 +++++++++++------ .../prog/en/modules/admin/debit_types.tt | 86 +++++++++++++------ .../prog/en/modules/admin/desks.tt | 34 +++++--- 4 files changed, 170 insertions(+), 81 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/cash_registers.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/cash_registers.tt index 48b2b63cd1c..b081c25ea0a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/cash_registers.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/cash_registers.tt @@ -103,27 +103,42 @@
[% INCLUDE 'csrf-token.inc' %] -
+
-
    - [% IF cash_register %] -
  1. - Cash register ID: [% cash_register.id | html %] + [% IF cash_register %] +
    +
    + Cash register ID: +
    +
    + [% cash_register.id | html %] -
  2. - [% END %] -
  3. + + + [% END %] +
    +
    +
    +
    - Required -
  4. +
    Required
    + + -
  5. +
    +
    +
    +
    -
  6. -
  7. + + +
    +
    +
    +
    -
  8. + + -
  9. +
    +
    +
    +
    -
  10. -
+ +
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/credit_types.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/credit_types.tt index 7fb1068645d..8e1699718e5 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/credit_types.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/credit_types.tt @@ -85,27 +85,43 @@ [% INCLUDE 'csrf-token.inc' %] -
-
    -
  1. +
    +
    +
    - [% IF credit_type %] +
    + [% IF credit_type %] +
    [% credit_type.code | html %] - [% ELSE %] - Required. Maximum length is 64 letters - [% END %] -
  2. -
  3. + + [% ELSE %] +
    + +
    +
    Required
    +
    Maximum length is 64 letters
    + [% END %] + +
    +
    - [% IF credit_type && credit_type.is_system %] +
    + [% IF credit_type && credit_type.is_system %] +
    [%- PROCESS credit_type_description credit_type = credit_type -%] - [% ELSE %] +
    + [% ELSE %] +
    Required - [% END %] -
  4. -
  5. - + + [% END %] + +
    +
    + +
    +
    [% IF credit_type && credit_type.is_system %] [% IF credit_type.can_be_added_manually %]Yes[% ELSE %]No[% END %] [% ELSIF credit_type.can_be_added_manually %] @@ -113,21 +129,31 @@ [% ELSE %] [% END %] -
  6. -
  7. + + +
    +
    +
    +
    [% IF credit_type.credit_number_enabled %] [% ELSE %] [% END %] - Enable automatic generation of credit number (see AutoCreditNumber) -
  8. -
  9. + +
    Enable automatic generation of credit number (see AutoCreditNumber)
    + +
    +
    - [% IF credit_type && credit_type.is_system %] +
    + [% IF credit_type && credit_type.is_system %] +
    No library limitation - [% ELSE %] +
    + [% ELSE %] +
    -
    Limit the use of this credit type to the selected libraries.
    - [% END %] -
  10. -
+ +
Limit the use of this credit type to the selected libraries.
+ [% END %] +
[% IF additional_fields.size %] [% INCLUDE 'additional-fields-entry.inc' available=additional_fields values=additional_field_values wrap_fieldset=1 %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/debit_types.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/debit_types.tt index 018bd5c6654..393d3a231f0 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/debit_types.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/debit_types.tt @@ -83,57 +83,89 @@ [% INCLUDE 'csrf-token.inc' %] -
-
    -
  1. +
    +
    +
    - [% IF debit_type %] +
    + [% IF debit_type %] +
    [% debit_type.code | html %] - [% ELSE %] - Required. Maximum length is 64 letters - [% END %] -
  2. -
  3. + + [% ELSE %] +
    + +
    +
    Required
    +
    Maximum length is 64 letters
    + [% END %] + +
    +
    +
    +
    -
  4. -
  5. + + +
    +
    - [% IF debit_type && debit_type.is_system %] +
    + [% IF debit_type && debit_type.is_system %] +
    [%- PROCESS debit_type_description debit_type = debit_type -%] - [% ELSE %] - Required - [% END %] -
  6. -
  7. + + [% ELSE %] +
    + +
    +
    Required
    + [% END %] + +
    +
    +
    +
    [% IF debit_type.can_be_invoiced %] [% ELSE %] [% END %] -
  8. -
  9. + + +
    +
    +
    +
    [% IF debit_type.can_be_sold %] [% ELSE %] [% END %] -
  10. -
  11. + + +
    +
    +
    +
    [% IF debit_type.restricts_checkouts %] [% ELSE %] [% END %] -
  12. -
  13. + + +
    +
    +
    +
    -
    Limit use of this debit type to the selected libraries.
    -
  14. -
+ +
Limit use of this debit type to the selected libraries.
+
[% IF additional_fields.size %] [% INCLUDE 'additional-fields-entry.inc' available=additional_fields values=additional_field_values wrap_fieldset=1 %] 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 13a9c1c8bdf..4be7dd27428 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt @@ -101,17 +101,29 @@ -
-
    - [% IF desk %] -
  1. Desk ID: [% desk.desk_id | html %]
  2. - [% END %] -
  3. +
    + [% IF desk %] +
    +
    + Desk ID: +
    +
    [% desk.desk_id | html %]
    +
    + [% END %] +
    +
    - Required -
  4. -
  5. + +
    + +
    +
    Required
    + +
    +
    +
    +
    -
  6. -
+ +
-- 2.39.5