[Koha-bugs] [Bug 17649] Create only one message per borrower and overdue level

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon Dec 5 09:26:38 CET 2016


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17649

--- Comment #3 from Koha Team Lyon 3 <koha at univ-lyon3.fr> ---
(In reply to Mika from comment #2)
> 2 identical messages are still created in message_queue when 'perl
> ./misc/cronjobs/overdue_notices.pl' is run, both containing both I1 and I2.
> Both messages are sent from B1 with B1 addresses.

Did you run overdue_notices.pl with the option -a that is introduced by the
patch ?
perl ./misc/cronjobs/overdue_notices.pl  -a B2CODE
I realize that my test plan was confusing as far as step 6 is concerned and the
use of this new option.

So here is a new test plan with corrected step 6
NEW TEST PLAN :

0/ Have (or create) at least two branches B1 and B2. Have (or create) a default
notice for all branches in Notices and Slips Module
1/ Make sure you're logged in with an account belonging to B1, or switch to
branch B1
2/ checkout item I1 (belonging to B1) to patron P (preferably while specifying
a due date < today)
3/ switch to branch B2
4/ checkout item I2 (belonging to B2) to patron P (preferably while specifying
a due date < today)
5/ make sure you have defined "Overdue notice/status triggers" for that patron
category, ie with Delay=1 so that "Overdue Notice" is selected and "Email" is
checked.
6/ from cli run 'perl ./misc/cronjobs/overdue_notices.pl' (optionally
specifying also '-library B1 -library B2' )
7/ Two new entries will be generated in message_queue DB table, coming from
different branches that have the SAME list of overdue items
8/ either see the 'content' field in these entries, or run 'perl
./cronjobs/process_message_queue.pl' to receive the actual emails (provided the
email is properly setup).

Apply patch
redo step 6 running the script with the new option -a (all_in_one). this option
expect as mandatory parameter the branchcode of the library that you want to
make sender of the message. say that 'B2CODE' is the branchcode of B2 branch,
it will run like this :
perl ./misc/cronjobs/overdue_notices.pl -a B2CODE
You will see that only one message had been created. Its content shows both B1
and B2 overdue items and the sender address matches B2 address as well.

Olivier crouzet

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.


More information about the Koha-bugs mailing list