@@ -, +, @@
---
installer/data/mysql/sysprefs.sql | 1 +
installer/data/mysql/updatedatabase.pl | 6 ++++
.../en/modules/admin/preferences/circulation.pref | 7 ++++-
.../prog/en/modules/reserve/request.tt | 25 ++++++++++---------
opac/opac-reserve.pl | 25 +++++++++++--------
5 files changed, 40 insertions(+), 24 deletions(-)
--- a/installer/data/mysql/sysprefs.sql
+++ a/installer/data/mysql/sysprefs.sql
@@ -411,3 +411,4 @@ INSERT INTO systempreferences (variable,value,options,explanation,type) VALUES (
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES('IDreamBooksReviews','0','Display book review snippets from IDreamBooks.com','','YesNo');
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES('IDreamBooksReadometer','0','Display Readometer from IDreamBooks.com','','YesNo');
INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES('IDreamBooksResults','0','Display IDreamBooks.com rating in search results','','YesNo');
+INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES('MaxHoldsPerRecord', '1', 'The maximum number of holds allowed per bibliographic record per borrower', NULL, NULL);
--- a/installer/data/mysql/updatedatabase.pl
+++ a/installer/data/mysql/updatedatabase.pl
@@ -6399,6 +6399,12 @@ if ( CheckVersion($DBversion) ) {
SetVersion($DBversion);
}
+$DBversion = "3.11.00.XXX";
+if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
+ $dbh->do("INSERT IGNORE INTO systempreferences (variable,value,explanation,options,type) VALUES ('MaxHoldsPerRecord', '1', 'The maximum number of holds allowed per bibliographic record per borrower', NULL, NULL)");
+ print "Upgrade to $DBversion done (Add syspref MaxHoldsPerRecord)\n";
+ SetVersion ($DBversion);
+}
=head1 FUNCTIONS
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref
@@ -404,7 +404,12 @@ Circulation:
- Patrons can only have
- pref: maxreserves
class: integer
- - holds at once.
+ - total holds at a time.
+ -
+ - Patrons can only place
+ - pref: MaxHoldsPerRecord
+ class: integer
+ - holds on a single record at a time.
-
- pref: emailLibrarianWhenHoldIsPlaced
choices:
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt
@@ -55,7 +55,7 @@ function check() {
}
if (alreadyreserved > "0"){
- msg += (_("- This patron had already placed a hold on this item") + "\n" + _("Please cancel the previous hold first") + "\n");
+ msg += (_("This patron has already placed the maximum number of holds for this record") + "\n" + _("Please cancel a previous hold first") + "\n");
}
if (msg == "") return(true);
@@ -208,7 +208,7 @@ function checkMultiHold() {