<!ENTITY opac.holds.pickupLocation "Pickup location">
<!ENTITY opac.holds.success "Hold was successfully placed">
<!ENTITY opac.holds.failure "Hold was not successfully placed">
+<!ENTITY opac.hold.has_parts "The system was not able to place the requested hold. The item requested has multiple parts to choose from. Try selecting a specific part for the hold.">
<!-- =================================================================
Advanced
================================================================= -->
if(holdArgs.editHold) // flesh the args with the existing hold
holdArgsFromHold(holdArgs.editHold, holdArgs);
+ $('holds_parts_selector').style.border = 'auto';
+ holdArgs.partsSuggestionMade = false;
+
holdsDrawWindow();
}
var res = r.getResultObject();
if(checkILSEvent(res) || res.success != 1) {
if(res.success != 1) {
- alert($('hold_not_allowed').innerHTML);
+
+ if(!holdArgs.partsSuggestionMade && holdArgs.recordParts &&
+ holdArgs.recordParts.length && holdArgs.type == 'T') {
+ // T holds on records that have parts are OK, but if the record has no non-part
+ // copies, the hold will ultimately fail. Suggest selecting a part to the user.
+ $('holds_parts_selector').style.border = '2px solid red';
+ holdArgs.partsSuggestionMade = true;
+ alert($('hold_has_parts').innerHTML);
+ } else {
+ alert($('hold_not_allowed').innerHTML);
+ }
} else {
if( res.textcode == 'PATRON_BARRED' ) {
alertId('hold_failed_patron_barred');