diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt index 87e9a409cb..d3d3596f4b 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/about.tt @@ -1218,9 +1218,7 @@ [% MACRO jsinclude BLOCK %] [% END %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt index d98d1573f4..60ca070d7a 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt @@ -375,7 +375,7 @@

Reminder: Patron has an indefinite restriction.

[% END %] [% IF errmsgloo.data_corrupted %] -

The item has not been checked in due to a configuration issue in your system. You must ask an administrator to take a look at the about page and correct all errors shown on the "System information" tab

+

The item has not been checked in due to a configuration issue in your system. You must ask an administrator to take a look at the about page and correct all errors shown on the "System information" tab

[% END %] [% END # /FOREACH errmsgloo %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt index 78f18b7c17..7fcb2cb7f4 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt @@ -114,7 +114,7 @@ [% END %]
[% IF !backends_available || !has_branch %] -
ILL module configuration problem. Take a look at the about page
+
ILL module configuration problem. Take a look at the about page
[% ELSE %] [% INCLUDE 'ill-toolbar.inc' %] diff --git a/koha-tmpl/intranet-tmpl/prog/js/marc_subfields_structure.js b/koha-tmpl/intranet-tmpl/prog/js/marc_subfields_structure.js index 898c64e3ae..119507ba01 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/marc_subfields_structure.js +++ b/koha-tmpl/intranet-tmpl/prog/js/marc_subfields_structure.js @@ -1,4 +1,4 @@ -/* global dataTablesDefaults tagsubfield */ +/* global dataTablesDefaults tagsubfield selectBsTabByHash */ $(document).ready(function() { if( tagsubfield && tagsubfield == "@"){ $("#subfieldtabs a[href='#subATfield']").tab("show"); @@ -39,6 +39,9 @@ $(document).ready(function() { aaSorting: [], paginate: false })); + + selectBsTabByHash("subfieldtabs"); + }); /* Function to enable/disable hidden values checkboxes when Flag is (de)selected */ diff --git a/koha-tmpl/intranet-tmpl/prog/js/pages/circulation.js b/koha-tmpl/intranet-tmpl/prog/js/pages/circulation.js index 7a8f53f474..d05d87b5bc 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/pages/circulation.js +++ b/koha-tmpl/intranet-tmpl/prog/js/pages/circulation.js @@ -1,4 +1,4 @@ -/* global borrowernumber */ +/* global borrowernumber selectBsTabByHash */ $(document).ready(function() { $("#CheckAllExports").on("click",function(){ $(".export:visible").prop("checked", true); @@ -91,11 +91,7 @@ $(document).ready(function() { }); /* Preselect Bootstrap tab based on location hash */ - var hash = window.location.hash.substring(1); - if( hash ){ - var activeTab = $('a[href="#' + hash + '"]'); - activeTab && activeTab.tab('show'); - } + selectBsTabByHash("finesholdsissues"); if ( $('#clubs_panel').length ) { $('#clubs-tab').on('click', function() { diff --git a/koha-tmpl/intranet-tmpl/prog/js/staff-global.js b/koha-tmpl/intranet-tmpl/prog/js/staff-global.js index abb3193bd7..56e35b6209 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/staff-global.js +++ b/koha-tmpl/intranet-tmpl/prog/js/staff-global.js @@ -598,3 +598,14 @@ function buildPatronSearchQuery(term, options) { } return q; } + +function selectBsTabByHash( tabs_container_id ){ + /* Check for location.hash in the page URL */ + /* If present the location hash will be used to activate the correct tab */ + var hash = document.location.hash; + if( hash !== "" ){ + $('#' + tabs_container_id + ' a[href="' + hash + '"]').tab('show'); + } else { + $('#' + tabs_container_id + ' a:first').tab('show'); + } +}