Lines 44-49
Link Here
|
44 |
if( hashPieces[0] !== "" ){ |
44 |
if( hashPieces[0] !== "" ){ |
45 |
selectTab( hashPieces[0] ); |
45 |
selectTab( hashPieces[0] ); |
46 |
window.scrollTo( 0, 0 ); |
46 |
window.scrollTo( 0, 0 ); |
|
|
47 |
} else { |
48 |
selectTab( "#tab0XX_panel" ); |
47 |
} |
49 |
} |
48 |
|
50 |
|
49 |
$( "ul.sortable_field", "#addbibliotabs" ).sortable({ |
51 |
$( "ul.sortable_field", "#addbibliotabs" ).sortable({ |
Lines 159-165
Link Here
|
159 |
Changefwk(); |
161 |
Changefwk(); |
160 |
}); |
162 |
}); |
161 |
|
163 |
|
162 |
$(".toolbar-tabs a").on("click",function(e){ |
164 |
$(".toolbar-tabs-container .nav-tabs a").on("click",function(e){ |
163 |
e.preventDefault(); |
165 |
e.preventDefault(); |
164 |
selectTab( this.hash ); |
166 |
selectTab( this.hash ); |
165 |
}); |
167 |
}); |
Lines 177-183
Link Here
|
177 |
e.preventDefault(); |
179 |
e.preventDefault(); |
178 |
var tab = $(this).data("tab"); |
180 |
var tab = $(this).data("tab"); |
179 |
var field = $(this).data("field"); |
181 |
var field = $(this).data("field"); |
180 |
var tablink = $("a[data-tabid='" + tab + "']" ).get(0).hash; |
182 |
var tablink = $("a[data-tabname='tab" + tab + "XX']" ).get(0).hash; |
181 |
selectTab( tablink ); |
183 |
selectTab( tablink ); |
182 |
window.scrollTo( 0, getScrollto( field, "toolbar" ) ); |
184 |
window.scrollTo( 0, getScrollto( field, "toolbar" ) ); |
183 |
}); |
185 |
}); |
Lines 190-198
Link Here
|
190 |
|
192 |
|
191 |
function selectTab( tablink ){ |
193 |
function selectTab( tablink ){ |
192 |
let a = $("a[href='" + tablink + "']"); |
194 |
let a = $("a[href='" + tablink + "']"); |
193 |
$(".toolbar-tabs li").removeClass("selected"); |
195 |
$(".toolbar-tabs-container .nav-tabs li").removeClass("selected"); |
194 |
a.tab("show").parent().addClass("selected"); |
196 |
a.tab("show").parent().addClass("selected"); |
195 |
var tabid = a.data("tabid"); |
197 |
/* Get number from string like "tab9XX" */ |
|
|
198 |
var tabid = a.data("tabname").substring(3, 4); |
196 |
$(".tag_anchors").removeClass("tab_selected").hide(); |
199 |
$(".tag_anchors").removeClass("tab_selected").hide(); |
197 |
$(".tag_anchors_" + tabid ).addClass("tab_selected").show(); |
200 |
$(".tag_anchors_" + tabid ).addClass("tab_selected").show(); |
198 |
} |
201 |
} |
Lines 951-967
function PopupMARCFieldDoc(field) {
Link Here
|
951 |
[% END # /UNLESS circborrowernumber %] |
954 |
[% END # /UNLESS circborrowernumber %] |
952 |
<div class="toolbar-tabs-container"> |
955 |
<div class="toolbar-tabs-container"> |
953 |
[% IF ( BIG_LOOP && BIG_LOOP.size > 1 ) %] |
956 |
[% IF ( BIG_LOOP && BIG_LOOP.size > 1 ) %] |
954 |
<ul class="toolbar-tabs" role="tablist"> |
957 |
[% WRAPPER tabs_nav %] |
955 |
[%- FOREACH BIG_LOO IN BIG_LOOP -%] |
958 |
[%- FOREACH BIG_LOO IN BIG_LOOP -%] |
956 |
[% IF loop.first %] |
959 |
[% IF loop.first %] |
957 |
<li role="presentation" class="active selected"> |
960 |
[% SET bt_active = 1 %] |
958 |
[% ELSE %] |
961 |
[% ELSE %] |
959 |
<li role="presentation"> |
962 |
[% SET bt_active = 0 %] |
|
|
963 |
[% END %] |
964 |
[% WRAPPER tab_item tabname= "tab${BIG_LOO.number}XX" bt_active= bt_active %] |
965 |
<span>[% BIG_LOO.number | html %]</span> |
960 |
[% END %] |
966 |
[% END %] |
961 |
<a data-tabid="[% BIG_LOO.number | html %]" href="#tab[% BIG_LOO.number | html %]XX" aria-controls="#tab[% BIG_LOO.number | html %]XX" role="tab" data-toggle="tab">[% BIG_LOO.number | html %]</a> |
|
|
962 |
</li> |
963 |
[%- END -%] |
967 |
[%- END -%] |
964 |
</ul> |
968 |
[% END # /WRAPPER tabs_nav %] |
965 |
[% END %] |
969 |
[% END %] |
966 |
<ul class="tag_anchors_list"> |
970 |
<ul class="tag_anchors_list"> |
967 |
[% FOREACH BIG_LOO IN BIG_LOOP %] |
971 |
[% FOREACH BIG_LOO IN BIG_LOOP %] |
Lines 995-1009
function PopupMARCFieldDoc(field) {
Link Here
|
995 |
<input type="hidden" name="breedingid" value="[% breedingid | html %]" /> |
999 |
<input type="hidden" name="breedingid" value="[% breedingid | html %]" /> |
996 |
<input type="hidden" name="changed_framework" value="" /> |
1000 |
<input type="hidden" name="changed_framework" value="" /> |
997 |
|
1001 |
|
998 |
<div id="addbibliotabs" class="toptabs numbered"> |
1002 |
[% WRAPPER tabs id= "addbibliotabs" %] |
999 |
<div class="tab-content"> |
1003 |
[% WRAPPER tab_panels %] |
1000 |
|
|
|
1001 |
[% FOREACH BIG_LOO IN BIG_LOOP %] |
1004 |
[% FOREACH BIG_LOO IN BIG_LOOP %] |
1002 |
[% IF loop.first %] |
1005 |
[% IF loop.first %] |
1003 |
<div id="tab[% BIG_LOO.number | html %]XX" role="tabpanel" class="tab-pane active"> |
1006 |
[% SET bt_active = 1 %] |
1004 |
[% ELSE %] |
1007 |
[% ELSE %] |
1005 |
<div id="tab[% BIG_LOO.number | html %]XX" role="tabpanel" class="tab-pane"> |
1008 |
[% SET bt_active = 0 %] |
1006 |
[% END %] |
1009 |
[% END %] |
|
|
1010 |
[% WRAPPER tab_panel tabname="tab${BIG_LOO.number}XX" bt_active= bt_active %] |
1007 |
|
1011 |
|
1008 |
[% IF ( BIG_LOOP.size > 1 ) %] |
1012 |
[% IF ( BIG_LOOP.size > 1 ) %] |
1009 |
<h3>Section [% BIG_LOO.number | html %]</h3> |
1013 |
<h3>Section [% BIG_LOO.number | html %]</h3> |
Lines 1204-1213
function PopupMARCFieldDoc(field) {
Link Here
|
1204 |
[% END %]<!-- if innerloo.tag --> |
1208 |
[% END %]<!-- if innerloo.tag --> |
1205 |
[% END # /FOREACH BIG_LOO.innerloop %] |
1209 |
[% END # /FOREACH BIG_LOO.innerloop %] |
1206 |
</ul> <!-- /.sortable_field --> |
1210 |
</ul> <!-- /.sortable_field --> |
1207 |
</div> <!-- /#tabXXX --> |
1211 |
[% END # /tab_panel#tabXXX %] |
1208 |
[% END # /FOREACH BIG_LOOP %] |
1212 |
[% END # /FOREACH BIG_LOOP %] |
1209 |
</div> <!-- /.tab-content --> |
1213 |
[% END # /WRAPPER tab_panels %] |
1210 |
</div><!-- /#addbibliotabs --> |
1214 |
[% END # /WRAPPER tabs %] |
1211 |
|
1215 |
|
1212 |
[%# Fields for fast cataloging %] |
1216 |
[%# Fields for fast cataloging %] |
1213 |
<input type="hidden" name="barcode" value="[% barcode | html %]" /> |
1217 |
<input type="hidden" name="barcode" value="[% barcode | html %]" /> |
1214 |
- |
|
|