Koha/misc/cronjobs
Pedro Amorim 5fdc778da1 Bug 34059: Add only issues from the branch that is creating the notice
Test plan, on k-t-d
1) Go to 'my account' on top right user menu
2) On 'Patron messaging preferences', click 'Edit'
3) On the 'Item due' row, check the 'Email' and 'Digests only' checkboxes and save
4) On the top search bar, press 'Check out' and enter '42' (koha user cardnumber)
5) On the checkout input bar, enter 39999000001372 and press checkout
7) Go to 'Set library' on top right user menu and pick a different library
8) Repeat step 4), then, on the checkout input, enter 39999000004571 and press checkout
9) Verify that this user now has 2 items checked out, from 2 different libraries at /cgi-bin/koha/circ/circulation.pl?borrowernumber=51
9) Run the following 2 queries to force the due_date to be equal to 'today's' date for both issues:
NOTE: change the YYYY-MM-DD below to whatever day it is you're running this test plan

UPDATE issues SET date_due = '2023-06-19 23:59:00' where issue_id = 1;
UPDATE issues SET date_due = '2023-06-19 23:59:00' where issue_id = 2;

10) Run the cronjob:
./koha/misc/cronjobs/advance_notices.pl -c --digest-per-branch

11) Verify that two DUEDGEST notices were created, one per each library, but both notices contain both issues:
SELECT letter_code, time_queued, content FROM message_queue ORDER BY message_id DESC LIMIT 2;

12) Apply patch, then do 10) and 11) again
13) Verify that each notice only contains the issue for its respective library

Signed-off-by: Sam Lau <samalau@gmail.com>
Signed-off-by: Stephen Graham <s.graham4@herts.ac.uk>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 39e6b100cb)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit bdfe5b3cde)
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
2023-08-18 13:14:29 +00:00
..
holds Bug 31995: (QA follow-up) Add 'system preference' to help text 2022-11-03 09:54:33 -03:00
recalls Bug 33992: Only consider the date when auto-expiring problematic recalls 2023-08-18 10:34:28 +00:00
rss
social_data
thirdparty
advance_notices.pl Bug 34059: Add only issues from the branch that is creating the notice 2023-08-18 13:14:29 +00:00
archive_purchase_suggestions.pl
automatic_checkin.pl
automatic_item_modification_by_age.pl
automatic_renewals.pl Bug 30642: (QA follow-up) Do not rely on script names in modules, add unit test 2023-02-13 09:29:18 +00:00
backup.sh
batch_anonymise.pl
build_browser_and_cloud.pl
cart_to_shelf.pl
check-url-quick.pl
cleanup_database.pl Bug 31969: Use filter_by_last_update 2022-11-25 09:40:09 -03:00
cloud-kw.pl
cloud-sample.conf
CONFIGURE.gmail
create_koc_db.pl
crontab.example
delete_items.pl Bug 32922: Remove space in shebang 2023-02-24 07:51:37 +00:00
delete_patrons.pl Bug 31854: (QA follow-up) Terminology: loans > checkouts 2022-11-03 10:04:27 -03:00
delete_records_via_leader.pl Bug 32656: Script delete_records_via_leader.pl no longer deletes items 2023-01-31 14:06:21 +00:00
edi_cron.pl
fines.pl Bug 18855: Don't create duplicate overdue fines if an issue is returned 2023-07-18 13:32:48 +00:00
gather_print_notices.pl
import_webservice_batch.pl Bug 15869: Change framework on overlay 2023-02-08 16:34:09 +00:00
longoverdue.pl
membership_expiry.pl
merge_authorities.pl
notice_unprocessed_suggestions.pl
overdue_notices.pl Bug 29354: Make overdue_notices.pl send .html 2023-03-16 19:30:26 +00:00
patron_emailer.pl
plugins_nightly.pl
printoverdues.sh
process_message_queue.pl Bug 33649: Fix use of cronlogaction 2023-05-12 15:05:10 +01:00
purge_suggestions.pl
reconcile_balances.pl
remove_temporary_edifiles.pl
runreport.pl Bug 33285: (QA follow-up) add POD and fix some code style 2023-04-16 18:13:55 +01:00
serialsUpdate.pl
share_usage_with_koha_community.pl
sitemap.pl
staticfines.pl Bug 27259: Add HomeOrHoldingBranch checks where it was missing from 2022-11-04 19:04:18 -03:00
stockrotation.pl
update_patrons_category.pl
update_totalissues.pl
writeoff_debts.pl