https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41358
--- Comment #2 from Martin Renvoize (ashimema) <[email protected]> --- Created attachment 190624 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=190624&action=edit Bug 41358: Always store circulation logs in consistent JSON format Previously, CIRCULATION ISSUE logs would store just the itemnumber when there were no confirmations or forced overrides, but would store a full JSON structure when overrides were present. This inconsistency makes reporting difficult as queries need to handle both formats. This patch changes AddIssue to always store logs in JSON format, matching the pattern already used in AddRenewal. The JSON structure now consistently includes: - issue: issue_id - branchcode: branchcode - itemnumber: itemnumber - confirmations: array of confirmation codes (empty array if none) - forced: array of forced override codes (empty array if none) Benefits: - Consistent data format simplifies reporting and analysis - Matches existing RENEWAL logging pattern - Display code (tools/viewlog.pl) already handles both formats, so backward compatibility is maintained Test plan: 1. prove t/db_dependent/Circulation.t 2. Perform a normal checkout - verify action log contains JSON 3. Perform a checkout with overrides - verify confirmations/forced are populated in the JSON 4. Check Tools > Log viewer - both types should display correctly Sponsored-by: OpenFifth <https://openfifth.co.uk/> -- 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] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
