From 5f8b4cb652fdf0b1ddaa4a4ee3d26f89a559f5a5 Mon Sep 17 00:00:00 2001 From: Fridolin Somers Date: Fri, 14 Aug 2015 11:00:13 +0200 Subject: [PATCH] Bug 14666 - add fixed_fines for overdues - Add a overduerules.fixed_fineX for the 3 levels - Add a column "Fixed fines" in the tools/overduerules.pl page --- installer/data/mysql/atomicupdate/BZ14666.sql | 3 +++ installer/data/mysql/kohastructure.sql | 3 +++ .../prog/en/modules/help/tools/overduerules.tt | 1 + .../prog/en/modules/tools/overduerules.tt | 4 ++++ tools/overduerules.pl | 24 ++++++++++++++-------- 5 files changed, 27 insertions(+), 8 deletions(-) create mode 100644 installer/data/mysql/atomicupdate/BZ14666.sql diff --git a/installer/data/mysql/atomicupdate/BZ14666.sql b/installer/data/mysql/atomicupdate/BZ14666.sql new file mode 100644 index 0000000..8d9f238 --- /dev/null +++ b/installer/data/mysql/atomicupdate/BZ14666.sql @@ -0,0 +1,3 @@ +ALTER TABLE overduerules ADD COLUMN fixed_fine1 float NOT NULL DEFAULT 0 after debarred1; +ALTER TABLE overduerules ADD COLUMN fixed_fine2 float NOT NULL DEFAULT 0 after debarred2; +ALTER TABLE overduerules ADD COLUMN fixed_fine3 float NOT NULL DEFAULT 0 after debarred3; \ No newline at end of file diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index d6732a3..977ebdf 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -1711,12 +1711,15 @@ CREATE TABLE `overduerules` ( -- overdue notice status and triggers `delay1` int(4) default NULL, -- number of days after the item is overdue that the first notice is sent `letter1` varchar(20) default NULL, -- foreign key from the letter table to define which notice should be sent as the first notice `debarred1` varchar(1) default 0, -- is the patron restricted when the first notice is sent (1 for yes, 0 for no) + `fixed_fine1` float NOT NULL default '0', -- fixed fine for the first notice `delay2` int(4) default NULL, -- number of days after the item is overdue that the second notice is sent `debarred2` varchar(1) default 0, -- is the patron restricted when the second notice is sent (1 for yes, 0 for no) + `fixed_fine2` float NOT NULL default '0', -- fixed fine for the second notice `letter2` varchar(20) default NULL, -- foreign key from the letter table to define which notice should be sent as the second notice `delay3` int(4) default NULL, -- number of days after the item is overdue that the third notice is sent `letter3` varchar(20) default NULL, -- foreign key from the letter table to define which notice should be sent as the third notice `debarred3` int(1) default 0, -- is the patron restricted when the third notice is sent (1 for yes, 0 for no) + `fixed_fine3` float NOT NULL default '0', -- fixed fine for the third notice PRIMARY KEY (`branchcode`,`categorycode`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/overduerules.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/overduerules.tt index b8eaa79..fcbf4dd 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/overduerules.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/overduerules.tt @@ -14,6 +14,7 @@
  • Important: If you want Koha to trigger an action (send a letter or restrict member), a delay value is required.
  • +
  • Fixed fine is an amount added to the total amount (which is a sum of item's prices)
  • To send additional notices, click on the tabs for 'Second' and 'Third' notice
  • If you would like to prevent a patron from checking items out because of their overdue items, check the 'Restrict' box, this will put a notice on the patron's record at checkout informing the librarian that the patron cannot check out due to overdue items.