Bug 37034 - Add cronjob to alert patron with bookings ended and not been converted into a loan
Summary: Add cronjob to alert patron with bookings ended and not been converted into a...
Status: Needs Signoff
Alias: None
Product: Koha
Classification: Unclassified
Component: Tools (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Thibaud Guillot
QA Contact: Testopia
URL:
Keywords:
Depends on: 36915
Blocks:
  Show dependency treegraph
 
Reported: 2024-06-05 09:46 UTC by Thibaud Guillot
Modified: 2024-06-05 10:14 UTC (History)
0 users

See Also:
Change sponsored?: Sponsored
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 37034: Add script to alerts patron when booking ended a day before (6.82 KB, patch)
2024-06-05 09:55 UTC, Thibaud Guillot
Details | Diff | Splinter Review
Bug 37034: Add script to alerts patron when booking ended a day before (6.82 KB, patch)
2024-06-05 10:14 UTC, Thibaud Guillot
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Thibaud Guillot 2024-06-05 09:46:14 UTC
Hello,

It could be useful to alert patron with some bookings ended a day before but not been converted into a loan. Based on notice template.
Comment 1 Thibaud Guillot 2024-06-05 09:55:19 UTC
Created attachment 167434 [details] [review]
Bug 37034: Add script to alerts patron when booking ended a day before

Test plan:

1) Write a notice template to use datas from this script.
For example :
"
Hello <<borrowers.firstname>>, <<borrowers.surname>>

Some bookings ended yesterday:
[% FOREACH booking IN bookings %]
  Booking number [% booking.booking_id %] linked to [% booking.biblio.title %] which was to be
  taken from the library [% booking.pickup_library.branchname %], ended [% booking.end_date %].
[% END %]
"

2) This template can have custom lettercode but don't forget to use it
   when you launch it. By default (if no lettercode is send to script,
'BOOKINGS_OUTDATED' code will be used)

3) Launch 'perl misc/cronjobs/bookings/bookings_outdated.pl' with args
   or not
4) Go on message_queue and you can normally see your message.

Sponsored by: Association de Gestion des Œuvres Sociales d'Inria (AGOS)
Comment 2 Thibaud Guillot 2024-06-05 10:14:46 UTC
Created attachment 167435 [details] [review]
Bug 37034: Add script to alerts patron when booking ended a day before

Test plan:

1) Write a notice template to use datas from this script.
For example :
"
Hello <<borrowers.firstname>>, <<borrowers.surname>>

Some bookings ended yesterday:
[% FOREACH booking IN bookings %]
  Booking number [% booking.booking_id %] linked to [% booking.biblio.title %] which was to be
  taken from the library [% booking.pickup_library.branchname %], ended [% booking.end_date %].
[% END %]
"

2) This template can have custom lettercode but don't forget to use it
   when you launch it. By default (if no lettercode is send to script,
'BOOKINGS_OUTDATED' code will be used)

3) Launch 'perl misc/cronjobs/bookings/bookings_outdated.pl' with args
   or not
4) Go on message_queue and you can normally see your message.

Sponsored by: Association de Gestion des Œuvres Sociales d'Inria (AGOS)