There was concern initially about whether a patrons own holds should be ignored, but that is not the case in scripted circ rules, so the behavior, as implemented by Dan, is correct.
git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_1_6@16021
dcc99617-32d9-48b4-a31d-
7c20da2025e4
my $events = [];
+ if ($U->ou_ancestor_setting_value($self->circ_lib, 'circ.block_renews_for_holds')) {
+ my ($hold, undef, $retarget) = $holdcode->find_nearest_permitted_hold(
+ $self->editor, $self->copy, $self->editor->requestor, 1 );
+ if ($hold) {
+ push(@$events, 'COPY_NEEDED_FOR_HOLD');
+ }
+ }
+
if(!$self->legacy_script_support) {
my $results = $self->run_indb_circ_test;
unless($self->circ_test_success) {
INSERT INTO permission.perm_list (code) VALUES ('UPDATE_ORG_UNIT_SETTING.cat.bib.keep_on_empty');
INSERT INTO permission.perm_list (code) VALUES ('UPDATE_ORG_UNIT_SETTING.cat.bib.alert_on_empty');
INSERT INTO permission.perm_list (code) VALUES ('UPDATE_ORG_UNIT_SETTING.patron.password.use_phone');
+INSERT INTO permission.perm_list (code) VALUES ('UPDATE_ORG_UNIT_SETTING.circ.block_renews_for_holds');
SELECT SETVAL('permission.perm_list_id_seq'::TEXT, 1000);
<!ENTITY staff.server.admin.org_settings.circ.reshelving_complete.interval.desc 'Amount of time to wait before changing an item from "reshelving" status to "available". Examples "1 day", "6 hours"'>
<!ENTITY staff.server.admin.org_settings.circ.hold_estimate_wait_interval "Holds: Estimated Wait (Days)">
<!ENTITY staff.server.admin.org_settings.circ.hold_estimate_wait_interval.desc "When predicting the amount of time a patron will be waiting for a hold to be fulfilled,this is the default/average number of days to assume an item will be checked out.">
+<!ENTITY staff.server.admin.org_settings.circ.block_renews_for_holds "Holds: Block Renewal on Items Needed for Holds">
+<!ENTITY staff.server.admin.org_settings.circ.block_renews_for_holds.desc "When an item could fulfill a hold, do not allow the current patron to renew">
<!ENTITY staff.server.admin.org_settings.circ.selfcheck.patron_login_timeout "Selfcheck: Patron Login Timeout (in seconds)">
<!ENTITY staff.server.admin.org_settings.circ.selfcheck.patron_login_timeout.desc "Number of seconds of inactivity before the patron is logged out of the selfcheck interface">
<!ENTITY staff.server.admin.org_settings.circ.selfcheck.alert_on_checkout_event "Selfcheck: Pop-up alert for errors">
desc : '&staff.server.admin.org_settings.circ.hold_estimate_wait_interval.desc;',
type : 'number'
},
+ 'circ.block_renews_for_holds' : {
+ label : '&staff.server.admin.org_settings.circ.block_renews_for_holds;',
+ desc : '&staff.server.admin.org_settings.circ.block_renews_for_holds.desc;',
+ type : 'bool'
+ },
'circ.selfcheck.patron_login_timeout' : {
label : '&staff.server.admin.org_settings.circ.selfcheck.patron_login_timeout;',
desc : '&staff.server.admin.org_settings.circ.selfcheck.patron_login_timeout.desc;',