Bugzilla – Attachment 100744 Details for
Bug 21443
Add ability to exclude holidays when calculating rentals fees by time period
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21443: Update database
Bug-21443-Update-database.patch (text/plain), 2.91 KB, created by
Kyle M Hall (khall)
on 2020-03-16 12:57:29 UTC
(
hide
)
Description:
Bug 21443: Update database
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2020-03-16 12:57:29 UTC
Size:
2.91 KB
patch
obsolete
>From 263e5b110d4e493acff2bc63286089281f4f49a0 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Mon, 9 Mar 2020 13:11:55 -0400 >Subject: [PATCH] Bug 21443: Update database > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> > >Signed-off-by: Marti Fuerst <mfuerst@hmcpl.org> >--- > .../data/mysql/atomicupdate/bug_21443.perl | 22 +++++++++++++++++++ > installer/data/mysql/kohastructure.sql | 2 ++ > 2 files changed, 24 insertions(+) > create mode 100644 installer/data/mysql/atomicupdate/bug_21443.perl > >diff --git a/installer/data/mysql/atomicupdate/bug_21443.perl b/installer/data/mysql/atomicupdate/bug_21443.perl >new file mode 100644 >index 0000000000..74cf57f650 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_21443.perl >@@ -0,0 +1,22 @@ >+$DBversion = 'XXX'; # will be replaced by the RM >+if( CheckVersion( $DBversion ) ) { >+ if( !column_exists( 'itemtypes', 'rentalcharge_daily_calendar' ) ) { >+ $dbh->do(q{ >+ ALTER TABLE itemtypes ADD COLUMN >+ rentalcharge_daily_calendar tinyint(1) NOT NULL DEFAULT 1 >+ AFTER rentalcharge_daily; >+ }); >+ } >+ >+ if( !column_exists( 'itemtypes', 'rentalcharge_hourly_calendar' ) ) { >+ $dbh->do(q{ >+ ALTER TABLE itemtypes ADD COLUMN >+ rentalcharge_hourly_calendar tinyint(1) NOT NULL DEFAULT 1 >+ AFTER rentalcharge_hourly; >+ }); >+ } >+ >+ # Always end with this (adjust the bug info) >+ SetVersion( $DBversion ); >+ print "Upgrade to $DBversion done (Bug 21443: Add ability to exclude holidays when calculating rentals fees by time period)\n"; >+} >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index 0f092725b5..b97af9517f 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -878,7 +878,9 @@ CREATE TABLE `itemtypes` ( -- defines the item types > description LONGTEXT, -- a plain text explanation of the item type > rentalcharge decimal(28,6) default NULL, -- the amount charged when this item is checked out/issued > rentalcharge_daily decimal(28,6) default NULL, -- the amount charged for each day between checkout date and due date >+ rentalcharge_daily_calendar tinyint(1) NOT NULL DEFAULT 1, -- controls if the daily retnal fee is calculated directly or using finesCalendar > rentalcharge_hourly decimal(28,6) default NULL, -- the amount charged for each hour between checkout date and due date >+ rentalcharge_hourly_calendar tinyint(1) NOT NULL DEFAULT 1, -- controls if the hourly retnal fee is calculated directly or using finesCalendar > defaultreplacecost decimal(28,6) default NULL, -- default replacement cost > processfee decimal(28,6) default NULL, -- default text be recorded in the column note when the processing fee is applied > notforloan smallint(6) default NULL, -- 1 if the item is not for loan, 0 if the item is available for loan >-- >2.21.1 (Apple Git-122.3)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 21443
:
100402
|
100403
|
100404
|
100405
|
100744
|
100745
|
100746
|
100747
|
100748
|
101428
|
101429
|
101430
|
101431
|
101458
|
101459
|
101460
|
101461
|
101462
|
101463
|
101464
|
101465
|
101466
|
101467
|
101468
|
101469
|
101631