Lines 666-676
Link Here
|
666 |
<a href="#" title="Checkout settings"><i class="fa-solid fa-sliders"></i></a> |
666 |
<a href="#" title="Checkout settings"><i class="fa-solid fa-sliders"></i></a> |
667 |
</div> |
667 |
</div> |
668 |
|
668 |
|
669 |
[% IF waiting_holds_barcodes %] |
669 |
<button type="submit" class="btn btn-primary">Check out</button> |
670 |
<button type="button" class="btn btn-primary">Check out</button> |
|
|
671 |
[% ELSE %] |
672 |
<button type="submit" class="btn btn-primary">Check out</button> |
673 |
[% END %] |
674 |
|
670 |
|
675 |
<div class="circ-settings"> |
671 |
<div class="circ-settings"> |
676 |
|
672 |
|
Lines 966-994
Link Here
|
966 |
[% FOREACH b IN waiting_holds_barcodes %] |
962 |
[% FOREACH b IN waiting_holds_barcodes %] |
967 |
waiting_holds_barcodes.push("[% b | html %]"); |
963 |
waiting_holds_barcodes.push("[% b | html %]"); |
968 |
[% END %] |
964 |
[% END %] |
969 |
$('#barcode').on('keyup', function() { |
965 |
$('#mainform').on('submit', function() { |
970 |
$('#mainform .btn-primary').off('click'); |
966 |
if (waiting_holds_barcodes) { |
971 |
$('#barcode').off('keypress'); |
967 |
if ( waiting_holds_barcodes.includes($('#barcode').val().trim()) ) { |
972 |
if ( waiting_holds_barcodes.includes($('#barcode').val().trim()) ) { |
968 |
return true; |
973 |
$('#mainform .btn-primary').on('click',function() { |
969 |
} else { |
974 |
$('#mainform').submit(); |
|
|
975 |
}); |
976 |
|
977 |
$('#barcode').on('keypress', function(e) { |
978 |
if (e.which == 13) { |
979 |
$('#mainform').submit(); |
980 |
} |
981 |
}); |
982 |
} else { |
983 |
$('#mainform .btn-primary').on('click',function() { |
984 |
$('#circ-warnwaitingholds-modal').modal(); |
970 |
$('#circ-warnwaitingholds-modal').modal(); |
985 |
}); |
971 |
return false; |
986 |
|
972 |
} |
987 |
$('#barcode').on('keypress', function(e) { |
973 |
} else { |
988 |
if (e.which == 13) { |
974 |
return true; |
989 |
$('#circ-warnwaitingholds-modal').modal(); |
|
|
990 |
} |
991 |
}); |
992 |
} |
975 |
} |
993 |
}); |
976 |
}); |
994 |
[% END %] |
977 |
[% END %] |
995 |
- |
|
|