|
Lines 587-598
Link Here
|
| 587 |
$(document).ready(function(){ |
587 |
$(document).ready(function(){ |
| 588 |
var browser = KOHA.browser('[% searchid | html %]', parseInt('[% biblionumber | html %]', 10)); |
588 |
var browser = KOHA.browser('[% searchid | html %]', parseInt('[% biblionumber | html %]', 10)); |
| 589 |
browser.show(); |
589 |
browser.show(); |
| 590 |
$(".collapsed, .expanded").on("click",function(e){ |
|
|
| 591 |
e.preventDefault(); |
| 592 |
var linkid = this.id; |
| 593 |
window.scrollTo( 0, getScrollto( linkid, "" ) ); |
| 594 |
togglePanel( $(this) ); |
| 595 |
}); |
| 596 |
|
590 |
|
| 597 |
$(".item_sublink").on("click", function () { |
591 |
$(".item_sublink").on("click", function () { |
| 598 |
/* If the user clicks a sub-menu link in the sidebar, |
592 |
/* If the user clicks a sub-menu link in the sidebar, |
|
Lines 604-626
Link Here
|
| 604 |
$("#" + href) |
598 |
$("#" + href) |
| 605 |
.addClass("expanded") |
599 |
.addClass("expanded") |
| 606 |
.removeClass("collapsed") |
600 |
.removeClass("collapsed") |
| 607 |
.attr("title", __("Collapse this section")); |
601 |
.attr("title", _("Collapse this section")); |
| 608 |
panel.show(); |
602 |
panel.show(); |
| 609 |
} |
603 |
} |
| 610 |
}); |
604 |
}); |
| 611 |
|
605 |
|
| 612 |
}); |
606 |
}); |
| 613 |
|
|
|
| 614 |
function togglePanel( node ){ |
| 615 |
var panel = node.next( ".page-section" ); |
| 616 |
if(panel.is(":visible")){ |
| 617 |
node.addClass("collapsed").removeClass("expanded").attr("title", __("Click to expand this section") ); |
| 618 |
panel.hide(); |
| 619 |
} else { |
| 620 |
node.addClass("expanded").removeClass("collapsed").attr("title", __("Click to collapse this section") ); |
| 621 |
panel.show(); |
| 622 |
} |
| 623 |
} |
| 624 |
</script> |
607 |
</script> |
| 625 |
[% END %] |
608 |
[% END %] |
| 626 |
[% INCLUDE 'intranet-bottom.inc' %] |
609 |
[% INCLUDE 'intranet-bottom.inc' %] |