|
Lines 1505-1524
Link Here
|
| 1505 |
[% INCLUDE 'calendar.inc' %] |
1505 |
[% INCLUDE 'calendar.inc' %] |
| 1506 |
[% Asset.js("js/pages/circulation.js") | $raw %] |
1506 |
[% Asset.js("js/pages/circulation.js") | $raw %] |
| 1507 |
[% Asset.js("js/modal_printer.js") | $raw %] |
1507 |
[% Asset.js("js/modal_printer.js") | $raw %] |
|
|
1508 |
<script> |
| 1509 |
/* Set a variable needed by resolve_claim_modal.js or add_catalog_concern.js */ |
| 1510 |
var logged_in_user_borrowernumber = "[% logged_in_user.borrowernumber | html %]"; |
| 1511 |
|
| 1512 |
var table_settings = [% TablesSettings.GetTableSettings( 'circ', 'returns', 'checkedintable', 'json' ) | $raw %] |
| 1513 |
|
| 1514 |
const reserve_id = "[% reserve_id | html %]"; |
| 1515 |
const recall_id = "[% recall_id | html %]"; |
| 1516 |
|
| 1517 |
const print_slip = [% print_slip ? 1 : 0 | html %]; |
| 1518 |
const recall_slip = [% recall_slip ? 1 : 0 | html %]; |
| 1519 |
const overduecharges = [% overduecharges ? 1 : 0 | html %]; |
| 1520 |
const was_transferred = [% transfer ? 1 : 0 | html %]; |
| 1521 |
|
| 1522 |
addPrefs({ |
| 1523 |
TransfersBlockCirc: [% Koha.Preference('TransfersBlockCirc') ? 1 : 0 | html %], |
| 1524 |
AutomaticConfirmTransfer: [% Koha.Preference('AutomaticConfirmTransfer') ? 1 : 0 | html %], |
| 1525 |
}); |
| 1526 |
</script> |
| 1527 |
|
| 1508 |
[% IF ( ReturnClaims ) %] |
1528 |
[% IF ( ReturnClaims ) %] |
| 1509 |
<script> |
|
|
| 1510 |
/* Set a variable needed by resolve_claim_modal.js */ |
| 1511 |
var logged_in_user_borrowernumber = "[% logged_in_user.borrowernumber | html %]"; |
| 1512 |
</script> |
| 1513 |
[% Asset.js("js/resolve_claim_modal.js") | $raw %] |
1529 |
[% Asset.js("js/resolve_claim_modal.js") | $raw %] |
| 1514 |
[% END %] |
1530 |
[% END %] |
| 1515 |
[% IF ( Koha.Preference('CatalogConcerns') ) %] |
1531 |
[% IF ( Koha.Preference('CatalogConcerns') ) %] |
| 1516 |
<script> |
|
|
| 1517 |
/* Set a variable needed by add_catalog_concern.js */ |
| 1518 |
var logged_in_user_borrowernumber = "[% logged_in_user.borrowernumber | html %]"; |
| 1519 |
</script> |
| 1520 |
[% Asset.js("js/modals/add_catalog_concern.js") | $raw %] |
1532 |
[% Asset.js("js/modals/add_catalog_concern.js") | $raw %] |
| 1521 |
[% END %] |
1533 |
[% END %] |
|
|
1534 |
|
| 1522 |
<script> |
1535 |
<script> |
| 1523 |
function Dopop(link) { |
1536 |
function Dopop(link) { |
| 1524 |
var newin = window.open(link, 'popup', 'width=600,height=400,resizable=1,toolbar=0,scrollbars=1,top'); |
1537 |
var newin = window.open(link, 'popup', 'width=600,height=400,resizable=1,toolbar=0,scrollbars=1,top'); |
|
Lines 1547-1566
Link Here
|
| 1547 |
e.preventDefault(); |
1560 |
e.preventDefault(); |
| 1548 |
$(".modal.audio-alert-action").modal("show"); |
1561 |
$(".modal.audio-alert-action").modal("show"); |
| 1549 |
}); |
1562 |
}); |
| 1550 |
[% IF reserve_id %] |
1563 |
if (reserve_id){ |
| 1551 |
$(".print-slip").on('click', function(e) { |
1564 |
$(".print-slip").on('click', function(e) { |
| 1552 |
e.preventDefault(); |
1565 |
e.preventDefault(); |
| 1553 |
Dopop("hold-transfer-slip.pl?reserve_id=[% reserve_id | uri %]"); |
1566 |
Dopop("hold-transfer-slip.pl?reserve_id=" + reserve_id ); |
| 1554 |
}); |
1567 |
}); |
| 1555 |
[% IF print_slip %] |
1568 |
if (print_slip){ |
| 1556 |
Dopop("hold-transfer-slip.pl?reserve_id=[% reserve_id | uri %]"); |
1569 |
Dopop("hold-transfer-slip.pl?reserve_id=" + reserve_id ); |
| 1557 |
[% END %] |
1570 |
} |
| 1558 |
[% END %] |
1571 |
} |
| 1559 |
var table_settings = [% TablesSettings.GetTableSettings( 'circ', 'returns', 'checkedintable', 'json' ) | $raw %] |
|
|
| 1560 |
|
1572 |
|
| 1561 |
[% IF recall_slip %] |
1573 |
if (recall_slip){ |
| 1562 |
Dopop('/cgi-bin/koha/recalls/recall_pickup_slip.pl?recall_id=[% recall_id | uri %]'); |
1574 |
Dopop('/cgi-bin/koha/recalls/recall_pickup_slip.pl?recall_id=' + recall_id); |
| 1563 |
[% END %] |
1575 |
} |
| 1564 |
|
1576 |
|
| 1565 |
var returns_table = $("#checkedintable").kohaTable( |
1577 |
var returns_table = $("#checkedintable").kohaTable( |
| 1566 |
{ |
1578 |
{ |
|
Lines 1610-1616
Link Here
|
| 1610 |
$("#barcode").focus(); |
1622 |
$("#barcode").focus(); |
| 1611 |
}); |
1623 |
}); |
| 1612 |
|
1624 |
|
| 1613 |
[% IF(overduecharges) %] |
1625 |
if (overduecharges){ |
| 1614 |
$("#barcode").focus(function () { |
1626 |
$("#barcode").focus(function () { |
| 1615 |
if (($("#exemptcheck").prop("checked") == true) || ($("#dropboxcheck").prop("checked") == true)) { |
1627 |
if (($("#exemptcheck").prop("checked") == true) || ($("#dropboxcheck").prop("checked") == true)) { |
| 1616 |
$("#barcode").addClass("input-warning"); |
1628 |
$("#barcode").addClass("input-warning"); |
|
Lines 1621-1627
Link Here
|
| 1621 |
$("#barcode").blur(function () { |
1633 |
$("#barcode").blur(function () { |
| 1622 |
$("#barcode").removeClass("input-warning"); |
1634 |
$("#barcode").removeClass("input-warning"); |
| 1623 |
}); |
1635 |
}); |
| 1624 |
[% END %] |
1636 |
} |
| 1625 |
|
1637 |
|
| 1626 |
$('.openWin').on("click",function(e){ |
1638 |
$('.openWin').on("click",function(e){ |
| 1627 |
Dopop( $(this).data("url") ); |
1639 |
Dopop( $(this).data("url") ); |
|
Lines 1757-1772
Link Here
|
| 1757 |
], |
1769 |
], |
| 1758 |
}); |
1770 |
}); |
| 1759 |
|
1771 |
|
| 1760 |
[% IF ( !(Koha.Preference('TransfersBlockCirc')) && Koha.Preference('AutomaticConfirmTransfer') ) %] |
1772 |
if( !prefs.TransfersBlockCirc && prefs.AutomaticConfirmTransfer ){ |
| 1761 |
$("#wrong-transfer-modal").on('hidden.bs.modal',function(){ |
1773 |
$("#wrong-transfer-modal").on('hidden.bs.modal',function(){ |
| 1762 |
$("#wrongtransferform").submit(); |
1774 |
$("#wrongtransferform").submit(); |
| 1763 |
}); |
1775 |
}); |
| 1764 |
[% IF (transfer) %] |
1776 |
if (was_transferred){ |
| 1765 |
$("#item-transfer-modal").on('hidden.bs.modal',function(){ |
1777 |
$("#item-transfer-modal").on('hidden.bs.modal',function(){ |
| 1766 |
$("#mainform").submit(); |
1778 |
$("#mainform").submit(); |
| 1767 |
}); |
1779 |
}); |
| 1768 |
[% END %] |
1780 |
} |
| 1769 |
[% END %] |
1781 |
} |
| 1770 |
}); |
1782 |
}); |
| 1771 |
</script> |
1783 |
</script> |
| 1772 |
[% END %] |
1784 |
[% END %] |
| 1773 |
- |
|
|