Koha/misc/cronjobs
Marcel de Rooy 52d30fba7b Bug 15543: Use another notice in membership_expiry.pl
This patch adds a letter parameter to the cron job membership_expiry.
It is used to substitute the default notice by another one.
This could be handy if you e.g. send a reminder after the first notice.
In any case, it allows for more flexibility.

Apart from this new parameter, this patch removes the sub parse_letter from
the code. The call to GetPreparedLetter is moved to the for loop and the
call to getletter is removed (no longer needed). If there is no letter
found, the Letter module already warns you. So we just exit the loop.

Test plan:
[1] Run membership_expiry.pl -c -n -v -let NOT_EXIST
    Check if you see a warning (coming from Letters.pm)
[2] Check if you have some soon expiring patrons or add before/after
    parameter to include some.
    Run membership_expiry.pl -c -n -v [-before ?] [-after ?]
[3] Create a new notice MEMBERSHIP2. Copy the text from the original notice
    and make some adjustments.
[4] Run membership_expiry.pl -c -v -let MEMBERSHIP2 [-before ?] [-after ?].
    Be aware that this call generates email messages.
    Verify that the email contained the adjusted text.

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>

On top of Bug 14834
Work as described, tested using '-n' to see messages on terminal, e.g.
membership_expiry.pl -v -n -c -before 3 -branch BC -after 2 --letter MEMEXP2
No errors

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
2016-04-29 16:58:58 +00:00
..
holds
rss
social_data Bug 15193 - Perl scripts missing exec permission 2015-12-11 16:36:08 +00:00
thirdparty Bug 9004: Use Koha::Calendar instead of C4::Calendar 2016-04-29 12:01:24 +00:00
advance_notices.pl Bug 15629: Koha::Libraries - Remove GetBranchDetail 2016-02-24 03:55:06 +00:00
automatic_item_modification_by_age.pl Bug 11023: Automatic item modification by age (Was Toggle "new" status") 2016-03-02 22:56:31 +00:00
automatic_renewals.pl
backup.sh
batch_anonymise.pl Bug 14960: Remove C4::Dates from files in misc/cronjobs 2015-11-17 15:36:43 -03:00
build_browser_and_cloud.pl
cart_to_shelf.pl
check-url-quick.pl
check-url.pl
cleanup_database.pl Bug 15548: Move new patron related code to Patron* 2016-03-03 14:38:26 -07:00
cloud-kw.pl
cloud-sample.conf
CONFIGURE.gmail
create_koc_db.pl
crontab.example
delete_expired_opac_registrations.pl
delete_patrons.pl Bug 10612: (QA followup) 2016-04-01 19:52:14 +00:00
delete_records_via_leader.pl Bug 11084 [QA Followup] - Document limitations of test mode 2015-12-29 19:32:20 +00:00
delete_unverified_opac_registrations.pl
edi_cron.pl Bug 15630 - Make Edifact module pluggable 2016-04-01 21:31:28 +00:00
fines.pl Bug 15675 - Add issue_id column to accountlines and use it for updating fines 2016-03-02 03:24:45 +00:00
gather_print_notices.pl Bug 14960: Remove C4::Dates from files in misc/cronjobs 2015-11-17 15:36:43 -03:00
import_webservice_batch.pl
j2a.pl Bug 15742 [QA Followup] - Tidy script 2016-02-23 21:19:08 +00:00
longoverdue.pl Bug 15548: Move new patron related code to Patron* 2016-03-03 14:38:26 -07:00
MARC21_parse_test.pl Bug 16011: $VERSION - Remove comments 2016-03-24 17:20:29 +00:00
membership_expiry.pl Bug 15543: Use another notice in membership_expiry.pl 2016-04-29 16:58:58 +00:00
nl-sync-from-koha.pl Bug 15193 - Perl scripts missing exec permission 2015-12-11 16:36:08 +00:00
nl-sync-to-koha.pl Bug 15193 - Perl scripts missing exec permission 2015-12-11 16:36:08 +00:00
notice_unprocessed_suggestions.pl Bug 15629: Koha::Libraries - Remove GetBranchDetail 2016-02-24 03:55:06 +00:00
overdue_notices.pl Bug 15967: Use the email template if the print template does not exist 2016-04-05 15:14:48 +00:00
printoverdues.sh
process_message_queue.pl
purge_suggestions.pl
remove_temporary_edifiles.pl Bug 7736: Support Ordering via Edifact EDI messages 2016-04-01 20:03:17 +00:00
runreport.pl Bug 16011: $VERSION - Remove comments 2016-03-24 17:20:29 +00:00
serialsUpdate.pl Bug 14960: Remove C4::Dates from files in misc/cronjobs 2015-11-17 15:36:43 -03:00
services_throttle.pl
share_usage_with_koha_community.pl Bug 16039: Remove useless exit 2016-03-23 20:57:22 +00:00
sitemap.pl Bug 16031: (followup) Fix documentation 2016-03-11 15:28:50 +00:00
staticfines.pl Bug 14960: Simplify the date management in staticfines 2015-11-17 15:36:51 -03:00
update_totalissues.pl