misc/cronjobs/patron_emailer.pl was introduced by Bug 16149, but as far as I can tell it is not documented in the manual. Sorry if I missed it. I'd say documenting this is extra important, since it is a cool feature that is not visible from the Koha GUI (but see also Bug 27452.)
I'll have a go at drafting something out and run it by our support company- I've not done any documentation work in Koha, so I am a newbie. I just love the patron emailer functionality and we are using it a lot, with more uses to come. But I am struggling a bit with the lack of html / TT support that I have rasied in Bug 27443.
Hi Ray, have you unsuccessfully tried to mark the notice template used as HTML? From looking at the cron I don't see why that wouldn't work. It seems to use the standard procedure for creating emails. The patron emailer documentation on ByWater's blog also included some TT - sadly that is no longer accessible. Maybe by TT you think of specific objects or variables?
Apologies- on 22.11 I have notices being sent by the patron_emailer.pl script working perfectly with html, and the fields pulled in from the report must use TT notation so html and at least some TT is supported. All I can assume from earlier failures (ages back) must be down to specific objects/ variables that either aren’t fully supported (or more likely!) I had syntax errors in my TT code.
(In reply to Ray Delahunty from comment #3) > Apologies- on 22.11 I have notices being sent by the patron_emailer.pl > script working perfectly with html, and the fields pulled in from the report > must use TT notation so html and at least some TT is supported. All I can > assume from earlier failures (ages back) must be down to specific objects/ > variables that either aren’t fully supported (or more likely!) I had syntax > errors in my TT code. Thanks for the feedback! I think it would be worthwhile to have better documentation especially with some no longer available for the plugin.
https://koha.bywatersolutions.com/education/monday-minutes-emailing-customized-patron-notices 1.) REPORT create the report. Keep in mind, only columns in report are available for the sent notice All reports for this function need to include borrowernumber and an emailaddress Example Report: SELECT borrowernumber, email, firstname, surname, round (sum(amountoutstanding),2) as total_fines FROM borrowers LEFT JOIN accountlines using (borrowernumber) GROUP BY borrowernumber HAVING total_fines>50 2.) NOTICE / LETTER Go to Tools › Notices & slips. Click on + New notice dropdown. Select the module you want to add the notice to ( remember this information for the cronjob). Create a code for the notice (all caps and under 10 characters as a rule of thumb). You will also need this code for the cronjob. Add a name for the notice. Add a message subject. Add in your message body (we use the template toolkit syntax in the example in our video). Click save. Example from video: Dear [% firstname %] [% surname %]. You owe us $[% total_fines %]. Please pay up. Thank you so much!! 3.) CRONJOB Once you have created the notice and set up the report, it's time to set up the cronjob. You will want to include the 3 following items: The code of the notice (Tools - Notices and Slips) The module of the notice (Tools - Notices and Slips) The report number (Reports Module) Here is an example of the cronjob that will be run: misc/cronjobs/patron_emailer.pl --report 48 --notice BIGFINE --module circulation --from anyone@anywhere.com --commit