Line 0
Link Here
|
0 |
- |
1 |
$DBversion = 'XXX'; # will be replaced by the RM |
|
|
2 |
if( CheckVersion( $DBversion ) ) { |
3 |
|
4 |
for my $f ( qw( categorycode dateexpiry ) ) { |
5 |
my ( $exists ) = $dbh->selectrow_array(qq{ |
6 |
SELECT value from systempreferences |
7 |
WHERE variable="PatronSelfRegistrationBorrowerUnwantedField" |
8 |
AND value LIKE "%$f%" |
9 |
}); |
10 |
unless ( $exists ) { |
11 |
$dbh->do(q{ |
12 |
UPDATE systempreferences |
13 |
SET value = CONCAT(value, IF(value<>'','|',''), ?) |
14 |
WHERE variable="PatronSelfRegistrationBorrowerUnwantedField" |
15 |
}, undef, $f); |
16 |
} |
17 |
} |
18 |
|
19 |
NewVersion( $DBversion, 27634, "Add categorycode and dateexpiry to PatronSelfRegistrationBorrowerUnwantedField"); |
20 |
} |