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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt (-277 / +281 lines)
Lines 89-94 Link Here
89
        .icon-set-lowest::before {
89
        .icon-set-lowest::before {
90
            content: "\f04e";
90
            content: "\f04e";
91
        }
91
        }
92
        :disabled{
93
            opacity:0.5
94
        }
92
    </style>
95
    </style>
93
[% END %]
96
[% END %]
94
</head>
97
</head>
Lines 571-620 Link Here
571
                                    [% END %]
574
                                    [% END %]
572
                                </legend>
575
                                </legend>
573
                                <input type="hidden" name="alreadyreserved" value="[% alreadyreserved | html %]" />
576
                                <input type="hidden" name="alreadyreserved" value="[% alreadyreserved | html %]" />
574
                                <ol>
577
                                <fieldset class="enable_request_any disable_request_group disable_request_specific">
578
                                    <ol>
575
579
576
                                    <li>
577
                                        <label for="pickup">Pickup at:</label>
578
                                        <select name="pickup" id="pickup-next-avail"
579
                                                data-biblio-id="[% biblio.biblionumber | html %]"
580
                                                data-patron-id="[% patron.borrowernumber | html %]"
581
                                                data-pickup-location-source="biblio">
582
                                            [% PROCESS options_for_libraries libraries => Branches.pickup_locations({ search_params => { biblio => biblionumber, patron => patron }, selected => pickup }) %]
583
                                        </select>
584
                                    </li>
585
586
                                    [% IF Koha.Preference('AllowHoldItemTypeSelection') %]
587
                                        <li>
580
                                        <li>
588
                                            <label for="itemtype">Request specific item type:</label>
581
                                            <label for="pickup">Pickup at:</label>
589
                                            <select name="itemtype" id="itemtype">
582
                                            <select name="pickup" id="pickup-next-avail"
590
                                                <option value="">Any item type</option>
583
                                                    data-biblio-id="[% biblio.biblionumber | html %]"
591
                                                [%- FOREACH itemtype IN available_itemtypes %]
584
                                                    data-patron-id="[% patron.borrowernumber | html %]"
592
                                                    <option value="[% itemtype | html %]">[% ItemTypes.GetDescription( itemtype ) | html %]</option>
585
                                                    data-pickup-location-source="biblio">
593
                                                [%- END %]
586
                                                [% PROCESS options_for_libraries libraries => Branches.pickup_locations({ search_params => { biblio => biblionumber, patron => patron }, selected => pickup }) %]
594
                                            </select>
587
                                            </select>
595
                                        </li>
588
                                        </li>
596
                                    [% END %]
589
597
                                    [% IF remaining_holds_for_record > 1 %]
590
                                        [% IF Koha.Preference('AllowHoldItemTypeSelection') %]
598
                                        <li>
591
                                            <li>
599
                                            <label for="holds_to_place_count">Holds to place (count)</label>
592
                                                <label for="itemtype">Request specific item type:</label>
600
                                            <input type="text" inputmode="numeric" pattern="[0-9]*" id="holds_to_place_count" name="holds_to_place_count" maxlength="[% remaining_holds_for_record | html %]" value="1" />
593
                                                <select name="itemtype" id="itemtype">
601
                                        </li>
594
                                                    <option value="">Any item type</option>
602
                                    [% ELSE %]
595
                                                    [%- FOREACH itemtype IN available_itemtypes %]
603
                                        <input type="hidden" name="holds_to_place_count" value="1" />
596
                                                        <option value="[% itemtype | html %]">[% ItemTypes.GetDescription( itemtype ) | html %]</option>
604
                                    [% END %]
597
                                                    [%- END %]
605
                                </ol>
598
                                                </select>
599
                                            </li>
600
                                        [% END %]
601
                                        [% IF remaining_holds_for_record > 1 %]
602
                                            <li>
603
                                                <label for="holds_to_place_count">Holds to place (count)</label>
604
                                                <input type="text" inputmode="numeric" pattern="[0-9]*" id="holds_to_place_count" name="holds_to_place_count" maxlength="[% remaining_holds_for_record | html %]" value="1" />
605
                                            </li>
606
                                        [% ELSE %]
607
                                            <input type="hidden" name="holds_to_place_count" value="1" />
608
                                        [% END %]
609
                                    </ol>
606
610
607
611
608
                            <fieldset class="action">
612
                                <fieldset class="action">
609
                                [% IF ( patron.borrowernumber ) %]
613
                                    [% IF ( patron.borrowernumber ) %]
610
                                    [% IF ( override_required ) %]
614
                                        [% IF ( override_required ) %]
611
                                        <button type="submit" id="hold_any_btn" class="btn btn-primary warning"><i class="fa fa-exclamation-triangle "></i> Place hold</button>
615
                                            <button type="submit" id="hold_any_btn" class="btn btn-primary warning"><i class="fa fa-exclamation-triangle "></i> Place hold</button>
612
                                    [% ELSIF ( none_available ) %]
616
                                        [% ELSIF ( none_available ) %]
