diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/moredetail.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/moredetail.tt index f35048b429..a75ba0efcc 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/moredetail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/moredetail.tt @@ -587,12 +587,6 @@ $(document).ready(function(){ var browser = KOHA.browser('[% searchid | html %]', parseInt('[% biblionumber | html %]', 10)); browser.show(); - $(".collapsed, .expanded").on("click",function(e){ - e.preventDefault(); - var linkid = this.id; - window.scrollTo( 0, getScrollto( linkid, "" ) ); - togglePanel( $(this) ); - }); $(".item_sublink").on("click", function () { /* If the user clicks a sub-menu link in the sidebar, @@ -604,23 +598,12 @@ $("#" + href) .addClass("expanded") .removeClass("collapsed") - .attr("title", __("Collapse this section")); + .attr("title", _("Collapse this section")); panel.show(); } }); }); - - function togglePanel( node ){ - var panel = node.next( ".page-section" ); - if(panel.is(":visible")){ - node.addClass("collapsed").removeClass("expanded").attr("title", __("Click to expand this section") ); - panel.hide(); - } else { - node.addClass("expanded").removeClass("collapsed").attr("title", __("Click to collapse this section") ); - panel.show(); - } - } [% END %] [% INCLUDE 'intranet-bottom.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/js/staff-global.js b/koha-tmpl/intranet-tmpl/prog/js/staff-global.js index ff9f29b371..3403b54768 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/staff-global.js +++ b/koha-tmpl/intranet-tmpl/prog/js/staff-global.js @@ -60,7 +60,7 @@ $.fn.selectTabByID = function (tabID) { }; function togglePanel(node) { - var panel = node.nextAll(); + var panel = node.next(); if (panel.is(":visible")) { node.addClass("collapsed") .removeClass("expanded")