@@ -, +, @@ --- .../prog/en/modules/authorities/detail.tt | 7 ++++++- .../bootstrap/en/modules/opac-auth-MARCdetail.tt | 8 ++++++-- .../opac-tmpl/bootstrap/en/modules/opac-auth-detail.tt | 10 +++++++++- 3 files changed, 21 insertions(+), 4 deletions(-) --- a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/detail.tt +++ a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/detail.tt @@ -151,7 +151,12 @@ } }, "plugins" : [ "types" ] - }).on('ready.jstree', function(){ $(this).jstree('open_all') + }).on('ready.jstree', function(){ + $(this).jstree('open_all'); + $("#hier"+[% authid %]+"_anchor").on("click", + function(e){e.preventDefault(); return false;} + ).css("text-decoration", "none").css("color", "#333"); + $(".currentauth").css("text-decoration", "none").css("color", "#333"); }).bind("select_node.jstree", function (e, data) { e.preventDefault(); document.location.href = data.node.a_attr.href; --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-auth-MARCdetail.tt +++ a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-auth-MARCdetail.tt @@ -91,7 +91,12 @@ } }, "plugins" : [ "types" ] - }).on('ready.jstree', function(){ $(this).jstree('open_all') + }).on('ready.jstree', function(){ + $(this).jstree('open_all') + $("#hier"+[% authid %]+"_anchor").on("click", + function(e){e.preventDefault(); return false;} + ).css("text-decoration", "none").css("color", "#333"); + $(".currentauth").css("text-decoration", "none").css("color", "#333"); }).bind("select_node.jstree", function (e, data) { e.preventDefault(); document.location.href = data.node.a_attr.href; @@ -99,4 +104,3 @@ [% END %] }); -[% END %] --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-auth-detail.tt +++ a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-auth-detail.tt @@ -13,6 +13,9 @@ [% Asset.css("lib/jquery/plugins/jstree/themes/default/style.min.css") | $raw %] [% END %] [% END %] +[%# FIXME authid is modified when passed authheadingdisplay %] +[%# It's then wrong in the JS %] +[% SET original_authid = authid %] [% INCLUDE 'bodytag.inc' bodyid='opac-authoritiesdetail' bodyclass='scrollto' %] [% INCLUDE 'masthead.inc' %] @@ -183,7 +186,12 @@ } }, "plugins" : [ "types" ] - }).on('ready.jstree', function(){ $(this).jstree('open_all') + }).on('ready.jstree', function(){ + $(this).jstree('open_all'); + $("#hier"+[% original_authid %]+"_anchor").on("click", + function(e){e.preventDefault(); return false;} + ).css("text-decoration", "none").css("color", "#333"); + $(".currentauth").css("text-decoration", "none").css("color", "#333"); }).bind("select_node.jstree", function (e, data) { e.preventDefault(); document.location.href = data.node.a_attr.href; --