From e47a04876eedcc58dbf1ac7428560199b2c3c90e Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Fri, 18 Mar 2022 15:24:49 +0000 Subject: [PATCH] Bug 30316: Replace the use of jQueryUI tabs on MARC detail page This patch replaces jQueryUI tabs on the MARC detail page, replacing them with Bootstrap tabs. To test, apply the patch and locate a bibliographic record in the staff client. View the MARC detail page for that record. Confirm that the numered tabs work correctly. --- .../prog/en/modules/catalogue/MARCdetail.tt | 97 ++++++++++--------- 1 file changed, 50 insertions(+), 47 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/MARCdetail.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/MARCdetail.tt index f6be1b3d8f..612e855409 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/MARCdetail.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/MARCdetail.tt @@ -78,7 +78,7 @@ [% BLOCK show_tab_html %] -
+
[% FOREACH tab0X IN tab_data %] [% IF ( tab0X.tag ) %]
@@ -115,83 +115,83 @@
[% END %] - -
-
    +
    + - [% PROCESS show_tab_html tab_id="tab0XX" tab_data=tab0XX %] +
    + [% PROCESS show_tab_html tab_id="tab0XX" tab_data=tab0XX %] - [% PROCESS show_tab_html tab_id="tab1XX" tab_data=tab1XX %] + [% PROCESS show_tab_html tab_id="tab1XX" tab_data=tab1XX %] - [% PROCESS show_tab_html tab_id="tab2XX" tab_data=tab2XX %] + [% PROCESS show_tab_html tab_id="tab2XX" tab_data=tab2XX %] - [% PROCESS show_tab_html tab_id="tab3XX" tab_data=tab3XX %] + [% PROCESS show_tab_html tab_id="tab3XX" tab_data=tab3XX %] - [% PROCESS show_tab_html tab_id="tab4XX" tab_data=tab4XX %] + [% PROCESS show_tab_html tab_id="tab4XX" tab_data=tab4XX %] - [% PROCESS show_tab_html tab_id="tab5XX" tab_data=tab5XX %] + [% PROCESS show_tab_html tab_id="tab5XX" tab_data=tab5XX %] - [% PROCESS show_tab_html tab_id="tab6XX" tab_data=tab6XX %] + [% PROCESS show_tab_html tab_id="tab6XX" tab_data=tab6XX %] - [% PROCESS show_tab_html tab_id="tab7XX" tab_data=tab7XX %] + [% PROCESS show_tab_html tab_id="tab7XX" tab_data=tab7XX %] - [% PROCESS show_tab_html tab_id="tab8XX" tab_data=tab8XX %] + [% PROCESS show_tab_html tab_id="tab8XX" tab_data=tab8XX %] - [% PROCESS show_tab_html tab_id="tab9XX" tab_data=tab9XX %] + [% PROCESS show_tab_html tab_id="tab9XX" tab_data=tab9XX %] - [% IF ( tab10XX ) %] -
    - - - [% FOREACH header IN item_header_loop %] - - [% END %] - - [% FOREACH item IN item_loop %] - - [% FOREACH sf_code IN item_subfield_codes %] - - [% END %] - - [% END %] -
    [% header | html %]
    [% item.$sf_code | $raw %]
    -
    - [% END %] - -
    + [% IF ( tab10XX ) %] +
    + + + [% FOREACH header IN item_header_loop %] + + [% END %] + + [% FOREACH item IN item_loop %] + + [% FOREACH sf_code IN item_subfield_codes %] + + [% END %] + + [% END %] +
    [% header | html %]
    [% item.$sf_code | $raw %]
    +
    + [% END %] +
    +
@@ -215,11 +215,14 @@ browser.show(); $(document).ready(function() { - $('#bibliotabs').tabs(); + // $('#bibliotabs').tabs(); $("#Frameworks").on("change",function(){ Changefwk(this); }); - }); + if( $(".tab-pane.active").length < 1 ){ + $("#bibliotabs a:first").tab("show"); + } + }); function Changefwk(FwkList) { var fwk = FwkList.options[FwkList.selectedIndex].value; -- 2.20.1