Bug 42037 - Add diff support to ACQUISITIONS action logs
Summary: Add diff support to ACQUISITIONS action logs
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Transaction logs (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks: 37940
  Show dependency treegraph
 
Reported: 2026-03-09 15:37 UTC by Martin Renvoize (ashimema)
Modified: 2026-03-09 15:37 UTC (History)
0 users

See Also:
GIT URL:
Initiative type: ---
Sponsorship status: ---
Comma delimited list of Sponsors:
Crowdfunding goal: 0
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize (ashimema) 2026-03-09 15:37:20 UTC
The action logging for acquisitions events does not pass structured data or the $original parameter to logaction(), so no structured diff is generated in the action_logs.diff column.

Currently the only logged acquisitions action is:
- acqui/cancelorder.pl CANCEL_ORDER (~line 82):
  logaction( 'ACQUISITIONS', 'CANCEL_ORDER', $ordernumber );
  (no $infos or $original passed)

This bug covers a broader review of acquisitions logging to:
1. Update the CANCEL_ORDER log call to pass the order data (Koha::Acquisition::Order object or its unblessed hashref) as both $infos and $original so the log shows what was cancelled.
2. Identify and add logaction() calls for other significant acquisitions events (order creation, modification, receipt) that are currently unlogged or poorly logged, passing appropriate $infos and $original data to enable diff support.