Lines 594-623
Link Here
|
594 |
</div> |
594 |
</div> |
595 |
[% END%] |
595 |
[% END%] |
596 |
|
596 |
|
597 |
<div id="exemptfines" class="dialog message" style="display:none;"> |
|
|
598 |
<p>Fines for returned items are forgiven.</p> |
599 |
</div> |
600 |
<div id="forgivemanualholdsexpire-alert" class="dialog message" style="display:none;"> |
601 |
<p>Fines are not charged for manually cancelled holds.</p> |
602 |
</div> |
603 |
<div id="dropboxmode" class="dialog message" style="display:none;"> |
604 |
<p>Book drop mode. (Effective checkin date is [% dropboxdate | html %] ).</p> |
605 |
</div> |
606 |
</div> |
597 |
</div> |
607 |
<div class="yui-g"> |
598 |
|
608 |
<form id="checkin-form" method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off" > |
599 |
<form id="checkin-form" method="post" action="/cgi-bin/koha/circ/returns.pl" autocomplete="off"> |
609 |
<div class="yui-u first"> |
600 |
<fieldset id="circ_returns_checkin"> |
610 |
<fieldset> |
601 |
<h3>Check in</h3> |
611 |
<legend>Check in</legend> |
602 |
<div class="row"> |
612 |
<label for="barcode">Enter item barcode: </label> |
603 |
<div class="col-sm-6"> |
613 |
[% IF ( exemptfine ) %] |
604 |
<div class="hint">Enter item barcode:</div> |
614 |
<input name="barcode" id="barcode" size="14" class="focus alert" type="text" /> |
605 |
[% IF ( exemptfine ) %] |
615 |
[% ELSIF ( dropboxmode ) %] |
606 |
<input name="barcode" id="barcode" size="14" class="barcode focus input-warning" /> |
616 |
<input name="barcode" id="barcode" size="14" class="focus alert" type="text" /> |
607 |
[% ELSIF ( dropboxmode ) %] |
617 |
[% ELSE %] |
608 |
<input name="barcode" id="barcode" size="14" class="barcode focus input-warning" /> |
618 |
<input name="barcode" id="barcode" size="14" class="focus" type="text" /> |
609 |
[% ELSE %] |
619 |
[% END %] |
610 |
<input name="barcode" id="barcode" size="14" class="barcode focus" /> |
620 |
<input type="submit" class="submit" value="Submit" /> |
611 |
[% END %] |
|
|
612 |
<button type="submit" class="btn btn-default">Check in</button> |
613 |
[% FOREACH inputloo IN inputloop %] |
614 |
<input type="hidden" name="ri-[% inputloo.counter | html %]" value="[% inputloo.barcode | html %]" /> |
615 |
<input type="hidden" name="dd-[% inputloo.counter | html %]" value="[% inputloo.duedate | html %]" /> |
616 |
<input type="hidden" name="bn-[% inputloo.counter | html %]" value="[% inputloo.borrowernumber | html %]" /> |
617 |
[% END %] |
618 |
<div id="show-circ-settings"> |
619 |
<a href="#"><i class="fa circ-settings-icon fa-caret-down"></i> Checkin settings</a> |
620 |
</div> |
621 |
</div> |
622 |
<div class="col-sm-6"> |
623 |
<div id="exemptfines" class="checkin-active-setting" style="display:none;"> |
624 |
<p><i class="fa fa-check"></i> Fines for returned items are forgiven.</p> |
625 |
</div> |
626 |
<div id="forgivemanualholdsexpire-alert" class="checkin-active-setting" style="display:none;"> |
627 |
<p><i class="fa fa-check"></i> Fines are not charged for manually cancelled holds.</p> |
628 |
</div> |
629 |
<div id="dropboxmode" class="checkin-active-setting" style="display:none;"> |
630 |
<p><i class="fa fa-check"></i> Book drop mode. (Effective checkin date is [% dropboxdate %] ).</p> |
631 |
</div> |
632 |
</div> |
633 |
</div> |
634 |
|
635 |
<div class="circ-settings"> |
621 |
|
636 |
|
622 |
[% IF Koha.Preference('SpecifyReturnDate') %] |
637 |
[% IF Koha.Preference('SpecifyReturnDate') %] |
623 |
<div class="date-select" id="return_date_override_fields"> |
638 |
<div class="date-select" id="return_date_override_fields"> |
Lines 631-684
Link Here
|
631 |
[% ELSE %] |
646 |
[% ELSE %] |
632 |
<input type="checkbox" id="return_date_override_remember" onclick="this.form.barcode.focus();" name="return_date_override_remember" /> |
647 |
<input type="checkbox" id="return_date_override_remember" onclick="this.form.barcode.focus();" name="return_date_override_remember" /> |
633 |
[% END %] |
648 |
[% END %] |
634 |
|
649 |
<button type="button" class="action btn btn-default btn-xs" id="cleardate" name="cleardate" onclick="this.checked = false; this.form.return_date_override.value = ''; this.form.return_date_override_remember.checked = false; this.form.barcode.focus(); return false;">Clear</button> |
635 |
<input type="button" class="action" id="cleardate" value="Clear" name="cleardate" onclick="this.checked = false; this.form.return_date_override.value = ''; this.form.return_date_override_remember.checked = false; this.form.barcode.focus(); return false;" /> |
650 |
</div> |
636 |
</div> |
|
|
637 |
[% END %] |
638 |
[% FOREACH inputloo IN inputloop %] |
639 |
<input type="hidden" name="ri-[% inputloo.counter | html %]" value="[% inputloo.barcode | html %]" /> |
640 |
<input type="hidden" name="dd-[% inputloo.counter | html %]" value="[% inputloo.duedate | html %]" /> |
641 |
<input type="hidden" name="bn-[% inputloo.counter | html %]" value="[% inputloo.borrowernumber | html %]" /> |
642 |
[% END %] |
651 |
[% END %] |
643 |
|
652 |
|
644 |
|
653 |
[% IF ( CAN_user_updatecharges_writeoff && overduecharges ) %] |
645 |
</fieldset> |
654 |
<div id="forgive-overdue-fines" class="circ-setting"> |
646 |
</div> |
655 |
[% IF ( exemptfine ) %] |
647 |
<div class="yui-u"> |
|
|
648 |
<fieldset id="checkin_options"> |
649 |
<legend>Options</legend> |
650 |
[% IF ( CAN_user_updatecharges_writeoff && overduecharges ) %] |
651 |
<p> |
652 |
[% IF ( exemptfine ) %] |
653 |
<input type="checkbox" id="exemptcheck" name="exemptfine" value="exemptfine" checked="checked" /> |
656 |
<input type="checkbox" id="exemptcheck" name="exemptfine" value="exemptfine" checked="checked" /> |
654 |
[% ELSE %] |
657 |
[% ELSE %] |
655 |
<input type="checkbox" id="exemptcheck" name="exemptfine" value="exemptfine" /> |
658 |
<input type="checkbox" id="exemptcheck" name="exemptfine" value="exemptfine" /> |
656 |
[% END %] |
659 |
[% END %] |
657 |
<label for="exemptcheck">Forgive overdue charges</label> |
660 |
<label for="exemptcheck">Forgive overdue charges</label> |
658 |
</p> |
661 |
</div> |
659 |
[% END %] <!-- overduecharges --> |
662 |
[% END %] |
660 |
<p> |
663 |
<!-- overduecharges --> |
661 |
[% IF ( dropboxmode ) %] |
664 |
<div id="book-drop-mode" class="circ-setting"> |
662 |
<input type="checkbox" id="dropboxcheck" name="dropboxmode" value="dropboxmode" checked="checked" /> |
665 |
[% IF ( dropboxmode ) %] |
663 |
[% ELSE %] |
666 |
<input type="checkbox" id="dropboxcheck" name="dropboxmode" value="dropboxmode" checked="checked" /> |
664 |
<input type="checkbox" id="dropboxcheck" name="dropboxmode" value="dropboxmode" /> |
667 |
[% ELSE %] |
665 |
[% END %] |
668 |
<input type="checkbox" id="dropboxcheck" name="dropboxmode" value="dropboxmode" /> |
666 |
<label for="dropboxcheck">Book drop mode</label> |
669 |
[% END %] |
667 |
</p> |
670 |
<label for="dropboxcheck">Book drop mode</label> |
668 |
[% IF Koha.Preference('ExpireReservesMaxPickUpDelayCharge') %] |
671 |
</div> |
669 |
<p> |
672 |
[% IF Koha.Preference('ExpireReservesMaxPickUpDelayCharge') %] |
670 |
[% IF ( forgivemanualholdsexpire ) %] |
673 |
<div id="forgive-manual-hold-fees" class="circ-setting"> |
|
|
674 |
[% IF ( forgivemanualholdsexpire ) %] |
671 |
<input type="checkbox" id="forgivemanualholdsexpire" name="forgivemanualholdsexpire" value="forgivemanualholdsexpire" checked="checked" /> |
675 |
<input type="checkbox" id="forgivemanualholdsexpire" name="forgivemanualholdsexpire" value="forgivemanualholdsexpire" checked="checked" /> |
672 |
[% ELSE %] |
676 |
[% ELSE %] |
673 |
<input type="checkbox" id="forgivemanualholdsexpire" name="forgivemanualholdsexpire" value="forgivemanualholdsexpire" /> |
677 |
<input type="checkbox" id="forgivemanualholdsexpire" name="forgivemanualholdsexpire" value="forgivemanualholdsexpire" /> |
674 |
[% END %] |
678 |
[% END %] |
675 |
<label for="forgivemanualholdsexpire">Forgive fees for manually expired holds</label> |
679 |
<label for="forgivemanualholdsexpire">Forgive fees for manually expired holds</label> |
676 |
</p> |
680 |
</div> |
677 |
[% END %] <!-- overduecharges --> |
681 |
[% END %] |
678 |
</fieldset> |
682 |
<!-- overduecharges --> |
679 |
</div> |
683 |
</div> [%# /.circ-settings %] |
680 |
</form> |
684 |
</fieldset> [%# /#circ_returns_checkin %] |
681 |
</div> |
685 |
</form> [%# /#checkin-form %] |
682 |
|
686 |
|
683 |
[% IF ( riloop ) %] |
687 |
[% IF ( riloop ) %] |
684 |
<h2>Checked-in items</h2> |
688 |
<h2>Checked-in items</h2> |
Lines 749-761
Link Here
|
749 |
[% INCLUDE 'columns_settings.inc' %] |
753 |
[% INCLUDE 'columns_settings.inc' %] |
750 |
[% INCLUDE 'calendar.inc' %] |
754 |
[% INCLUDE 'calendar.inc' %] |
751 |
[% Asset.js("lib/jquery/plugins/jquery-ui-timepicker-addon.min.js") | $raw %] |
755 |
[% Asset.js("lib/jquery/plugins/jquery-ui-timepicker-addon.min.js") | $raw %] |
|
|
756 |
[% Asset.js("js/pages/circulation.js") | $raw %] |
752 |
[% INCLUDE 'timepicker.inc' %] |
757 |
[% INCLUDE 'timepicker.inc' %] |
753 |
|
758 |
|
754 |
<script type="text/javascript"> |
759 |
<script> |
755 |
function Dopop(link) { |
760 |
function Dopop(link) { |
756 |
var newin = window.open(link, 'popup', 'width=600,height=400,resizable=1,toolbar=0,scrollbars=1,top'); |
761 |
var newin = window.open(link, 'popup', 'width=600,height=400,resizable=1,toolbar=0,scrollbars=1,top'); |
757 |
$("#barcode").focus(); |
762 |
$("#barcode").focus(); |
758 |
} |
763 |
} |
|
|
764 |
|
765 |
function check_valid_return_date() { |
766 |
if ( $("#return_date_override").val() ) { |
767 |
var datetime = DateTime_from_syspref( $("#return_date_override").val() ); |
768 |
var now = new Date(); |
769 |
if ( !datetime || datetime > now ) { |
770 |
alert("Invalid return date/time!"); |
771 |
$("#return_date_override").val("") |
772 |
return false; |
773 |
} |
774 |
} |
775 |
return true; |
776 |
} |
777 |
|
759 |
$(document).ready(function () { |
778 |
$(document).ready(function () { |
760 |
$(".modal").modal({ backdrop: 'static' }).on('shown.bs.modal', function() { |
779 |
$(".modal").modal({ backdrop: 'static' }).on('shown.bs.modal', function() { |
761 |
$("#barcode").prop("disabled", true); |
780 |
$("#barcode").prop("disabled", true); |
Lines 805-842
Link Here
|
805 |
} |
824 |
} |
806 |
}); |
825 |
}); |
807 |
|
826 |
|
808 |
function check_valid_return_date() { |
|
|
809 |
if ( $("#return_date_override").val() ) { |
810 |
var datetime = DateTime_from_syspref( $("#return_date_override").val() ); |
811 |
var now = new Date(); |
812 |
if ( !datetime || datetime > now ) { |
813 |
alert("Invalid return date/time!"); |
814 |
$("#return_date_override").val("") |
815 |
return false; |
816 |
} |
817 |
} |
818 |
return true; |
819 |
} |
820 |
|
821 |
$("#exemptcheck").change(function () { |
827 |
$("#exemptcheck").change(function () { |
822 |
if (this.checked == true) { |
828 |
if (this.checked == true) { |
823 |
$("#barcode").addClass("alert"); |
829 |
$("#barcode").addClass("input-warning"); |
824 |
$("#exemptfines").show(); |
830 |
$("#exemptfines").show(); |
825 |
} else { |
831 |
} else { |
826 |
$("#barcode").removeClass("alert"); |
832 |
$("#barcode").removeClass("input-warning"); |
827 |
$("#exemptfines").hide(); |
833 |
$("#exemptfines").hide(); |
828 |
} |
834 |
} |
829 |
$("#barcode").focus(); |
835 |
$("#barcode").focus(); |
830 |
}); |
836 |
}); |
831 |
$("#dropboxcheck").change(function () { |
837 |
$("#dropboxcheck").change(function () { |
832 |
if (this.checked == true) { |
838 |
if (this.checked == true) { |
833 |
$("#barcode").addClass("alert"); |
839 |
$("#barcode").addClass("input-warning"); |
834 |
$("#dropboxmode").show(); |
840 |
$("#dropboxmode").show(); |
835 |
|
841 |
|
836 |
$("#return_date_override_fields :input").prop('disabled', true); |
842 |
$("#return_date_override_fields :input").prop('disabled', true); |
837 |
$("#return_date_override").datetimepicker("disable"); |
843 |
$("#return_date_override").datetimepicker("disable"); |
838 |
} else { |
844 |
} else { |
839 |
$("#barcode").removeClass("alert"); |
845 |
$("#barcode").removeClass("input-warning"); |
840 |
$("#dropboxmode").hide(); |
846 |
$("#dropboxmode").hide(); |
841 |
|
847 |
|
842 |
$("#return_date_override_fields :input").prop('disabled', false); |
848 |
$("#return_date_override_fields :input").prop('disabled', false); |
Lines 846-855
Link Here
|
846 |
}); |
852 |
}); |
847 |
$("#forgivemanualholdsexpire").change(function () { |
853 |
$("#forgivemanualholdsexpire").change(function () { |
848 |
if (this.checked == true) { |
854 |
if (this.checked == true) { |
849 |
$("#barcode").addClass("alert"); |
855 |
$("#barcode").addClass("input-warning"); |
850 |
$("#forgivemanualholdsexpire-alert").show(); |
856 |
$("#forgivemanualholdsexpire-alert").show(); |
851 |
} else { |
857 |
} else { |
852 |
$("#barcode").removeClass("alert"); |
858 |
$("#barcode").removeClass("input-warning"); |
853 |
$("#forgivemanualholdsexpire-alert").hide(); |
859 |
$("#forgivemanualholdsexpire-alert").hide(); |
854 |
} |
860 |
} |
855 |
$("#barcode").focus(); |
861 |
$("#barcode").focus(); |
Lines 858-870
Link Here
|
858 |
[% IF(overduecharges) %] |
864 |
[% IF(overduecharges) %] |
859 |
$("#barcode").focus(function () { |
865 |
$("#barcode").focus(function () { |
860 |
if (($("#exemptcheck").prop("checked") == true) || ($("#dropboxcheck").prop("checked") == true)) { |
866 |
if (($("#exemptcheck").prop("checked") == true) || ($("#dropboxcheck").prop("checked") == true)) { |
861 |
$("#barcode").addClass("alert"); |
867 |
$("#barcode").addClass("input-warning"); |
862 |
} else { |
868 |
} else { |
863 |
$("#barcode").removeClass("alert"); |
869 |
$("#barcode").removeClass("input-warning"); |
864 |
} |
870 |
} |
865 |
}); |
871 |
}); |
866 |
$("#barcode").blur(function () { |
872 |
$("#barcode").blur(function () { |
867 |
$("#barcode").removeClass("alert"); |
873 |
$("#barcode").removeClass("input-warning"); |
868 |
}); |
874 |
}); |
869 |
[% END %] |
875 |
[% END %] |
870 |
|
876 |
|