Bug 28688: Add new notice MEMBERSHIP_RENEWED

Test plan:
Run new install or upgrade.
Check for this notice under Tools/Notices.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
[EDIT] Enrollment fee via object instead of substitute hash.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Marcel de Rooy 2023-06-15 08:51:32 +00:00 committed by Tomas Cohen Arazi
parent 7f6009068e
commit a912709898
Signed by: tomascohen
GPG key ID: 0A272EA1B2F3C15F
2 changed files with 37 additions and 0 deletions

View file

@ -0,0 +1,17 @@
use Modern::Perl;
return {
bug_number => 28688,
description => "Add notice MEMBERSHIP_RENEWED",
up => sub {
my ($args) = @_;
my ( $dbh, $out ) = @$args{qw(dbh out)};
$dbh->do(
q{
INSERT IGNORE INTO `letter` (`module`, `code`, `branchcode`, `name`, `is_html`, `title`, `content`, `message_transport_type`, `lang`)
VALUES ( 'members', 'MEMBERSHIP_RENEWED', '', 'Account renewal', 0, 'Account renewal', "[%- USE Price -%]\nDear [% borrower.title %] [% borrower.firstname %] [% borrower.surname %],\n\nYour library account has been renewed. The new expiry date is: [% borrower.dateexpiry %].\n\n[% IF borrower.category.enrolmentfee > 0 %]An enrollment fee of [% borrower.category.enrolmentfee | $Price with_symbol => 1 %] has been applied.\n\n[% END %]Thank you,\n\nYour library,\n\n[% branch.branchname %]", 'email', 'default' )
}
);
},
};

View file

@ -1300,6 +1300,26 @@ tables:
- ""
- "<<branches.branchname>>"
- module: members
code: MEMBERSHIP_RENEWED
branchcode: ""
name: "Account renewal"
is_html: 0
title: "Account renewal"
message_transport_type: email
lang: default
content:
- "[%- USE Price -%]"
- "Dear [% borrower.title %] [% borrower.firstname %] [% borrower.surname %],"
- ""
- "Your library account has been renewed. The new expiry date is: [% borrower.dateexpiry %]."
- "[% IF borrower.category.enrolmentfee > 0 %]\nAn enrollment fee of [% borrower.category.enrolmentfee | $Price with_symbol => 1 %] has been applied.\n[% END %]"
- "Thank you,"
- ""
- "Your library,"
- ""
- "[% branch.branchname %]"
- module: members
code: OPAC_REG_VERIFY
branchcode: ""