Browse Source

Bug 12224: DBRev 20.12.00.022

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
21.05.x
Jonathan Druart 9 months ago
parent
commit
7e66d32be4
  1. 2
      Koha.pm
  2. 23
      installer/data/mysql/atomicupdate/bug_12224-add_CHECKINSLIP_notice.perl
  3. 24
      installer/data/mysql/updatedatabase.pl

2
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 = "20.12.00.021";
$VERSION = "20.12.00.022";
sub version {
return $VERSION;

23
installer/data/mysql/atomicupdate/bug_12224-add_CHECKINSLIP_notice.perl

@ -1,23 +0,0 @@
$DBversion = 'XXX';
if( CheckVersion( $DBversion ) ) {
$dbh->do(q{ INSERT IGNORE INTO letter (module, code, branchcode, name, is_html, title, content, message_transport_type) VALUES
('circulation','CHECKINSLIP','','Checkin slip',1,'Checkin slip',
"<h3>[% branch.branchname %]</h3>
Checked in items for [% borrower.title %] [% borrower.firstname %] [% borrower.initials %] [% borrower.surname %] <br />
([% borrower.cardnumber %]) <br />
[% today | $KohaDates %]<br />
<h4>Checked in today</h4>
[% FOREACH checkin IN old_checkouts %]
[% SET item = checkin.item %]
<p>
[% item.biblio.title %] <br />
Barcode: [% item.barcode %] <br />
</p>
[% END %]",
'print')
});
NewVersion( $DBversion, 12224, "Add CHECKINSLIP notice" );
}

24
installer/data/mysql/updatedatabase.pl

@ -23634,6 +23634,30 @@ if( CheckVersion( $DBversion ) ) {
NewVersion( $DBversion, 22824, "Update syspref values for YesNo");
}
$DBversion = '20.12.00.022';
if( CheckVersion( $DBversion ) ) {
$dbh->do(q{ INSERT IGNORE INTO letter (module, code, branchcode, name, is_html, title, content, message_transport_type) VALUES
('circulation','CHECKINSLIP','','Checkin slip',1,'Checkin slip',
"<h3>[% branch.branchname %]</h3>
Checked in items for [% borrower.title %] [% borrower.firstname %] [% borrower.initials %] [% borrower.surname %] <br />
([% borrower.cardnumber %]) <br />
[% today | $KohaDates %]<br />
<h4>Checked in today</h4>
[% FOREACH checkin IN old_checkouts %]
[% SET item = checkin.item %]
<p>
[% item.biblio.title %] <br />
Barcode: [% item.barcode %] <br />
</p>
[% END %]",
'print')
});
NewVersion( $DBversion, 12224, "Add CHECKINSLIP notice" );
}
# SEE bug 13068
# if there is anything in the atomicupdate, read and execute it.
my $update_dir = C4::Context->config('intranetdir') . '/installer/data/mysql/atomicupdate/';

Loading…
Cancel
Save