5 description => "Allow patrons to change pickup location for non-waiting holds",
8 my ($dbh, $out) = @$args{qw(dbh out)};
11 INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type)
12 VALUES ('OPACAllowUserToChangeBranch','','Pending, In-Transit, Suspended','Allow users to change the library to pick up a hold for these statuses:','multiple');
15 say $out "Added new system preference 'OPACAllowUserToChangeBranch'";
17 my ($value) = $dbh->selectrow_array(q{
18 SELECT CASE WHEN value=1 THEN 'intransit' ELSE '' END
19 FROM systempreferences
20 WHERE variable='OPACInTransitHoldPickupLocationChange'
24 UPDATE systempreferences
26 WHERE variable='OPACAllowUserToChangeBranch'
30 DELETE FROM systempreferences
31 WHERE variable = 'OPACInTransitHoldPickupLocationChange'
34 say $out "Removed system preference 'OPACInTransitHoldPickupLocationChange'";