[Koha-bugs] [Bug 34611] Add a script for pseudonymizing existing data

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Sat Mar 23 17:31:40 CET 2024


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

--- Comment #37 from Nick Clemens <nick at bywatersolutions.com> ---
Created attachment 163757
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=163757&action=edit
Bug 34611: (follow-up) Preserve statistic date if passed or null if not

When testing the confirm option, I found that I was not warned on repeated
runs.
It turns out creating a new statistic object was setting the datetime to
current
timestamp

This patch reset the object from the values passed

To test:
1 - Disable Pseudonymization
2 - Perform some transactions, update datetimein DB to set them to yesterday
3 - Enable pseudonymization, ensure 'Date and time of transaction' is checked
4 - perl misc/maintenance/pseudonymize_statistics.pl -v
5 - Check the DB, note the new pseudonymized transactions have todays date
6 - DELETE FROM pseudonymized_transactions
7 - Apply patch
8 - perl misc/maintenance/pseudonymize_statistics.pl -v
9 - Check DB and confirm the transactoins have the original date
10 - DELETE FROM pseudonymized_transactions
11 - Unset date and time from pseudonymization pref
12 - perl misc/maintenance/pseudonymize_statistics.pl -v
13 - Confirm the transactions have a null date

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


More information about the Koha-bugs mailing list