Lines 168-173
Link Here
|
168 |
</div> |
168 |
</div> |
169 |
[% END %] |
169 |
[% END %] |
170 |
|
170 |
|
|
|
171 |
[% IF ( failed_holds ) %] |
172 |
<div class="dialog alert"> |
173 |
<strong>One or more holds were not placed due to following errors:</strong> |
174 |
<ul> |
175 |
[% FOREACH fail IN failed_holds %] |
176 |
<li> |
177 |
[% SWITCH fail %] |
178 |
[% CASE 'damaged' %] |
179 |
<span>Item is damaged</span> |
180 |
[% CASE 'ageRestricted' %] |
181 |
<span>The record and its items are age restricted</span> |
182 |
[% CASE 'tooManyHoldsForThisRecord' %] |
183 |
<span>Patron exceeded the number of concurrent holds for this record</span> |
184 |
[% CASE 'tooManyReservesToday' %] |
185 |
<span>Patron reached daily holds limit</span> |
186 |
[% CASE 'tooManyReserves' %] |
187 |
<span>Too many holds already</span> |
188 |
[% CASE 'notReservable' %] |
189 |
<span>Not holdable</span> |
190 |
[% CASE 'cannotReserveFromOtherBranches' %] |
191 |
<span>Patron from a different library</span> |
192 |
[% CASE 'branchNotInHoldGroup' %] |
193 |
<span>Holds are not allowed from patron's library</span> |
194 |
[% CASE 'itemAlreadyOnHold' %] |
195 |
<span>Patron already has a hold for failed item(s)</span> |
196 |
[% CASE 'cannotBeTransferred' %] |
197 |
<span>Cannot be transferred to pickup library</span> |
198 |
[% CASE 'pickupNotInHoldGroup' %] |
199 |
<span>The chosen pickup location is not allowed</span> |
200 |
[% CASE 'noReservesAllowed' %] |
201 |
<span>No holds are allowed on failed item(s)</span> |
202 |
[% CASE 'libraryNotPickupLocation' %] |
203 |
<span>Library is not a valid pickup location</span> |
204 |
[% CASE 'no_valid_pickup_location' %] |
205 |
<span>No valid pickup location</span> |
206 |
[% CASE 'notforloan' %] |
207 |
<span>Not for loan</span> |
208 |
[% CASE 'items_available' %] |
209 |
<span>There are items available in the library</span> |
210 |
[% CASE 'not_placed' %] |
211 |
<span>Error when placing hold</span> |
212 |
[% CASE %] |
213 |
<span>Error: [% fail | html %]</span> |
214 |
[% END %] |
215 |
</li> |
216 |
[% END %] |
217 |
</ul> |
218 |
</div> |
219 |
[% END %] |
220 |
|
171 |
[% IF ( messagetransfert ) %] |
221 |
[% IF ( messagetransfert ) %] |
172 |
<div class="dialog message"> |
222 |
<div class="dialog message"> |
173 |
<h2>Hold found for ([% nextreservtitle | html %]), please transfer</h2> |
223 |
<h2>Hold found for ([% nextreservtitle | html %]), please transfer</h2> |
Lines 745-753
Link Here
|
745 |
Hold must be item group level |
795 |
Hold must be item group level |
746 |
</span> |
796 |
</span> |
747 |
[% ELSIF ( itemloo.available ) %] |
797 |
[% ELSIF ( itemloo.available ) %] |
748 |
<input type="radio" name="checkitem" value="[% itemloo.itemnumber | html %]" /> |
798 |
<input type="checkbox" name="checkitem" value="[% itemloo.itemnumber | html %]" /> |
749 |
[% ELSIF ( itemloo.override ) %] |
799 |
[% ELSIF ( itemloo.override ) %] |
750 |
<input type="radio" name="checkitem" class="needsoverride" value="[% itemloo.itemnumber | html %]" /> |
800 |
<input type="checkbox" name="checkitem" class="needsoverride" value="[% itemloo.itemnumber | html %]" /> |
751 |
<i class="fa fa-exclamation-triangle fa-lg" style="color:gold" title="Requires override of hold policy"/></i> |
801 |
<i class="fa fa-exclamation-triangle fa-lg" style="color:gold" title="Requires override of hold policy"/></i> |
752 |
[% ELSE %] |
802 |
[% ELSE %] |
753 |
<span class="error"> |
803 |
<span class="error"> |
Lines 1502-1512
Link Here
|
1502 |
|
1552 |
|
1503 |
if ( ! $("#requestany").is(":checked") ) { |
1553 |
if ( ! $("#requestany").is(":checked") ) { |
1504 |
// requestany not selected, go through the item-specific cases |
1554 |
// requestany not selected, go through the item-specific cases |
1505 |
if ( $('input[type="radio"]:checked').length > 0 ) { |
1555 |
if ( $('input[name="checkitem"]:checked').length > 0 ) { |
1506 |
// got item-specific hold requests in the form! |
1556 |
// got item-specific hold requests in the form! |
1507 |
// verify they have a pickup location selected |
1557 |
// verify they have a pickup location selected |
1508 |
|
1558 |
|
1509 |
if (table.find('input[type="radio"]:checked') |
1559 |
if (table.find('input[name="checkitem"]:checked') |
1510 |
.closest('tr') |
1560 |
.closest('tr') |
1511 |
.find(".pickup_locations").val() === null) { |
1561 |
.find(".pickup_locations").val() === null) { |
1512 |
|
1562 |
|
Lines 1597-1611
Link Here
|
1597 |
} |
1647 |
} |
1598 |
}); |
1648 |
}); |
1599 |
$("input[name=checkitem]").click(function() { |
1649 |
$("input[name=checkitem]").click(function() { |
1600 |
onechecked = 0; |
1650 |
let onechecked = 0; |
1601 |
$("input[name=checkitem]").each(function() { |
1651 |
$("input[name=checkitem]").each(function() { |
1602 |
if(this.checked){ |
1652 |
if(this.checked){ |
1603 |
onechecked = 1; |
1653 |
onechecked++; |
1604 |
} |
1654 |
} |
1605 |
}); |
1655 |
}); |
1606 |
if(onechecked == 1){ |
1656 |
if(onechecked > 0){ |
1607 |
$("#requestany").prop("checked", false); |
1657 |
$("#requestany").prop("checked", false); |
1608 |
$("#holds_to_place_count").prop('disabled', true); |
1658 |
$("#holds_to_place_count").prop('disabled', true); |
|
|
1659 |
|
1660 |
$("#holds_to_place_count").val(onechecked); |
1609 |
} else { |
1661 |
} else { |
1610 |
$("#requestany").prop("checked",true); |
1662 |
$("#requestany").prop("checked",true); |
1611 |
$("#holds_to_place_count").prop('disabled', false); |
1663 |
$("#holds_to_place_count").prop('disabled', false); |
Lines 1683-1692
Link Here
|
1683 |
|
1735 |
|
1684 |
[% IF Koha.Preference('EnableItemGroupHolds') %] |
1736 |
[% IF Koha.Preference('EnableItemGroupHolds') %] |
1685 |
$(':radio[name="item_group_id"]').change(function(){ |
1737 |
$(':radio[name="item_group_id"]').change(function(){ |
1686 |
$(':radio[name="checkitem"]').prop('checked', false); |
1738 |
$('input[name="checkitem"]').prop('checked', false); |
1687 |
}); |
1739 |
}); |
1688 |
|
1740 |
|
1689 |
$(':radio[name="checkitem"]').change(function(){ |
1741 |
$('input[name="checkitem"]').change(function(){ |
1690 |
$(':radio[name="item_group_id"]').prop('checked', false); |
1742 |
$(':radio[name="item_group_id"]').prop('checked', false); |
1691 |
}); |
1743 |
}); |
1692 |
[% END %] |
1744 |
[% END %] |