Lines 21-33
return {
Link Here
|
21 |
); |
21 |
); |
22 |
say $out "Added new system preference 'UseLibraryFloatLimits'"; |
22 |
say $out "Added new system preference 'UseLibraryFloatLimits'"; |
23 |
|
23 |
|
24 |
unless ( TableExists('search_filters') ) { |
24 |
unless ( TableExists('library_float_limits') ) { |
25 |
$dbh->do( |
25 |
$dbh->do( |
26 |
q{ |
26 |
q{ |
27 |
CREATE TABLE `library_float_limits` ( |
27 |
CREATE TABLE `library_float_limits` ( |
28 |
`branchcode` varchar(10) NOT NULL, |
28 |
`branchcode` varchar(10) NOT NULL, |
29 |
`itemtype` varchar(10) NOT NULL, |
29 |
`itemtype` varchar(10) NOT NULL, |
30 |
`limit` int(11) NULL DEFAULT NULL, |
30 |
`float_limit` int(11) NULL DEFAULT NULL, |
31 |
PRIMARY KEY (`branchcode`,`itemtype`), |
31 |
PRIMARY KEY (`branchcode`,`itemtype`), |
32 |
CONSTRAINT `library_float_limits_ibfk_bc` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
32 |
CONSTRAINT `library_float_limits_ibfk_bc` FOREIGN KEY (`branchcode`) REFERENCES `branches` (`branchcode`) ON DELETE CASCADE ON UPDATE CASCADE, |
33 |
CONSTRAINT `library_float_limits_ibfk_it` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) ON DELETE CASCADE ON UPDATE CASCADE |
33 |
CONSTRAINT `library_float_limits_ibfk_it` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) ON DELETE CASCADE ON UPDATE CASCADE |