Lines 19-24
Link Here
|
19 |
</head> |
19 |
</head> |
20 |
|
20 |
|
21 |
<body id="circ_request" class="catalog"> |
21 |
<body id="circ_request" class="catalog"> |
|
|
22 |
<script> |
23 |
var select2Width = "100%"; |
24 |
</script> |
22 |
[% INCLUDE 'header.inc' %] |
25 |
[% INCLUDE 'header.inc' %] |
23 |
[% INCLUDE 'circ-search.inc' %] |
26 |
[% INCLUDE 'circ-search.inc' %] |
24 |
|
27 |
|
Lines 985-991
Link Here
|
985 |
[% INCLUDE 'columns_settings.inc' %] |
988 |
[% INCLUDE 'columns_settings.inc' %] |
986 |
[% Asset.js("lib/hc-sticky.js") | $raw %] |
989 |
[% Asset.js("lib/hc-sticky.js") | $raw %] |
987 |
[% Asset.js("js/circ-patron-search-results.js") | $raw %] |
990 |
[% Asset.js("js/circ-patron-search-results.js") | $raw %] |
988 |
[% Asset.js("js/holds.js") | $raw %] |
991 |
[% INCLUDE 'select2.inc' %] |
989 |
<script> |
992 |
<script> |
990 |
var Sticky; |
993 |
var Sticky; |
991 |
var biblionumber = "[% biblionumber | $raw %]"; |
994 |
var biblionumber = "[% biblionumber | $raw %]"; |
Lines 1150-1155
Link Here
|
1150 |
}); |
1153 |
}); |
1151 |
[% END %] |
1154 |
[% END %] |
1152 |
|
1155 |
|
|
|
1156 |
$(".pickup_location_dropdown").each( function () { |
1157 |
var this_dropdown = $(this); |
1158 |
var hold_id = $(this).data('hold_id'); |
1159 |
|
1160 |
this_dropdown.select2({ |
1161 |
ajax: { |
1162 |
url: '/api/v1/holds/' + encodeURIComponent(hold_id) + '/pickup_locations', |
1163 |
allowClear: false, |
1164 |
dataType: 'json', |
1165 |
data: function (params) { |
1166 |
var search_term = (params.term === undefined) ? '' : params.term; |
1167 |
var query = { |
1168 |
"q": JSON.stringify({"name":{"-like":search_term+'%'}}) |
1169 |
}; |
1170 |
return query; |
1171 |
}, |
1172 |
processResults: function (data) { |
1173 |
var results = []; |
1174 |
data.forEach( function ( library ) { |
1175 |
results.push( |
1176 |
{ |
1177 |
"id": library.library_id.escapeHtml(), |
1178 |
"text": library.name.escapeHtml() |
1179 |
} |
1180 |
); |
1181 |
}); |
1182 |
return { "results": results }; |
1183 |
} |
1184 |
} |
1185 |
}); |
1186 |
}); |
1153 |
}); |
1187 |
}); |
1154 |
|
1188 |
|
1155 |
function check() { |
1189 |
function check() { |