|
Lines 743-754
Link Here
|
| 743 |
</td> |
743 |
</td> |
| 744 |
<td> |
744 |
<td> |
| 745 |
[% IF (itemloo.pickup_locations_count > 0) %] |
745 |
[% IF (itemloo.pickup_locations_count > 0) %] |
|
|
746 |
[% UNLESS ( multi_hold ) %] |
| 746 |
<select name="item_pickup_[% itemloo.itemnumber | html %]" class="pickup_locations" style="width:100%;" |
747 |
<select name="item_pickup_[% itemloo.itemnumber | html %]" class="pickup_locations" style="width:100%;" |
| 747 |
data-item-id="[% itemloo.itemnumber | html %]" |
748 |
data-item-id="[% itemloo.itemnumber | html %]" |
| 748 |
data-patron-id="[% patron.borrowernumber | html %]" |
749 |
data-patron-id="[% patron.borrowernumber | html %]" |
| 749 |
data-pickup-location-source="item"> |
750 |
data-pickup-location-source="item"> |
| 750 |
[% IF (itemloo.default_pickup_location) %] |
751 |
[% PROCESS options_for_libraries libraries => Branches.pickup_locations({ search_params => { biblio => biblionumber, patron => patron }, selected => pickup }) %] |
| 751 |
<option value="[% itemloo.default_pickup_location.branchcode | html %]" selected="selected">[% itemloo.default_pickup_location.branchname | html %]</option> |
752 |
[% ELSE %] |
|
|
753 |
[% IF (itemloo.default_pickup_location) %] |
| 754 |
<option value="[% itemloo.default_pickup_location.branchcode | html %]" selected="selected">[% itemloo.default_pickup_location.branchname | html %]</option> |
| 755 |
[% END %] |
| 752 |
[% END %] |
756 |
[% END %] |
| 753 |
</select> |
757 |
</select> |
| 754 |
[% END %] |
758 |
[% END %] |
|
Lines 1269-1275
Link Here
|
| 1269 |
var MSG_CANCEL_SELECTED = _("Cancel selected (%s)"); |
1273 |
var MSG_CANCEL_SELECTED = _("Cancel selected (%s)"); |
| 1270 |
$.fn.select2.defaults.set("width", "100%" ); |
1274 |
$.fn.select2.defaults.set("width", "100%" ); |
| 1271 |
$.fn.select2.defaults.set("dropdownAutoWidth", true ); |
1275 |
$.fn.select2.defaults.set("dropdownAutoWidth", true ); |
| 1272 |
|
|
|
| 1273 |
$(document).ready(function() { |
1276 |
$(document).ready(function() { |
| 1274 |
$('#cancellation-reason-fieldset').hide(); |
1277 |
$('#cancellation-reason-fieldset').hide(); |
| 1275 |
$('.rank-request').on('change', function() { |
1278 |
$('.rank-request').on('change', function() { |
|
Lines 1293-1299
Link Here
|
| 1293 |
}); |
1296 |
}); |
| 1294 |
} |
1297 |
} |
| 1295 |
|
1298 |
|
| 1296 |
|
|
|
| 1297 |
function ToggleHoldsToPlace() { |
1299 |
function ToggleHoldsToPlace() { |
| 1298 |
if ( $("#requestany").prop('checked') ) { |
1300 |
if ( $("#requestany").prop('checked') ) { |
| 1299 |
$("#holds_to_place_count").prop('disabled', false); |
1301 |
$("#holds_to_place_count").prop('disabled', false); |
|
Lines 1307-1319
Link Here
|
| 1307 |
}); |
1309 |
}); |
| 1308 |
|
1310 |
|
| 1309 |
[% IF Koha.Preference('UseBranchTransferLimits') %] |
1311 |
[% IF Koha.Preference('UseBranchTransferLimits') %] |
| 1310 |
$("#pickup").on('change', function(){ |
1312 |
$("#pickup").on('change', function(){ |
| 1311 |
var pickup = $("#pickup").val(); |
1313 |
$(".pickup_locations option:selected").text('Le nouveau texte à afficher'); |
| 1312 |
var url = "?pickup=" + pickup; |
1314 |
var pickup = $("#pickup").val(); |
| 1313 |
url += "&borrowernumber=" + borrowernumber; |
1315 |
var url = "?pickup=" + pickup; |
| 1314 |
url += "&biblionumber=" + biblionumbers[0]; |
1316 |
url += "&borrowernumber=" + borrowernumber; |
| 1315 |
window.location.replace(url); |
1317 |
url += "&biblionumber=" + biblionumbers[0]; |
| 1316 |
}); |
1318 |
window.location.replace(url); |
|
|
1319 |
}); |
| 1317 |
[% END %] |
1320 |
[% END %] |
| 1318 |
|
1321 |
|
| 1319 |
var my_table = $("#requestspecific").dataTable($.extend(true, {}, dataTablesDefaults, { |
1322 |
var my_table = $("#requestspecific").dataTable($.extend(true, {}, dataTablesDefaults, { |
|
Lines 1424-1429
Link Here
|
| 1424 |
$(".pickup_locations").each(function () { |
1427 |
$(".pickup_locations").each(function () { |
| 1425 |
$(this).pickup_locations_dropdown(); |
1428 |
$(this).pickup_locations_dropdown(); |
| 1426 |
}); |
1429 |
}); |
|
|
1430 |
|
| 1431 |
const pickup_location_code = window.location.search.substring(1).split('&').filter(tableau => tableau.split('=')[0] == 'pickup'); |
| 1432 |
|
| 1433 |
if(pickup_location_code.length > 0 ){ |
| 1434 |
$(".pickup_locations").val(pickup_location_code[0].split('=')[1]); |
| 1435 |
} |
| 1436 |
|
| 1437 |
|
| 1427 |
}); |
1438 |
}); |
| 1428 |
|
1439 |
|
| 1429 |
function check( table ) { |
1440 |
function check( table ) { |
| 1430 |
- |
|
|