@@ -, +, @@ --- .../data/mysql/atomicupdate/bug_22566.perl | 7 ++++++ .../mysql/en/mandatory/sample_notices.sql | 22 ++++++++++++++++++- 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 installer/data/mysql/atomicupdate/bug_22566.perl --- a/installer/data/mysql/atomicupdate/bug_22566.perl +++ a/installer/data/mysql/atomicupdate/bug_22566.perl @@ -0,0 +1,7 @@ +$DBversion = 'XXX'; +if ( CheckVersion($DBversion) ) { + $dbh->do(q{UPDATE letter SET content = 'Stockrotation report for [% name %]:\r\n\r\n[%- IF items.size -%]\r\n[% items.size %] items to be processed for this branch.\r\n[%- ELSE -%]\r\nNo items to be processed for this branch\r\n[%- END -%]\r\n\r\n\r\n[%- FOREACH item IN items -%]\r\n[% IF item.reason != ''in-demand'' %]\r\nTitle: [% item.title %]\r\nAuthor: [% item.author %]\r\nCallnumber: [% item.callnumber %]\r\nLocation: [% item.location %]\r\nBarcode: [% item.barcode %]\r\nOn loan?: [% item.onloan %]\r\nStatus: [% item.reason %]\r\nCurrent Library: [% item.branch.branchname %] [% item.branch.branchcode %]\r\n[% END %]\r\n[%- END -%]' WHERE code = 'SR_SLIP'}); + + SetVersion($DBversion); + print "Upgrade to $DBversion done (Bug XXXXX - description)\n"; +} --- a/installer/data/mysql/en/mandatory/sample_notices.sql +++ a/installer/data/mysql/en/mandatory/sample_notices.sql @@ -315,4 +315,24 @@ INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, ', 'print', 'default'); INSERT INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, `title`, `content`, `message_transport_type`) VALUES -('circulation', 'SR_SLIP', '', 'Stock rotation slip', 0, 'Stock rotation report', 'Stock rotation report for [% branch.name %]:\r\n\r\n[% IF branch.items.size %][% branch.items.size %] items to be processed for this branch.\r\n[% ELSE %]No items to be processed for this branch\r\n[% END %][% FOREACH item IN branch.items %][% IF item.reason != \'in-demand\' %]Title: [% item.title %]\r\nAuthor: [% item.author %]\r\nCallnumber: [% item.callnumber %]\r\nLocation: [% item.location %]\r\nBarcode: [% item.barcode %]\r\nOn loan?: [% item.onloan %]\r\nStatus: [% item.reason %]\r\nCurrent library: [% item.branch.branchname %] [% item.branch.branchcode %]\r\n\r\n[% END %][% END %]', 'email'); +('circulation', 'SR_SLIP', '', 'Stock rotation slip', 0, 'Stock rotation report', 'Stockrotation report for [% name %]: + +[%- IF items.size -%] +[% items.size %] items to be processed for this branch. +[%- ELSE -%] +No items to be processed for this branch +[%- END -%] + + +[%- FOREACH item IN items -%] +[% IF item.reason != ''in-demand'' %] +Title: [% item.title %] +Author: [% item.author %] +Callnumber: [% item.callnumber %] +Location: [% item.location %] +Barcode: [% item.barcode %] +On loan?: [% item.onloan %] +Status: [% item.reason %] +Current Library: [% item.branch.branchname %] [% item.branch.branchcode %] +[% END %] +[%- END -%]', 'email'); --