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

--- Comment #1 from babar junaid <[email protected]> ---
Created attachment 212179
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=212179&action=edit
Bug 44189: Anonymize only the selected library's checkout history

Bug 44189: Anonymize only the selected library's checkout history

Batch patron deletion and anonymization counted the histories to
anonymize at the selected library (search_patrons_to_anonymise with
library), but step 3 anonymized with no library at all, so every
library's checkouts returned before the date were anonymized. Under
IndependentBranches a staff member who is not a superlibrarian did the
same with "All libraries", although step 2 counted only their own.

Step 3 now passes the same library to filter_by_anonymizable, which takes
an optional library parameter.

Test plan:
1. prove t/db_dependent/Koha/Old/Checkouts.t
   The new subtest fails without the patch.
2. Set AnonymousPatron to an existing patron.
3. Take a patron whose privacy is not "Forever" and give them two returned
   checkouts dated before today: one with old_issues.branchcode = CPL,
   one with old_issues.branchcode = MPL.
4. Tools > Batch patron deletion and anonymization, Select a library =
   Centerville (CPL). Tick "Anonymize checkout history older than",
   tomorrow's date. Next.
5. Step 2 says the history of 1 patron at Centerville will be anonymized.
   Finish.
6. Without the patch: both checkouts now belong to the anonymous patron.
   With the patch: only the CPL checkout does; the MPL one is untouched.
7. Repeat with All libraries: both are anonymized.

Sponsored-by: Koha Solutions

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
_______________________________________________
Koha-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to