From ae6f5a347767135c3b707b638e5e496ae402752a Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 10 May 2019 14:44:47 +0000 Subject: [PATCH] Bug 22809: DBRev 18.12.00.072 Signed-off-by: Nick Clemens --- Koha.pm | 2 +- .../data/mysql/atomicupdate/bug_22809.perl | 61 ------------------ installer/data/mysql/updatedatabase.pl | 62 +++++++++++++++++++ 3 files changed, 63 insertions(+), 62 deletions(-) delete mode 100644 installer/data/mysql/atomicupdate/bug_22809.perl diff --git a/Koha.pm b/Koha.pm index cd3f751994..b31160885d 100644 --- a/Koha.pm +++ b/Koha.pm @@ -29,7 +29,7 @@ use vars qw{ $VERSION }; # - #4 : the developer version. The 4th number is the database subversion. # used by developers when the database changes. updatedatabase take care of the changes itself # and is automatically called by Auth.pm when needed. -$VERSION = "18.12.00.071"; +$VERSION = "18.12.00.072"; sub version { return $VERSION; diff --git a/installer/data/mysql/atomicupdate/bug_22809.perl b/installer/data/mysql/atomicupdate/bug_22809.perl deleted file mode 100644 index dfb158bf28..0000000000 --- a/installer/data/mysql/atomicupdate/bug_22809.perl +++ /dev/null @@ -1,61 +0,0 @@ -$DBversion = 'XXX'; # will be replaced by the RM -if( CheckVersion( $DBversion ) ) { - $dbh->do(q{ -INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, `title`, `content`, `message_transport_type`, `lang`) VALUES -('circulation', 'ACCOUNT_DEBIT', '', 'Account fee', 0, 'Account fee', ' - [% IF ( LibraryName ) %] - - - - [% END %] - - - - - - - - - - - - - - - - - - - [% FOREACH account IN accounts %] - - - - - [% IF ( account.amountcredit ) %] - [% IF ( account.amountoutstandingcredit ) %] - - [% END %] - - - - - [% IF ( totalcredit ) %] - - -
-

[% LibraryName | html %]

-
-

INVOICE

-
-

[% Branches.GetName( patron.branchcode ) | html %]

-
- Bill to: [% patron.firstname | html %] [% patron.surname | html %]
- Card number: [% patron.cardnumber | html %]
-
DateDescription of chargesNoteAmountAmount outstanding
[% account.date | $KohaDates%] - [% PROCESS account_type_description account=account %] - [%- IF account.description %], [% account.description | html %][% END %] - [% account.note | html %][% ELSE %][% END %][% account.amount | $Price %][% ELSE %][% END %][% account.amountoutstanding | $Price %]
Total outstanding dues as on date: [% ELSE %][% END %][% total | $Price %]
', 'print', 'default'); - }); - SetVersion( $DBversion ); - print "Upgrade to $DBversion done (Bug 22809 - Move 'INVOICE' from template to a slip)\n"; -} diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 7f335eb1a4..eff21d7316 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -18518,6 +18518,68 @@ INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, print "Upgrade to $DBversion done (Bug 22809 - Move 'ACCOUNT_CREDIT' from template to a slip)\n"; } +$DBversion = '18.12.00.072'; +if( CheckVersion( $DBversion ) ) { + $dbh->do(q{ +INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, `title`, `content`, `message_transport_type`, `lang`) VALUES +('circulation', 'ACCOUNT_DEBIT', '', 'Account fee', 0, 'Account fee', ' + [% IF ( LibraryName ) %] + + + + [% END %] + + + + + + + + + + + + + + + + + + + [% FOREACH account IN accounts %] + + + + + [% IF ( account.amountcredit ) %] + [% IF ( account.amountoutstandingcredit ) %] + + [% END %] + + + + + [% IF ( totalcredit ) %] + + +
+

[% LibraryName | html %]

+
+

INVOICE

+
+

[% Branches.GetName( patron.branchcode ) | html %]

+
+ Bill to: [% patron.firstname | html %] [% patron.surname | html %]
+ Card number: [% patron.cardnumber | html %]
+
DateDescription of chargesNoteAmountAmount outstanding
[% account.date | $KohaDates%] + [% PROCESS account_type_description account=account %] + [%- IF account.description %], [% account.description | html %][% END %] + [% account.note | html %][% ELSE %][% END %][% account.amount | $Price %][% ELSE %][% END %][% account.amountoutstanding | $Price %]
Total outstanding dues as on date: [% ELSE %][% END %][% total | $Price %]
', 'print', 'default'); + }); + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 22809 - Move 'INVOICE' from template to a slip)\n"; +} + # SEE bug 13068 # if there is anything in the atomicupdate, read and execute it. -- 2.20.1