View | Details | Raw Unified | Return to bug 20959
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss (-8 / +20 lines)
Lines 483-493 input { Link Here
483
        }
483
        }
484
    }
484
    }
485
485
486
    &.alert {
487
        background-color: #FFFF99;
488
        border-color: #900;
489
    }
490
491
    &.submit {
486
    &.submit {
492
        @include default-button;
487
        @include default-button;
493
488
Lines 506-511 input { Link Here
506
    }
501
    }
507
}
502
}
508
503
504
.input-warning {
505
    background-color: #FFFF99;
506
    border-color: #900;
507
}
508
509
label,
509
label,
510
.label {
510
.label {
511
    color: #000;
511
    color: #000;
Lines 1909-1915 i { Link Here
1909
    }
1909
    }
1910
}
1910
}
1911
1911
1912
.checkout-setting {
1912
.circ-setting {
1913
    font-size: 85%;
1913
    font-size: 85%;
1914
    padding-top: .3em;
1914
    padding-top: .3em;
1915
1915
Lines 1923-1929 i { Link Here
1923
    }
1923
    }
1924
}
1924
}
1925
1925
1926
.checkout-settings {
1926
.circ-settings {
1927
    background-color: #F4F8F9;
1927
    background-color: #F4F8F9;
1928
    border-radius: 0;
1928
    border-radius: 0;
1929
    border-top: 2px solid #B9D8D9;
1929
    border-top: 2px solid #B9D8D9;
Lines 1934-1943 i { Link Here
1934
    padding: 1em 1em 0;
1934
    padding: 1em 1em 0;
1935
}
1935
}
1936
1936
1937
#show-checkout-settings {
1937
#show-circ-settings {
1938
    margin-top: .5em;
1938
    margin-top: .5em;
1939
}
1939
}
1940
1940
1941
.checkin-active-setting {
1942
    background-color: #FFC;
1943
    border-radius: 3px;
1944
    margin: .5em;
1945
    padding: .5em;
1946
    box-shadow: 1px 1px 2px 0 rgba(102, 102, 102, .5);
1947
}
1948
1949
.form-control-group {
1950
    white-space: nowrap;
1951
}
1952
1941
.blocker {
1953
.blocker {
1942
    color: #990000;
1954
    color: #990000;
1943
}
1955
}
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt (-8 / +8 lines)
Lines 527-541 No patron matched <span class="ex">[% message | html %]</span> Link Here
527
    [% END %]
527
    [% END %]
528
    <button type="submit" class="btn btn-default">Check out</button>
528
    <button type="submit" class="btn btn-default">Check out</button>
529
529
530
    <div id="show-checkout-settings">
530
    <div id="show-circ-settings">
531
        <a href="#"><i class="fa fa-caret-right checkout-settings-icon"></i> Checkout settings</a>
531
        <a href="#"><i class="fa fa-caret-right circ-settings-icon"></i> Checkout settings</a>
532
    </div>
532
    </div>
533
533
534
    <div class="checkout-settings">
534
    <div class="circ-settings">
535
535
536
        [% UNLESS ( noissues && Koha.Preference('OnSiteCheckoutsForce') ) %]
536
        [% UNLESS ( noissues && Koha.Preference('OnSiteCheckoutsForce') ) %]
537
            [% IF ( SpecifyDueDate ) %]
537
            [% IF ( SpecifyDueDate ) %]
538
                <div id="specify-due-date" class="checkout-setting">
538
                <div id="specify-due-date" class="circ-setting">
539
                    <div class="hint">Specify due date [% INCLUDE 'date-format.inc' %]: </div>
539
                    <div class="hint">Specify due date [% INCLUDE 'date-format.inc' %]: </div>
540
                    [% IF ( duedatespec ) %]
540
                    [% IF ( duedatespec ) %]
541
                        <input type="text" size="13" id="duedatespec" name="duedatespec" value="[% duedatespec | html %]" />
541
                        <input type="text" size="13" id="duedatespec" name="duedatespec" value="[% duedatespec | html %]" />
Lines 554-560 No patron matched <span class="ex">[% message | html %]</span> Link Here
554
        [% END %]
554
        [% END %]
555
555
556
        [% UNLESS ( noissues ) %]
556
        [% UNLESS ( noissues ) %]
557
            <div id="set-automatic-renewal" class="checkout-setting">
557
            <div id="set-automatic-renewal" class="circ-setting">
558
                [% IF NEEDSCONFIRMATION %]
558
                [% IF NEEDSCONFIRMATION %]
559
                    <input type="checkbox" name="auto_renew" id="auto_renew" value="auto_renew" disabled="disabled" />
559
                    <input type="checkbox" name="auto_renew" id="auto_renew" value="auto_renew" disabled="disabled" />
560
                [% ELSE %]
560
                [% ELSE %]
Lines 564-570 No patron matched <span class="ex">[% message | html %]</span> Link Here
564
                <label for="auto_renew">Automatic renewal</label>
564
                <label for="auto_renew">Automatic renewal</label>
565
            </div>
565
            </div>
566
            [% IF Koha.Preference('decreaseLoanHighHolds') %]