613
                                        <button type="submit" id="hold_any_btn" disabled="disabled" class="btn btn-primary btn-disabled">Place hold</button>
617
                                            <button type="submit" id="hold_any_btn" disabled="disabled" class="btn btn-primary btn-disabled">Place hold</button>
614
                                    [% ELSE %]
618
                                        [% ELSE %]
615
                                        <button type="submit" id="hold_any_btn" class="btn btn-primary">Place hold</button>
619
                                            <button type="submit" id="hold_any_btn" class="btn btn-primary">Place hold</button>
620
                                        [% END %]
616
                                    [% END %]
621
                                    [% END %]
617
                                [% END %]
622
                                </fieldset>
618
                            </fieldset>
623
                            </fieldset>
619
                        </fieldset>
624
                        </fieldset>
620
625
Lines 638-643 Link Here
638
                                [% END %]
643
                                [% END %]
639
                            </legend>
644
                            </legend>
640
645
646
                            <fieldset class="enable_request_group disable_request_any disable_request_specific">
641
                            [% IF force_hold_level == 'record' # Patron has placed a record level hold previously for this record %]
647
                            [% IF force_hold_level == 'record' # Patron has placed a record level hold previously for this record %]
642
                                <span class="error">
648
                                <span class="error">
643
                                    <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
649
                                    <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
Lines 685-691 Link Here
685
                                    </li>
691
                                    </li>
686
                                </ul>
692
                                </ul>
687
                            [% END %]
693
                            [% END %]
688
                            <button type="submit" id="hold_grp_btn" class="btn btn-primary warning">Place hold</button>
694
                                <fieldset class="action">
695
                                    <button type="submit" id="hold_grp_btn" class="btn btn-primary warning">Place hold</button>
696
                                </fieldset>
697
                            </fieldset>
689
                        </fieldset>
698
                        </fieldset>
690
                        [% END %]
699
                        [% END %]
691
                        <!-- /ItemGroup level holds -->
700
                        <!-- /ItemGroup level holds -->
Lines 705-939 Link Here
705
                                     <input type="radio" id="requestspecificitem" name="request" class="requestspecific"/>
714
                                     <input type="radio" id="requestspecificitem" name="request" class="requestspecific"/>
706
                                [% END %]
715
                                [% END %]
707
                            </legend>
716
                            </legend>
717
                            <fieldset class="enable_request_specific disable_request_any disable_request_group">
708
718
709
                            <ol>
719
                                <ol>
710
                                [% UNLESS Koha.Preference('item-level_itypes') %]
720
                                    [% UNLESS Koha.Preference('item-level_itypes') %]
711
                                    <li>
721
                                        <li>
712
                                        <span class="label">Item type:</span>
722
                                            <span class="label">Item type:</span>
713
                                        [% biblio.itemtype.translated_description | html %]
723
                                            [% biblio.itemtype.translated_description | html %]
714
                                    </li>
724
                                        </li>
715
                                [% END %]
725
                                    [% END %]
716
726
717
                                [% IF ( biblio.biblioitem.publicationyear ) %]
727
                                    [% IF ( biblio.biblioitem.publicationyear ) %]
718
                                    <li>
728
                                        <li>
719
                                        <span class="label">Publication year:</span>
729
                                            <span class="label">Publication year:</span>
720
                                        [% biblio.biblioitem.publicationyear | html %]
730
                                            [% biblio.biblioitem.publicationyear | html %]
721
                                    </li>
731
                                        </li>
722
                                [% END %]
732
                                    [% END %]
723
                            </ol>
733
                                </ol>
724
734
725
                            <table id="requestspecific">
735
                                <table id="requestspecific">
726
                                <thead>
736
                                    <thead>
727
                                    <tr>
737
                                        <tr>
728
                                        <th>Hold</th>
738
                                            <th>Hold</th>
729
                                        <th>Allowed pickup locations</th>
739
                                            <th>Allowed pickup locations</th>
730
                                        [% IF Koha.Preference('item-level_itypes') %]
740
                                            [% IF Koha.Preference('item-level_itypes') %]
731
                                            <th>Item type</th>
741
                                                <th>Item type</th>
732
                                        [% END %]
742
                                            [% END %]
733
                                        <th>Barcode</th>
743
                                            <th>Barcode</th>
734
                                        [% IF Koha.Preference('EnableItemGroupHolds') && biblio.object.item_groups.count %]
744
                                            [% IF Koha.Preference('EnableItemGroupHolds') && biblio.object.item_groups.count %]
735
                                            <th>Item group</th>
745
                                                <th>Item group</th>
736
                                        [% END %]
746
                                            [% END %]
737
                                        <th>Home library</th>
747
                                            <th>Home library</th>
738
                                        <th>Last location</th>
748
                                            <th>Last location</th>
739
                                        [% IF itemdata_ccode %]
749
                                            [% IF itemdata_ccode %]
740
                                            <th>Collection</th>
750
                                                <th>Collection</th>
741
                                        [% END %]
751
                                            [% END %]
742
                                        <th>Call number</th>
752
                                            <th>Call number</th>
743
                                        <th>Copy number</th>
753
                                            <th>Copy number</th>
744
                                        [% IF itemdata_enumchron %]
754
                                            [% IF itemdata_enumchron %]
745
                                            <th>Vol no.</th>
755
                                                <th>Vol no.</th>
746
                                        [% END %]
756
                                            [% END %]
747
                                        <th>Information</th>
757
                                            <th>Information</th>
748
                                    </tr>
758
                                        </tr>
749
                                </thead>
759
                                    </thead>
750
                                <tbody>
760
                                    <tbody>
751
                                    [% SET selected = 0 %]
761
                                        [% SET selected = 0 %]
752
                                    [% FOREACH itemloo IN biblio.itemloop %]
762
                                        [% FOREACH itemloo IN biblio.itemloop %]
753
                                        [% UNLESS ( itemloo.hide ) %]
763
                                            [% UNLESS ( itemloo.hide ) %]
754
                                            <tr class="[% itemloo.backgroundcolor | html %]">
764
                                                <tr class="[% itemloo.backgroundcolor | html %]">
755
                                                <td>
765
                                                    <td>
756
                                                    [% IF force_hold_level == 'record' # Patron has placed a record level hold previously for this record %]
766
                                                        [% IF force_hold_level == 'record' # Patron has placed a record level hold previously for this record %]
757
                                                        <span class="error">
767
                                                            <span class="error">
758
                                                            <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
768
                                                                <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
759
                                                            Hold must be record level
769
                                                                Hold must be record level
760
                                                        </span>
770
                                                            </span>
761
                                                    [% ELSIF force_hold_level == 'item_group' %]
771
                                                        [% ELSIF force_hold_level == 'item_group' %]
762
                                                        <span class="error">
772
                                                            <span class="error">
763
                                                            <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
773
                                                                <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
764
                                                            Hold must be item group level
774
                                                                Hold must be item group level
765
                                                        </span>
775
                                                            </span>
766
                                                    [% ELSIF ( itemloo.available ) %]
776
                                                        [% ELSIF ( itemloo.available ) %]
767
                                                        <input type="radio" name="checkitem" class="requestspecific" value="[% itemloo.itemnumber | html %]" />
777
                                                            <input type="radio" name="checkitem" class="requestspecific" value="[% itemloo.itemnumber | html %]" />
768
                                                    [% ELSIF ( itemloo.override ) %]
778
                                                        [% ELSIF ( itemloo.override ) %]
769
                                                        <input type="radio" name="checkitem" class="needsoverride requestspecific" value="[% itemloo.itemnumber | html %]" />
779
                                                            <input type="radio" name="checkitem" class="needsoverride requestspecific" value="[% itemloo.itemnumber | html %]" />
770
                                                        <i class="fa fa-exclamation-triangle fa-lg" style="color:gold" title="Requires override of hold policy"/></i>
780
                                                            <i class="fa fa-exclamation-triangle fa-lg" style="color:gold" title="Requires override of hold policy"/></i>
771
                                                    [% ELSE %]
781
                                                        [% ELSE %]
772
                                                        <span class="error">
782
                                                            <span class="error">
773
                                                            <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
783
                                                                <i class="fa fa-times fa-lg" title="Cannot be put on hold"></i>
774
                                                            [% IF itemloo.not_holdable %]
784
                                                                [% IF itemloo.not_holdable %]
775
                                                                [% IF itemloo.not_holdable == 'damaged' %]
785
                                                                    [% IF itemloo.not_holdable == 'damaged' %]
776
                                                                    <span>Item damaged</span>
786
                                                                        <span>Item damaged</span>
777
                                                                [% ELSIF itemloo.not_holdable == 'ageRestricted' %]
787
                                                                    [% ELSIF itemloo.not_holdable == 'ageRestricted' %]
778
                                                                    <span>Age restricted</span>
788
                                                                        <span>Age restricted</span>
779
                                                                [% ELSIF itemloo.not_holdable == 'tooManyHoldsForThisRecord' %]
789
                                                                    [% ELSIF itemloo.not_holdable == 'tooManyHoldsForThisRecord' %]
780
                                                                    <span>Exceeded max holds per record</span>
790
                                                                        <span>Exceeded max holds per record</span>
781
                                                                [% ELSIF itemloo.not_holdable == 'tooManyReservesToday' %]
791
                                                                    [% ELSIF itemloo.not_holdable == 'tooManyReservesToday' %]
782
                                                                    <span>Daily hold limit reached for patron</span>
792
                                                                        <span>Daily hold limit reached for patron</span>
783
                                                                [% ELSIF itemloo.not_holdable == 'tooManyReserves' %]
793
                                                                    [% ELSIF itemloo.not_holdable == 'tooManyReserves' %]
784
                                                                    <span>Too many holds</span>
794
                                                                        <span>Too many holds</span>
785
                                                                [% ELSIF itemloo.not_holdable == 'notReservable' %]
795
                                                                    [% ELSIF itemloo.not_holdable == 'notReservable' %]
786
                                                                    <span>Not holdable</span>
796
                                                                        <span>Not holdable</span>
787
                                                                [% ELSIF itemloo.not_holdable == 'cannotReserveFromOtherBranches' %]
797
                                                                    [% ELSIF itemloo.not_holdable == 'cannotReserveFromOtherBranches' %]
788
                                                                    <span>Patron is from different library</span>
798
                                                                        <span>Patron is from different library</span>
789
                                                                [% ELSIF itemloo.not_holdable == 'branchNotInHoldGroup' %]
799
                                                                    [% ELSIF itemloo.not_holdable == 'branchNotInHoldGroup' %]
790
                                                                    <span>Cannot place hold from patron's library</span>
800
                                                                        <span>Cannot place hold from patron's library</span>
791
                                                                [% ELSIF itemloo.not_holdable == 'itemAlreadyOnHold' %]
801
                                                                    [% ELSIF itemloo.not_holdable == 'itemAlreadyOnHold' %]
792
                                                                    <span>Patron already has hold for this item</span>
802
                                                                        <span>Patron already has hold for this item</span>
793
                                                                [% ELSIF itemloo.not_holdable == 'cannotBeTransferred' %]
803
                                                                    [% ELSIF itemloo.not_holdable == 'cannotBeTransferred' %]
794
                                                                    <span>Cannot be transferred to pickup library</span>
804
                                                                        <span>Cannot be transferred to pickup library</span>
795
                                                                [% ELSIF itemloo.not_holdable == 'pickupNotInHoldGroup' %]
805
                                                                    [% ELSIF itemloo.not_holdable == 'pickupNotInHoldGroup' %]
796
                                                                    <span>Only pickup locations within the same hold group are allowed</span>
806
                                                                        <span>Only pickup locations within the same hold group are allowed</span>
797
                                                                [% ELSIF itemloo.not_holdable == 'noReservesAllowed' %]
807
                                                                    [% ELSIF itemloo.not_holdable == 'noReservesAllowed' %]
798
                                                                    <span>No holds are allowed on this item</span>
808
                                                                        <span>No holds are allowed on this item</span>
799
                                                                [% ELSIF itemloo.not_holdable == 'libraryNotPickupLocation' %]
809
                                                                    [% ELSIF itemloo.not_holdable == 'libraryNotPickupLocation' %]
800
                                                                    <span>Library is not a pickup location</span>
810
                                                                        <span>Library is not a pickup location</span>
801
                                                                [% ELSIF itemloo.not_holdable == 'no_valid_pickup_location' %]
811
                                                                    [% ELSIF itemloo.not_holdable == 'no_valid_pickup_location' %]
802
                                                                    <span>No valid pickup location</span>
812
                                                                        <span>No valid pickup location</span>
803
                                                                [% ELSIF itemloo.not_holdable == 'notforloan' %]
813
                                                                    [% ELSIF itemloo.not_holdable == 'notforloan' %]
804
                                                                    <span>Not for loan</span>
814
                                                                        <span>Not for loan</span>
805
                                                                [% ELSE %]
815
                                                                    [% ELSE %]
806
                                                                    <span>[% itemloo.not_holdable | html %]</span>
816
                                                                        <span>[% itemloo.not_holdable | html %]</span>
817
                                                                    [% END %]
807
                                                                [% END %]
818
                                                                [% END %]
819
                                                            </span>
820
                                                        [% END # /IF force_hold_level %]
821
                                                    </td>
822
                                                    <td>
823
                                                    [% IF (itemloo.pickup_locations_count > 0) || itemloo.override %]
824
                                                        <select name="item_pickup_[% itemloo.itemnumber | html %]" class="pickup_locations requestspecific" style="width:100%;"
825
                                                                data-item-id="[% itemloo.itemnumber | html %]"
826
                                                                data-patron-id="[% patron.borrowernumber | html %]"
827
                                                                data-pickup-location-source="item">
828
                                                        [% IF (itemloo.default_pickup_location) %]
829
                                                            <option value="[% itemloo.default_pickup_location.branchcode | html %]" selected="selected">[% itemloo.default_pickup_location.branchname | html %]</option>
830
                                                        [% END %]
831
                                                        </select>
832
                                                    [% END %]
833
                                                    </td>
834
                                                    [% IF Koha.Preference('item-level_itypes') %]
835
                                                        <td>
836
                                                            [% UNLESS ( noItemTypeImages ) %]
837
                                                                [% IF ( itemloo.itemtype.image_location) %]<img src="[% itemloo.itemtype.image_location | html %]" alt="" /> <br /> [% END %]
808
                                                            [% END %]
838
                                                            [% END %]
809
                                                        </span>
839
                                                            <span class="itypetext">[% itemloo.itemtype.translated_description | html %]</span>
810
                                                    [% END # /IF force_hold_level %]
840
                                                        </td>
811
                                                </td>
812
                                                <td>
813
                                                [% IF (itemloo.pickup_locations_count > 0) || itemloo.override %]
814
                                                    <select name="item_pickup_[% itemloo.itemnumber | html %]" class="pickup_locations requestspecific" style="width:100%;"
815
                                                            data-item-id="[% itemloo.itemnumber | html %]"
816
                                                            data-patron-id="[% patron.borrowernumber | html %]"
817
                                                            data-pickup-location-source="item">
818
                                                    [% IF (itemloo.default_pickup_location) %]
819
                                                        <option value="[% itemloo.default_pickup_location.branchcode | html %]" selected="selected">[% itemloo.default_pickup_location.branchname | html %]</option>
820
                                                    [% END %]
841
                                                    [% END %]
821
                                                    </select>
822
                                                [% END %]
823
                                                </td>
824
                                                [% IF Koha.Preference('item-level_itypes') %]
825
                                                    <td>
842
                                                    <td>
826
                                                        [% UNLESS ( noItemTypeImages ) %]
843
                                                        [% itemloo.barcode | html %]
827
                                                            [% IF ( itemloo.itemtype.image_location) %]<img src="[% itemloo.itemtype.image_location | html %]" alt="" /> <br /> [% END %]
828
                                                        [% END %]
829
                                                        <span class="itypetext">[% itemloo.itemtype.translated_description | html %]</span>
830
                                                    </td>
844
                                                    </td>
831
                                                [% END %]
845
                                                    [% IF Koha.Preference('EnableItemGroupHolds') && biblio.object.item_groups.count %]
832
                                                <td>
846
                                                        <td>
833
                                                    [% itemloo.barcode | html %]
847
                                                            [% itemloo.object.item_group.description | html %]
834
                                                </td>
848
                                                        </td>
835
                                                [% IF Koha.Preference('EnableItemGroupHolds') && biblio.object.item_groups.count %]
849
                                                    [% END %]
836
                                                    <td>
850
                                                    <td>
837
                                                        [% itemloo.object.item_group.description | html %]
851
                                                        [% Branches.GetName( itemloo.homebranch ) | html %]
838
                                                    </td>
852
                                                    </td>
839
                                                [% END %]
840
                                                <td>
841
                                                    [% Branches.GetName( itemloo.homebranch ) | html %]
842
                                                </td>
843
                                                <td>
844
                                                    [% Branches.GetName( itemloo.holdingbranch ) | html %]
845
                                                </td>
846
                                                [% IF itemdata_ccode %]
847
                                                    <td>
853
                                                    <td>
848
                                                        [% IF ( itemloo.ccode ) %][% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => itemloo.ccode ) | html %][% END %]
854
                                                        [% Branches.GetName( itemloo.holdingbranch ) | html %]
849
                                                    </td>
855
                                                    </td>
850
                                                [% END %]
856
                                                    [% IF itemdata_ccode %]
851
                                                <td>
857
                                                        <td>
852
                                                    [% itemloo.itemcallnumber | html %]
858
                                                            [% IF ( itemloo.ccode ) %][% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.ccode', authorised_value => itemloo.ccode ) | html %][% END %]
853
                                                </td>
859
                                                        </td>
854
                                                <td>
860
                                                    [% END %]
855
                                                    [% IF ( itemloo.copynumber ) %][% itemloo.copynumber | html %][% ELSE %]&nbsp;[% END %]
856
                                                </td>
857
                                                [% IF itemdata_enumchron %]
858
                                                    <td>
861
                                                    <td>
859
                                                        [% itemloo.enumchron | html %]
862
                                                        [% itemloo.itemcallnumber | html %]
860
                                                    </td>
863
                                                    </td>
861
                                                [% END %]
862
                                                [% IF ( itemloo.onloan ) %]
863
                                                    <td data-order="[% itemloo.date_due | html %]">
864
                                                        <span class="checkedout">Due [% itemloo.date_due | $KohaDates as_due_date => 1 %]</span>
865
                                                [% ELSE %]
866
                                                    <td>
864
                                                    <td>
867
                                                        [% IF ( itemloo.transfertwhen ) %]
865
                                                        [% IF ( itemloo.copynumber ) %][% itemloo.copynumber | html %][% ELSE %]&nbsp;[% END %]
868
                                                            <span>In transit from [% Branches.GetName( itemloo.transfertfrom ) | html %],
866
                                                    </td>
869
                                                            to [% Branches.GetName( itemloo.transfertto ) | html %], since [% itemloo.transfertwhen | $KohaDates %]</span>
867
                                                    [% IF itemdata_enumchron %]
870
                                                        [% END %]
868
                                                        <td>
871
                                                [% END %]
869
                                                            [% itemloo.enumchron | html %]
870
                                                        </td>
871
                                                    [% END %]
872
                                                    [% IF ( itemloo.onloan ) %]
873
                                                        <td data-order="[% itemloo.date_due | html %]">
874
                                                            <span class="checkedout">Due [% itemloo.date_due | $KohaDates as_due_date => 1 %]</span>
875
                                                    [% ELSE %]
876
                                                        <td>
877
                                                            [% IF ( itemloo.transfertwhen ) %]
878
                                                                <span>In transit from [% Branches.GetName( itemloo.transfertfrom ) | html %],
879
                                                                to [% Branches.GetName( itemloo.transfertto ) | html %], since [% itemloo.transfertwhen | $KohaDates %]</span>
880
                                                            [% END %]
881
                                                    [% END %]
872
882
873
                                                    [% IF ( itemloo.reservedate ) %]
883
                                                        [% IF ( itemloo.reservedate ) %]
874
                                                        [% IF ( itemloo.nocancel ) %]
884
                                                            [% IF ( itemloo.nocancel ) %]
875
                                                                <span>Can't be cancelled when item is in transit</span>
885
                                                                    <span>Can't be cancelled when item is in transit</span>
876
                                                        [% ELSE %]
877
                                                            [% IF ( itemloo.waitingdate ) %]
878
                                                                [% IF ( itemloo.canreservefromotherbranches ) %]
879
                                                                    <span>Waiting for [% INCLUDE 'patron-title.inc' patron=itemloo.ReservedFor %] at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since [% itemloo.waitingdate | $KohaDates %]</span>
880
                                                                [% ELSE %]
881
                                                                    <span>Waiting at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since [% itemloo.waitingdate | $KohaDates %]</span>
882
                                                                [% END %]
883
                                                            [% ELSE %]
886
                                                            [% ELSE %]
884
                                                                [% IF ( itemloo.canreservefromotherbranches ) %]
887
                                                                [% IF ( itemloo.waitingdate ) %]
885
                                                                    [% IF itemloo.reservedate %]
888
                                                                    [% IF ( itemloo.canreservefromotherbranches ) %]
886
                                                                        <span>On hold for [% INCLUDE 'patron-title.inc' patron=itemloo.ReservedFor %] expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since</span>
889
                                                                        <span>Waiting for [% INCLUDE 'patron-title.inc' patron=itemloo.ReservedFor %] at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since [% itemloo.waitingdate | $KohaDates %]</span>
887
                                                                    [% ELSE %]
890
                                                                    [% ELSE %]
888
                                                                        <span>On hold expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %]</span>
891
                                                                        <span>Waiting at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since [% itemloo.waitingdate | $KohaDates %]</span>
889
                                                                    [% END %]
892
                                                                    [% END %]
890
                                                                [% ELSIF itemloo.reservedate %]
891
                                                                    <span>On hold expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since [% itemloo.reservedate | $KohaDates %]</span>
892
                                                                [% ELSE %]
893
                                                                [% ELSE %]
893
                                                                    <span>On hold expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %]</span>
894
                                                                    [% IF ( itemloo.canreservefromotherbranches ) %]
895
                                                                        [% IF itemloo.reservedate %]
896
                                                                            <span>On hold for [% INCLUDE 'patron-title.inc' patron=itemloo.ReservedFor %] expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since</span>
897
                                                                        [% ELSE %]
898
                                                                            <span>On hold expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %]</span>
899
                                                                        [% END %]
900
                                                                    [% ELSIF itemloo.reservedate %]
901
                                                                        <span>On hold expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %] since [% itemloo.reservedate | $KohaDates %]</span>
902
                                                                    [% ELSE %]
903
                                                                        <span>On hold expected at [% Branches.GetName( itemloo.ExpectedAtLibrary ) | html %]</span>
904
                                                                    [% END %]
894
                                                                [% END %]
905
                                                                [% END %]
895
                                                            [% END %]
906
                                                                <a class="info cancel-hold" href="modrequest.pl?CancelBiblioNumber=[% itemloo.biblionumber | html %]&amp;CancelBorrowerNumber=[% itemloo.ReservedFor.borrowernumber | html %]&amp;CancelItemnumber=[% itemloo.itemnumber | html %]">Cancel hold</a>
896
                                                            <a class="info cancel-hold" href="modrequest.pl?CancelBiblioNumber=[% itemloo.biblionumber | html %]&amp;CancelBorrowerNumber=[% itemloo.ReservedFor.borrowernumber | html %]&amp;CancelItemnumber=[% itemloo.itemnumber | html %]">Cancel hold</a>
907
                                                            [% END # /IF itemloo.nocancel %]
897
                                                        [% END # /IF itemloo.nocancel %]
908
                                                        [% ELSE %]
898
                                                    [% ELSE %]
909
                                                            Not on hold
899
                                                        Not on hold
910
                                                        [% END # /IF itemloo.reservedate %]
900
                                                    [% END # /IF itemloo.reservedate %]
901
911
902
                                                    [% IF itemloo.item_level_holds == "N" %]
912
                                                        [% IF itemloo.item_level_holds == "N" %]
903
                                                        <br/>Item level hold not allowed from OPAC
913
                                                            <br/>Item level hold not allowed from OPAC
904
                                                    [% ELSIF itemloo.item_level_holds == "F" %]
914
                                                        [% ELSIF itemloo.item_level_holds == "F" %]
905
                                                        <br/>Item level hold forced from OPAC
915
                                                            <br/>Item level hold forced from OPAC
906
                                                    [% END %]
916
                                                        [% END %]
907
917
908
                                                    [% IF ( itemloo.itemlost ) %]
918
                                                        [% IF ( itemloo.itemlost ) %]
909
                                                       <span class="lost">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.itemlost', authorised_value => itemloo.itemlost ) | html %]</span>
919
                                                           <span class="lost">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.itemlost', authorised_value => itemloo.itemlost ) | html %]</span>
910
                                                    [% END %]
920
                                                        [% END %]
911
921
912
                                                    [% IF ( itemloo.damaged ) %]
922
                                                        [% IF ( itemloo.damaged ) %]
913
                                                        <span class="dmg">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.damaged', authorised_value => itemloo.damaged ) | html %]</span>
923
                                                            <span class="dmg">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.damaged', authorised_value => itemloo.damaged ) | html %]</span>
914
                                                    [% END %]
924
                                                        [% END %]
915
925
916
                                                    [% IF ( itemloo.withdrawn ) %]
926
                                                        [% IF ( itemloo.withdrawn ) %]
917
                                                       <span class="wdn">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => itemloo.withdrawn ) | html %]</span>
927
                                                           <span class="wdn">[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => itemloo.withdrawn ) | html %]</span>
918
                                                    [% END %]
928
                                                        [% END %]
919
929
920
                                                    [% IF ( itemloo.notforloan ) %]
930
                                                        [% IF ( itemloo.notforloan ) %]
921
                                                       <span class="nfl">Not for loan ([% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.notforloan', authorised_value => itemloo.notforloan ) | html %])</span>
931
                                                           <span class="nfl">Not for loan ([% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.notforloan', authorised_value => itemloo.notforloan ) | html %])</span>
922
                                                    [% ELSIF ( itemloo.notforloanitype ) %]
932
                                                        [% ELSIF ( itemloo.notforloanitype ) %]
923
                                                       <span class="nfl">Not for loan (Itemtype not for loan)</span>
933
                                                           <span class="nfl">Not for loan (Itemtype not for loan)</span>
924
                                                    [% END %]
934
                                                        [% END %]
925
                                                </td>
935
                                                    </td>
926
                                            </tr>
936
                                                </tr>
927
                                        [% END # / UNLESS itemloo.hide %]
937
                                            [% END # / UNLESS itemloo.hide %]
928
                                    [% END # /FOREACH itemloo %]
938
                                        [% END # /FOREACH itemloo %]
929
                                </tbody>
939
                                    </tbody>
930
                            </table> <!-- /#requestspecific -->
940
                                </table> <!-- /#requestspecific -->
931
941
932
                            [% IF hiddencount %]
942
                                [% IF hiddencount %]
933
                                <p class="hiddencount">
943
                                    <p class="hiddencount">
934
                                    <a href="request.pl?biblionumber=[% biblio.biblionumber | uri %]&amp;borrowernumber=[% borrowernumber | uri %]&amp;showallitems=1">Show all items ([% hiddencount | html %] hidden)</a>
944
                                        <a href="request.pl?biblionumber=[% biblio.biblionumber | uri %]&amp;borrowernumber=[% borrowernumber | uri %]&amp;showallitems=1">Show all items ([% hiddencount | html %] hidden)</a>
935
                                </p>
945
                                    </p>
936
                            [% END # /IF hiddencount %]
946
                                [% END # /IF hiddencount %]
947
                                <fieldset class="action">
948
                                    [% IF ( override_required ) %]
949
                                        <button type="submit" id="hold_item_btn" class="btn btn-primary warning"><i class="fa fa-exclamation-triangle "></i> Place hold</button>
950
                                    [% ELSIF ( none_available ) %]
951
                                        <button type="submit" id="hold_item_btn" class="btn btn-primary btn-disabled" disabled="disabled">Place hold</button>
952
                                    [% ELSE %]
953
                                        <button type="submit" id="hold_item_btn" class="btn btn-primary">Place hold</button>
954
                                    [% END %]
955
                                </fieldset> <!-- /.action -->
956
                            </fieldset>
957
                        </fieldset class="rows">
937
958
938
                        [% ELSE # /UNLESS multi_hold %]
959
                        [% ELSE # /UNLESS multi_hold %]
939
                            <fieldset class="rows">
960
                            <fieldset class="rows">
Lines 1042-1073 Link Here
1042
                                    [% END # /FOREACH biblioloo %]
1063
                                    [% END # /FOREACH biblioloo %]
1043
                                </table> <!-- /#requesttitles -->
1064
                                </table> <!-- /#requesttitles -->
1044
                            </fieldset>
1065
                            </fieldset>
1066
                            <fieldset class="action">
1067
                                [% IF ( patron AND patron.borrowernumber ) %]
1068
                                        [% IF ( override_required ) %]
1069
                                            <button type="submit" id="hold_multi_btn" class="btn btn-primary warning"><i class="fa fa-exclamation-triangle "></i> Place holds</button>
1070
                                        [% ELSIF ( no_bibs_available ) %]
1071
                                            <button type="submit" id="hold_multi_btn" class="btn btn-primary btn-disabled" disabled="disabled">Place holds</button>
1072
                                        [% ELSIF ( none_available ) %]
1073
                                            <button type="submit" id="hold_multi_btn" class="btn btn-primary">Place holds</button>
1074
                                        [% ELSE %]
1075
                                            <button type="submit" id="hold_multi_btn" class="btn btn-primary" id="multi_hold_submit">Place holds</button>
1076
                                        [% END %]
1077
                                [% END # /IF patron %]
1078
                            </fieldset> <!-- /.action -->
1045
1079
1046
                        [% END # /UNLESS multi_hold %]
1080
                        [% END # /UNLESS multi_hold %]
1047
1081
1048
                        <fieldset class="action">
1049
                            [% IF ( patron AND patron.borrowernumber ) %]
1050
                                [% IF ( multi_hold ) %]
1051
                                    [% IF ( override_required ) %]
1052
                                        <button type="submit" id="hold_multi_btn" class="btn btn-primary warning"><i class="fa fa-exclamation-triangle "></i> Place holds</button>
1053
                                    [% ELSIF ( no_bibs_available ) %]
1054
                                        <button type="submit" id="hold_multi_btn" class="btn btn-primary btn-disabled" disabled="disabled">Place holds</button>
1055
                                    [% ELSIF ( none_available ) %]
1056
                                        <button type="submit" id="hold_multi_btn" class="btn btn-primary">Place holds</button>
1057
                                    [% ELSE %]
1058
                                        <button type="submit" id="hold_multi_btn" class="btn btn-primary" id="multi_hold_submit">Place holds</button>
1059
                                    [% END %]
1060
                                [% ELSE %]
1061
                                    [% IF ( override_required ) %]
1062
                                        <button type="submit" id="hold_item_btn" class="btn btn-primary warning"><i class="fa fa-exclamation-triangle "></i> Place hold</button>
1063
                                    [% ELSIF ( none_available ) %]
1064
                                        <button type="submit" id="hold_item_btn" class="btn btn-primary btn-disabled" disabled="disabled">Place hold</button>
1065
                                    [% ELSE %]
1066
                                        <button type="submit" id="hold_item_btn" class="btn btn-primary">Place hold</button>
1067
                                    [% END %]
1068
                                [% END %]
1069
                            [% END # /IF patron %]
1070
                        </fieldset> <!-- /.action -->
1071
                    </fieldset> <!-- /.rows -->
1082
                    </fieldset> <!-- /.rows -->
1072
                </form> <!-- /#hold-request-form -->
1083
                </form> <!-- /#hold-request-form -->
1073
            [% END %]
1084
            [% END %]
Lines 1510-1531 Link Here
1510
1521
1511
        function ToggleHoldsToPlace() {
1522
        function ToggleHoldsToPlace() {
1512
            if ( $("#requestany").prop('checked') ) {
1523
            if ( $("#requestany").prop('checked') ) {
1513
                $("#holds_to_place_count, #pickup-next-avail, #itemtype, #hold_any_btn").prop('disabled', false);
1524
                $(".disable_request_any").prop('disabled',true);
1525
                $(".enable_request_any").prop('disabled',false);
1514
                $(".requestspecific,.requestgrp").prop('checked', false);
1526
                $(".requestspecific,.requestgrp").prop('checked', false);
1515
                $(".requestspecific","#requestspecific").prop('disabled',true);
1516
                $("#hold_item_btn, #hold_grp_btn, #pickup-item-group").prop("disabled", true );
1517
                $("#hold_any_btn").prop("disabled", false );
1518
            } else if( $(".requestspecific").prop('checked') ) {
1527
            } else if( $(".requestspecific").prop('checked') ) {
1519
                $(".requestspecific","#requestspecific").prop('disabled',false);
1528
                $(".disable_request_specific").prop('disabled',true);
1520
                $("#holds_to_place_count, #pickup-item-group, #pickup-next-avail #itemtype, #hold_any_btn").prop('disabled', true);
1529
                $(".enable_request_specific").prop('disabled',false);
1521
                $("#hold_item_btn").prop("disabled", false );
1522
                $("#hold_any_btn,#hold_grp_btn").prop("disabled", true );
1523
                $("#requestany,.requestgrp").prop('checked', false);
1530
                $("#requestany,.requestgrp").prop('checked', false);
1524
            } else {
1531
            } else {
1525
                $("#holds_to_place_count, #pickup-next-avail, #itemtype, #hold_any_btn").prop('disabled', true);
1532
                $(".disable_request_group").prop('disabled',true);
1526
                $("#hold_grp_btn, #pickup-item-group").prop("disabled", false );
1533
                $(".enable_request_group").prop('disabled',false);
1527
                $(".requestspecific","#requestspecific").prop('disabled',true);
1528
                $("#hold_any_btn,#hold_item_btn").prop("disabled", true );
1529
                $("#requestany,.requestspecific").prop('checked', false);
1534
                $("#requestany,.requestspecific").prop('checked', false);
1530
            }
1535
            }
1531
        }
1536
        }
1532
- 

Return to bug 30579