1 $(document).ready(function() {
2 var path = location.pathname.substring(1);
3 if (path.indexOf("labels") >= 0 && path.indexOf("spine") < 0 ) {
4 $('#navmenulist a[href$="/cgi-bin/koha/labels/label-home.pl"]').addClass("current");
5 } else if (path.indexOf("patroncards") >= 0 ) {
6 $('#navmenulist a[href$="/cgi-bin/koha/patroncards/home.pl"]').addClass("current");
7 } else if (path.indexOf("clubs") >= 0 ) {
8 $('#navmenulist a[href$="/cgi-bin/koha/clubs/clubs.pl"]').addClass("current");
9 } else if (path.indexOf("patron_lists") >= 0 ) {
10 $('#navmenulist a[href$="/cgi-bin/koha/patron_lists/lists.pl"]').addClass("current");
11 } else if (path.indexOf("rotating_collections") >= 0 ){
12 $('#navmenulist a[href$="/cgi-bin/koha/rotating_collections/rotatingCollections.pl"]').addClass("current");
13 } else if ((path+location.search).indexOf("batchMod.pl?del=1") >= 0 ) {
14 $('#navmenulist a[href$="/cgi-bin/koha/tools/batchMod.pl?del=1"]').addClass("current");
15 } else if (path.indexOf("quotes-upload.pl") >= 0 ){
16 $('#navmenulist a[href$="/cgi-bin/koha/tools/quotes.pl"]').addClass("current");
17 } else if (path.indexOf("stockrotation") >= 0 ) {
18 $('#navmenulist a[href$="/cgi-bin/koha/tools/stockrotation.pl"]').addClass("current");
19 } else if (path.indexOf("plugins") >= 0 ) {
20 $('#navmenulist a[href$="/cgi-bin/koha/plugins/plugins-home.pl?method=tool"]').addClass("current");