Bug 17794: Menu items in Tools menu and Admin menu not showing bold when active but not on linked page
To reproduce: admin-menu 1) Go to a page like admin/categories.pl 2) Click New Category 3) Notice Patron categories in the sidebar menu is no longer bold tools-menu 4) Go to a page like reviews/reviewswaiting.pl 5) Notice bold Comments in sidebar menu 6) Click Approved Comments tab 7) Notice no longer bold in sidebar menu To test: 8) Apply patch and refresh page 9) Follow above steps to reproduce bug, confirm that active links are always bold 10) Test with other links to confirm nothing has broken Special cases 11) Go To admin -> MARC bibliographic frameworks -> Actions for any framework -> MARC structure 12) Confirm sidebar menu link is still bold 13) Go to admin -> Authority types -> Actions for any auth type -> MARC structure 14) Confirm sidebar menu link is still bold 15) Click Actions for any tag -> Subfields 16) Confirm sidebar menu link is still bold 17) Go to admin -> OAI sets config -> Actions for any set -> Define mappings 18) Confirm sidebar menu link is still bold Sponsored-by: Catalyst IT Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
parent
c69e6faa98
commit
bee87e4f61
2 changed files with 9 additions and 11 deletions
|
@ -2,12 +2,15 @@
|
|||
<script type="text/javascript">//<![CDATA[
|
||||
$(document).ready(function() {
|
||||
var path = location.pathname.substring(1);
|
||||
var url = window.location.toString();
|
||||
var params = '';
|
||||
if ( url.match(/\?(.+)$/) ) {
|
||||
params = "?" + RegExp.$1;
|
||||
if (path == "cgi-bin/koha/admin/marctagstructure.pl" || path == "cgi-bin/koha/admin/marc_subfields_structure.pl") {
|
||||
$('#navmenulist a[href$="/cgi-bin/koha/admin/biblio_framework.pl"]').css('font-weight','bold');
|
||||
} else if (path == "cgi-bin/koha/admin/auth_tag_structure.pl" || path == "cgi-bin/koha/admin/auth_subfields_structure.pl") {
|
||||
$('#navmenulist a[href$="/cgi-bin/koha/admin/authtypes.pl"]').css('font-weight','bold');
|
||||
} else if (path == "cgi-bin/koha/admin/oai_set_mappings.pl") {
|
||||
$('#navmenulist a[href$="/cgi-bin/koha/admin/oai_sets.pl"]').css('font-weight','bold');
|
||||
} else {
|
||||
$('#navmenulist a[href$="/' + path + '"]').css('font-weight','bold');
|
||||
}
|
||||
$('#navmenulist a[href$="/' + path + params + '"]').css('font-weight','bold');
|
||||
});
|
||||
//]]>
|
||||
</script>
|
||||
|
|
|
@ -1,11 +1,6 @@
|
|||
<script type="text/javascript">//<![CDATA[
|
||||
$(document).ready(function() {
|
||||
var path = location.pathname.substring(1);
|
||||
var url = window.location.toString();
|
||||
var params = '';
|
||||
if ( url.match(/\?(.+)$/) ) {
|
||||
params = "?" + RegExp.$1;
|
||||
}
|
||||
if (path.indexOf("labels") >= 0 && path.indexOf("spine") < 0 ) {
|
||||
$('#navmenulist a[href$="/cgi-bin/koha/labels/label-home.pl"]').css('font-weight','bold');
|
||||
} else if (path.indexOf("patroncards") >= 0 ) {
|
||||
|
@ -13,7 +8,7 @@
|
|||
} else if (path.indexOf("patron_lists") >= 0 ) {
|
||||
$('#navmenulist a[href$="/cgi-bin/koha/patron_lists/lists.pl"]').css('font-weight','bold');
|
||||
} else {
|
||||
$('#navmenulist a[href$="/' + path + params + '"]').css('font-weight','bold');
|
||||
$('#navmenulist a[href$="/' + path + '"]').css('font-weight','bold');
|
||||
}
|
||||
});
|
||||
//]]>
|
||||
|
|
Loading…
Reference in a new issue