566
            [% IF Koha.Preference('decreaseLoanHighHolds') %]
567
                <div id="set_high_holds_overrride" class="checkout-setting">
567
                <div id="set_high_holds_overrride" class="circ-setting">
568
                    [% IF NEEDSCONFIRMATION %]
568
                    [% IF NEEDSCONFIRMATION %]
569
                        [% IF override_high_holds %]
569
                        [% IF override_high_holds %]
570
                            <input type="checkbox" name="override_high_holds" id="override_high_holds" value="1" disabled="disabled" checked="checked"/>
570
                            <input type="checkbox" name="override_high_holds" id="override_high_holds" value="1" disabled="disabled" checked="checked"/>
Lines 584-590 No patron matched <span class="ex">[% message | html %]</span> Link Here
584
        [% END %]
584
        [% END %]
585
585
586
        [% IF Koha.Preference('OnSiteCheckouts') %]
586
        [% IF Koha.Preference('OnSiteCheckouts') %]
587
            <div id="onsite_checkout-select" class="checkout-setting">
587
            <div id="onsite_checkout-select" class="circ-setting">
588
                [% IF noissues %]
588
                [% IF noissues %]
589
                    <div class="onsite-checkout-only">
589
                    <div class="onsite-checkout-only">
590
                        <input type="checkbox" id="onsite_checkout" name="onsite_checkout_forced" checked="checked" disabled="disabled" /> <label for="onsite_checkout">On-site checkouts only. Automatic due date: </label>
590
                        <input type="checkbox" id="onsite_checkout" name="onsite_checkout_forced" checked="checked" disabled="disabled" /> <label for="onsite_checkout">On-site checkouts only. Automatic due date: </label>
Lines 597-603 No patron matched <span class="ex">[% message | html %]</span> Link Here
597
            </div>
597
            </div>
598
        [% END %]
598
        [% END %]
599
599
600
    </div> <!-- /.checkout-settings -->
600
    </div> <!-- /.circ-settings -->
601
601
602
          <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% patron.borrowernumber | html %]" />
602
          <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% patron.borrowernumber | html %]" />
603
          <input type="hidden" name="branch" value="[% branch | html %]" />
603
          <input type="hidden" name="branch" value="[% branch | html %]" />
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt (-86 / +92 lines)
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"/>
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"/>
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"/>
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 %]" value="[% inputloo.barcode %]" />
615
                    <input type="hidden" name="dd-[% inputloo.counter %]" value="[% inputloo.duedate %]" />
616
                    <input type="hidden" name="bn-[% inputloo.counter %]" value="[% inputloo.borrowernumber %]" />
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', function() {
779
            $(".modal").modal({ backdrop: 'static' }).on('shown', function() {
761
                $("#barcode").prop("disabled", true);
780
                $("#barcode").prop("disabled", true);
Lines 805-836 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);
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
(-)a/koha-tmpl/intranet-tmpl/prog/js/pages/circulation.js (-15 / +14 lines)
Lines 54-79 $(document).ready(function() { Link Here
54
        return false;
54
        return false;
55
    });
55
    });
56
56
57
    var checkout_settings = $(".checkout-settings");
57
    var circ_settings = $(".circ-settings");
58
    var checkout_settings_icon = $(".checkout-settings-icon");
58
    var circ_settings_icon = $(".circ-settings-icon");
59
59
60
    // If any checkboxes in the checkout settings are selected, show the settings by default
60
    // If any checkboxes in the circ settings are selected, show the settings by default
61
    if ( $(".checkout-settings input:checked,#duedatespec[value!='']").length ) {
61
    if ( $(".circ-settings input:checked,#duedatespec[value!='']").length ) {
62
        checkout_settings.show();
62
        circ_settings.show();
63
        checkout_settings_icon.removeClass("fa-caret-right").addClass("fa-caret-down");
63
        circ_settings_icon.removeClass("fa-caret-right").addClass("fa-caret-down");
64
    } else {
64
    } else {
65
        checkout_settings.hide();
65
        circ_settings.hide();
66
        checkout_settings_icon.removeClass("fa-caret-down").addClass("fa-caret-right");
66
        circ_settings_icon.removeClass("fa-caret-down").addClass("fa-caret-right");
67
    }
67
    }
68
68
69
    $("#show-checkout-settings a").on("click",function(){
69
    $("#show-circ-settings a").on("click",function(){
70
        if( checkout_settings.is(":hidden")){
70
        if( circ_settings.is(":hidden")){
71
            checkout_settings.show();
71
            circ_settings.show();
72
            checkout_settings_icon.removeClass("fa-caret-right").addClass("fa-caret-down");
72
            circ_settings_icon.removeClass("fa-caret-right").addClass("fa-caret-down");
73
        } else {
73
        } else {
74
            $("#barcode").focus();
74
            $("#barcode").focus();
75
            checkout_settings.hide();
75
            circ_settings.hide();
76
            checkout_settings_icon.removeClass("fa-caret-down").addClass("fa-caret-right");
76
            circ_settings_icon.removeClass("fa-caret-down").addClass("fa-caret-right");
77
        }
77
        }
78
    });
78
    });
79
79
80
- 

Return to bug 20959