View | Details | Raw Unified | Return to bug 22768
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt (-7 / +12 lines)
Lines 28-34 Link Here
28
        });
28
        });
29
29
30
        [% IF tab %]
30
        [% IF tab %]
31
          $('#addbibliotabs').selectTabByID("tab[% tab | html %]");
31
            link = $("a[href='#[% tab | html %]']");
32
            selectTab( link );
32
        [% END %]
33
        [% END %]
33
34
34
        Sticky = $("#toolbar");
35
        Sticky = $("#toolbar");
Lines 136-147 Link Here
136
137
137
        $(".toolbar-tabs a").on("click",function(e){
138
        $(".toolbar-tabs a").on("click",function(e){
138
            e.preventDefault();
139
            e.preventDefault();
139
            $(".toolbar-tabs li").removeClass("selected");
140
            selectTab( $(this ) );
140
            $(this).parent().addClass("selected");
141
            var tabid = $(this).data("tabid");
142
            $('#addbibliotabs').selectTabByID("tab" + tabid + "XX");
143
            $(".tag_anchors").removeClass("tab_selected").hide();
144
            $(".tag_anchors_" + tabid ).addClass("tab_selected").show();
145
        });
141
        });
146
142
147
        $(".tag_anchor").on("click", function(e){
143
        $(".tag_anchor").on("click", function(e){
Lines 158-163 Link Here
158
154
159
    });
155
    });
160
156
157
    function selectTab( tablink ){
158
        $(".toolbar-tabs li").removeClass("selected");
159
        tablink.parent().addClass("selected");
160
        var tabid = tablink.data("tabid");
161
        $('#addbibliotabs').selectTabByID("#tab" + tabid + "XX");
162
        $(".tag_anchors").removeClass("tab_selected").hide();
163
        $(".tag_anchors_" + tabid ).addClass("tab_selected").show();
164
    }
165
161
    function redirect(dest){
166
    function redirect(dest){
162
        $("#redirect").attr("value",dest);
167
        $("#redirect").attr("value",dest);
163
        return Check();
168
        return Check();
(-)a/koha-tmpl/intranet-tmpl/prog/js/staff-global.js (-2 / +1 lines)
Lines 31-37 $.fn.tabIndex = function () { Link Here
31
    return $(this).parent().children('div').index(this);
31
    return $(this).parent().children('div').index(this);
32
};
32
};
33
$.fn.selectTabByID = function (tabID) {
33
$.fn.selectTabByID = function (tabID) {
34
    $(this).tabs("option", "active", $( "#" + tabID ).tabIndex());
34
    $(this).tabs("option", "active", $( tabID ).tabIndex());
35
};
35
};
36
36
37
 $(document).ready(function() {
37
 $(document).ready(function() {
38
- 

Return to bug 22768