Bug 34131: Add 'current' class on correct side menu link
authorPedro Amorim <pedro.amorim@ptfs-europe.com>
Tue, 27 Jun 2023 12:38:09 +0000 (12:38 +0000)
committerTomas Cohen Arazi <tomascohen@theke.io>
Fri, 7 Jul 2023 12:18:07 +0000 (09:18 -0300)
commit680bf6af2faa3b1612e16f77ec58daf129ef431a
tree9e63eeba4f30ef1ff6fd166cc3e01835ba8b00af
parent053439e50bd59a981a7f8c727818520653f484b5
Bug 34131: Add 'current' class on correct side menu link

This changes the way we're looking for the correct menu item to set as
active.

If we don't find an exact match for path+params, we attempt to set
'current' to just matching on path.

What this does is it sets the 'Plugins' menu item as active, even if
the url is 'plugins-home.pl?method=report

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
koha-tmpl/intranet-tmpl/prog/js/staff-global.js