[Bug 41632] New: Add Koha::CSV::Overdue for overdue exports
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41632 Bug ID: 41632 Summary: Add Koha::CSV::Overdue for overdue exports Initiative type: --- Sponsorship --- status: Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: tomascohen@gmail.com QA Contact: testopia@bugs.koha-community.org Depends on: 41619 Blocks: 41621 This bug adds Koha::CSV::Overdue to standardize CSV generation for overdue exports. Files to update: - circ/overdue.pl - misc/cronjobs/overdue_notices.pl Benefits: - Consistent CSV formatting - Proper quote handling - Testable code Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41619 [Bug 41619] Add `Koha::CSV` https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41621 [Bug 41621] Use Koha::CSV everywhere [UMBRELLA] -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41632 Bug 41632 depends on bug 41619, which changed state. Bug 41619 Summary: Add `Koha::CSV` https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41619 What |Removed |Added ---------------------------------------------------------------------------- Status|Needs documenting |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41632 Tomás Cohen Arazi (tcohen) <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch Status|NEW |Needs Signoff -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41632 --- Comment #1 from Tomás Cohen Arazi (tcohen) <tomascohen@gmail.com> --- Created attachment 203494 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=203494&action=edit Bug 41632: Use Koha::CSV for overdue exports This patch introduces Koha::CSV::Overdues, a subclass of Koha::CSV with fixed column definitions for the overdue report, and updates both circ/overdue.pl and misc/cronjobs/overdue_notices.pl. circ/overdue.pl: - Replaces the build_csv() function with Koha::CSV::Overdues - Uses export() with arrayref of overdue hashrefs - Privacy filtering applied before export misc/cronjobs/overdue_notices.pl: - Replaces Text::CSV_XS with Koha::CSV low-level API - Same combine/string pattern (cron script has different flow) Benefits: - formula => empty enforced (prevents formula injection) - CSVDelimiter system preference used consistently - Overdue columns defined once in Koha::CSV::Overdues - Removes build_csv function and Text::CSV_XS dependencies Test plan: 1. Apply patches (depends on bug 41620) 2. Go to Circulation > Overdues, export as CSV => SUCCESS: CSV generated with all columns 3. Test with restricted patron visibility => SUCCESS: Private fields blanked appropriately 4. Run overdue_notices.pl with --csv: k$ perl misc/cronjobs/overdue_notices.pl -n --csv /tmp/overdues.csv => SUCCESS: CSV file generated 5. Sign off :-D -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org