[Bug 33013] New: Add age, interface and operator as additional report stats
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Bug ID: 33013 Summary: Add age, interface and operator as additional report stats Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: ASSIGNED Severity: enhancement Priority: P5 - low Component: Reports Assignee: stalkernoid@gmail.com Reporter: stalkernoid@gmail.com QA Contact: testopia@bugs.koha-community.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 --- Comment #1 from Peter Vashchuk <stalkernoid@gmail.com> --- Created attachment 146955 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=146955&action=edit Bug 33013: add age, interface and operator to pseudonymized statistics This patch adds: age (patron's age), interface (sip/api/opac/intranet/cron/etc) and operator (user id if it has extra permissions, for example: librarian) to the pseudonymized statistics table. To reproduce: 1. With Pseudonymization enabled, perform a check-out, check-in or renew to add an entry to the pseudonymized_transactions table. 2. Apply the patch and perform the atomic update. 3. Go to sysprefs and enable "Interface" and "Operator ID" for PseudonymizationTransactionFields and "Patron's age" for PseudonymizationPatronFields. 4. Perform the same actions as you did earlier (check-out, check-in, or renew) to add another entry to the pseudonymized_transactions table. Compare those two entries, the one that was added should have new stats. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=30928 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart+koha@gmail. | |com --- Comment #2 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- I don't understand the "operator", can you detail please? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |emily-rose.francoeur@inLibr | |o.com Status|Needs Signoff |Patch doesn't apply --- Comment #3 from Émily-Rose Francoeur <emily-rose.francoeur@inLibro.com> --- When I try to apply the patch (git bz apply 33013) at step 2, I got this error error: sha1 information is lacking or useless (Koha/PseudonymizedTransaction.pm). error: could not build fake ancestor Patch failed at 0001 Bug 33013: add age, interface and operator to pseudonymized statistics hint: Use 'git am --show-current-patch=diff' to see the failed patch When you have resolved this problem run "git bz apply --continue". If you would prefer to skip this patch, instead run "git bz apply --skip". To restore the original branch and stop patching run "git bz apply --abort". Patch left in /tmp/Bug-33013-add-age-interface-and-operator-to-pseudo-xu_nqqh0.patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #146955|0 |1 is obsolete| | --- Comment #4 from Peter Vashchuk <stalkernoid@gmail.com> --- Created attachment 155591 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=155591&action=edit Bug 33013: add age, interface and operator to pseudonymized statistics This patch adds: age (patron's age), interface (sip/api/opac/intranet/cron/etc) and operator (user id if it has extra permissions, for example: librarian) to the pseudonymized statistics table. To reproduce: 1. With Pseudonymization enabled, perform a check-out, check-in or renew to add an entry to the pseudonymized_transactions table. 2. Apply the patch and perform the atomic update. 3. Go to sysprefs and enable "Interface" and "Operator ID" for PseudonymizationTransactionFields and "Patron's age" for PseudonymizationPatronFields. 4. Perform the same actions as you did earlier (check-out, check-in, or renew) to add another entry to the pseudonymized_transactions table. Compare those two entries, the one that was added should have new stats. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 --- Comment #5 from Peter Vashchuk <stalkernoid@gmail.com> --- (In reply to Émily-Rose Francoeur from comment #3) Rebased on the current master, it should work now -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA CC| |lucas@bywatersolutions.com --- Comment #6 from Lucas Gass <lucas@bywatersolutions.com> --- Hi Peter, Can you perltidy you changes? WARN Koha/PseudonymizedTransaction.pm WARN tidiness The file is less tidy than before (bad/messy lines before: 14, now: 26) WARN Koha/Schema/Result/PseudonymizedTransaction.pm WARN tidiness The file is less tidy than before (bad/messy lines before: 56, now: 62) WARN installer/data/mysql/atomicupdate/bug-33013_more-pseudonymization-fields.pl WARN tidiness The file is less tidy than before (bad/messy lines before: 0, now: 19) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #155591|0 |1 is obsolete| | --- Comment #7 from Peter Vashchuk <stalkernoid@gmail.com> --- Created attachment 155780 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=155780&action=edit Bug 33013: add age, interface and operator to pseudonymized statistics This patch adds: age (patron's age), interface (sip/api/opac/intranet/cron/etc) and operator (user id if it has extra permissions, for example: librarian) to the pseudonymized statistics table. To reproduce: 1. With Pseudonymization enabled, perform a check-out, check-in or renew to add an entry to the pseudonymized_transactions table. 2. Apply the patch and perform the atomic update. 3. Go to sysprefs and enable "Interface" and "Operator ID" for PseudonymizationTransactionFields and "Patron's age" for PseudonymizationPatronFields. 4. Perform the same actions as you did earlier (check-out, check-in, or renew) to add another entry to the pseudonymized_transactions table. Compare those two entries, the one that was added should have new stats. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA --- Comment #8 from Lucas Gass <lucas@bywatersolutions.com> --- Hi Peter, a couple things: 1. Your DB update still reads 'bug_number => "BUG_NUMBER",'. Can you replace that with the actual bug number. 2. If I run the 'updatedatabase' multiple times it will continue to output: Warning: PseudonymizationPatronFields already has 'age' Warning: PseudonymizationTransactionFields already has 'interface' Warning: pseudonymized_transactions already has 'age' Warning: pseudonymized_transactions already has 'interface' Warning: pseudonymized_transactions already has 'operator 3. Can we get an explain of "operator" as Jonathan requested in comment 2? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Peter Vashchuk <stalkernoid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #155780|0 |1 is obsolete| | --- Comment #9 from Peter Vashchuk <stalkernoid@gmail.com> --- Created attachment 178419 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=178419&action=edit Bug 33013: add age, interface and operator to pseudonymized statistics This patch adds age (patron's age), interface (sip/api/opac/intranet/cron/etc) and operator (numerical user id who performed pseudonymized action) to the pseudonymized statistics table. To reproduce: 1. With Pseudonymization enabled, perform a check-out, check-in or renew to add an entry to the pseudonymized_transactions table. 2. Apply the patch and perform the atomic update. 3. Go to sysprefs and enable "Interface" and "Operator ID" for PseudonymizationTransactionFields and "Patron's age" for PseudonymizationPatronFields. 4. Perform the same actions as you did earlier (check-out, check-in, or renew) to add another entry to the pseudonymized_transactions table. Compare those two entries, the one that was added should have new stats. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andrew@bywatersolutions.com | |, sspohn@oslri.net -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33013 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA --- Comment #10 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Testing... overall this works as expected. Mostly some smaller issues with the database update. If you follow-up I will try to come back to this ASAP for SO. 1) QA checks pass. (OK) 2) Code review a) Database update (blocker) * Schema changes should be in a separate patch file. * This activates the new options by default on update. I am not sure if this is what we want here or not. Raising as a question. But if we really want to do this: Results could be inconsistent depending on which options have been activated for Pseudonymization. If we wanted to do this maybe check for pref not empty and then concatenate the new options at the end? Given, transaction_type is probably always activated, but sex might be not. * The database update is missing a success message. Have a look at the latest database updates or the skeleton file. b) Terminology (no blocker) * + `operator` int(11) DEFAULT NULL COMMENT 'User id (if user has extra permissions, operator, api-keys user, sip-user, librarian)', + operator: "Operator ID (user id if it has extra permissions, i.e. librarian)" Should user id be user ID or even borrowernumber here? 3) Testing (OK) Followed the test plan and this works as expected. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org