Lines 1256-1262
Link Here
|
1256 |
</div> |
1256 |
</div> |
1257 |
<fieldset id="cancellation-reason-fieldset" class="action" style="display:none"> |
1257 |
<fieldset id="cancellation-reason-fieldset" class="action" style="display:none"> |
1258 |
[% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %] |
1258 |
[% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %] |
1259 |
[% IF hold_cancellation.count %] |
1259 |
[% IF hold_cancellation.count && cancel_notice_branches.size %] |
1260 |
<label for="cancellation-reason">Cancellation reason: </label> |
1260 |
<label for="cancellation-reason">Cancellation reason: </label> |
1261 |
<select class="cancellation-reason" name="cancellation-reason" id="cancellation-reason"> |
1261 |
<select class="cancellation-reason" name="cancellation-reason" id="cancellation-reason"> |
1262 |
<option value="">No reason given</option> |
1262 |
<option value="">No reason given</option> |
Lines 1264-1269
Link Here
|
1264 |
<option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option> |
1264 |
<option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option> |
1265 |
[% END %] |
1265 |
[% END %] |
1266 |
</select> |
1266 |
</select> |
|
|
1267 |
|
1268 |
<input type="checkbox" name="cancellation-notify-patron" id="cancellation-notify-patron" value="1" checked/> |
1269 |
<label for="cancellation-notify-patron">Notify patron</label> |
1267 |
[% END %] |
1270 |
[% END %] |
1268 |
</fieldset> |
1271 |
</fieldset> |
1269 |
</div> |
1272 |
</div> |
Lines 1304-1310
Link Here
|
1304 |
<div class="holds_by_library"> |
1307 |
<div class="holds_by_library"> |
1305 |
<h4>[% Branches.GetName( b ) | html %]</h4> |
1308 |
<h4>[% Branches.GetName( b ) | html %]</h4> |
1306 |
|
1309 |
|
1307 |
[% INCLUDE holds_table.inc holds=holds_by_branch %] |
1310 |
[% INCLUDE holds_table.inc holds=holds_by_branch cancel_notice_branches=cancel_notice_branches %] |
1308 |
</div> |
1311 |
</div> |
1309 |
[% END # /FOREACh b %] |
1312 |
[% END # /FOREACh b %] |
1310 |
[% END # /IF ( branchcodes.empty ) %] |
1313 |
[% END # /IF ( branchcodes.empty ) %] |
Lines 1450-1456
Link Here
|
1450 |
<div id="cancel_hold_alert" class="alert alert-danger" style="display:none;"></div> |
1453 |
<div id="cancel_hold_alert" class="alert alert-danger" style="display:none;"></div> |
1451 |
<fieldset class="action"> |
1454 |
<fieldset class="action"> |
1452 |
[% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %] |
1455 |
[% SET hold_cancellation = AuthorisedValues.GetAuthValueDropbox('HOLD_CANCELLATION') %] |
1453 |
[% IF hold_cancellation.count %] |
1456 |
[% IF hold_cancellation.count && cancel_notice_branches.size %] |
1454 |
<label for="cancellation-reason">Cancellation reason: </label> |
1457 |
<label for="cancellation-reason">Cancellation reason: </label> |
1455 |
<select class="cancellation-reason" name="cancellation-reason" id="modal-cancellation-reason"> |
1458 |
<select class="cancellation-reason" name="cancellation-reason" id="modal-cancellation-reason"> |
1456 |
<option value="">No reason given</option> |
1459 |
<option value="">No reason given</option> |
Lines 1458-1463
Link Here
|
1458 |
<option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option> |
1461 |
<option value="[% reason.authorised_value | html %]">[% reason.lib | html %]</option> |
1459 |
[% END %] |
1462 |
[% END %] |
1460 |
</select> |
1463 |
</select> |
|
|
1464 |
|
1465 |
<input type="checkbox" name="cancellation-notify-patron" id="cancellation-notify-patron" value="1" checked> |
1466 |
<label for="cancellation-notify-patron">Notify patron</label> |
1461 |
[% END %] |
1467 |
[% END %] |
1462 |
</fieldset> |
1468 |
</fieldset> |
1463 |
</div> |
1469 |
</div> |
Lines 1531-1542
Link Here
|
1531 |
$.fn.select2.defaults.set("dropdownAutoWidth", true ); |
1537 |
$.fn.select2.defaults.set("dropdownAutoWidth", true ); |
1532 |
|
1538 |
|
1533 |
$(document).ready(function() { |
1539 |
$(document).ready(function() { |
1534 |
$('#cancellation-reason-fieldset').hide(); |
1540 |
$('#cancellation-reason-fieldset, .no-notice-warning').hide(); |
1535 |
$('.rank-request').on('change', function() { |
1541 |
$('.rank-request').on('change', function() { |
1536 |
if ( $(".rank-request option:selected[value='del']").length ) { |
1542 |
if ( $(".rank-request option:selected[value='del']").length ) { |
1537 |
$('#cancellation-reason-fieldset').show(); |
1543 |
$('#cancellation-reason-fieldset').show(); |
|
|
1544 |
$('.no-notice-warning').show(); |
1538 |
} else { |
1545 |
} else { |
1539 |
$('#cancellation-reason-fieldset').hide(); |
1546 |
$('#cancellation-reason-fieldset').hide(); |
|
|
1547 |
$('.no-notice-warning').hide(); |
1540 |
} |
1548 |
} |
1541 |
}); |
1549 |
}); |
1542 |
|
1550 |
|
Lines 1852-1862
Link Here
|
1852 |
e.preventDefault; |
1860 |
e.preventDefault; |
1853 |
cancel_link = $(this); |
1861 |
cancel_link = $(this); |
1854 |
$("#cancel_modal_form #inputs").empty(); |
1862 |
$("#cancel_modal_form #inputs").empty(); |
1855 |
let reserve_id = cancel_link.data('id'); |
1863 |
let reserve_id = cancel_link.data('id'); |
1856 |
let biblionumber = cancel_link.data('biblionumber'); |
1864 |
let biblionumber = cancel_link.data('biblionumber'); |
1857 |
$("#cancel_modal_form #inputs").append('<input type="hidden" name="reserve_id" value="' + reserve_id + '">'); |
1865 |
$("#cancel_modal_form #inputs").append('<input type="hidden" name="reserve_id" value="' + reserve_id + '">'); |
1858 |
$("#cancel_modal_form #inputs").append('<input type="hidden" name="biblionumber" value="' + biblionumber + '">'); |
1866 |
$("#cancel_modal_form #inputs").append('<input type="hidden" name="biblionumber" value="' + biblionumber + '">'); |
1859 |
$("#cancel_modal_form #inputs").append('<input type="hidden" name="op" value="cud-cancel">'); |
1867 |
$("#cancel_modal_form #inputs").append('<input type="hidden" name="op" value="cud-cancel">'); |
1860 |
$('#cancelModal').modal('show'); |
1868 |
$('#cancelModal').modal('show'); |
1861 |
return false; |
1869 |
return false; |
1862 |
}); |
1870 |
}); |