Bug 33158: Use template wrapper for authorized values and item types administration...
authorOwen Leonard <oleonard@myacpl.org>
Mon, 6 Mar 2023 18:54:22 +0000 (18:54 +0000)
committerPedro Amorim <pedro.amorim@ptfs-europe.com>
Wed, 7 Jun 2023 12:18:10 +0000 (12:18 +0000)
commit87f5bbe77b410227790fbe3f2b77d96898b4cf04
tree5d814c6e8686225a644098ed1398c9581166f021
parent1f831624e8b0f7f6cf481e52c97c1b621b9ce6dd
Bug 33158: Use template wrapper for authorized values and item types administration tabs

This patch updates the authorized values and item types administration
templates so that they use the new WRAPPER directive to build tabbed
navigation.

Seeing that the markup in itemtypes.tt and authorised_values.tt is
indential when it comes to icon selection, I have moved that section of
the template into an include file and updated both templates to use it.

The patch also makes minor SCSS changes, so to test you must rebuild the
staff interface CSS.

To test, apply the patch and go to Administration -> Item types.

- Edit an item type.
- On the edit page you should see tabs under "Choose an icon."
- Confirm that the tabs look correct and work correctly.
- If you did not previously have any icon selected, the "None" tab
  should be active.
- If you had an icon selected, that icon set's tab should be active.
- Confirm that if you specify a remote image
  (e.g.https://via.placeholder.com/50/FF0000/FFFFFF.png) the tab is
  correctly shown after you save and re-edit.
- Confirm that changing icons works correctly and that the selected
  icon's tab is always active when you return to the edit view.

Perform the same tests in Administration -> Authorized values.

Signed-off-by: Andrew Auld <andrew.auld@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 49c64f3d278030b119106e30c4684d8b0d6c21c1)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss
koha-tmpl/intranet-tmpl/prog/en/includes/admin-icon-selection.inc [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/admin/authorised_values.tt
koha-tmpl/intranet-tmpl/prog/en/modules/admin/itemtypes.tt