Bug 35645 - Modification log for bibliographic records and items should only show changed values
Summary: Modification log for bibliographic records and items should only show changed...
Status: ASSIGNED
Alias: None
Product: Koha
Classification: Unclassified
Component: Staff interface (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks: 22794
  Show dependency treegraph
 
Reported: 2023-12-22 17:21 UTC by Angela Berrett
Modified: 2025-04-14 15:44 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
OLIB cataloging system item modification log (113.41 KB, image/jpeg)
2023-12-22 17:21 UTC, Angela Berrett
Details
Current Koha modification log view (110.34 KB, image/png)
2023-12-22 17:29 UTC, Angela Berrett
Details
Bug 35645: Show diff in log viewer (1.99 KB, patch)
2025-04-14 13:10 UTC, Andrew Fuerste-Henry
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Angela Berrett 2023-12-22 17:21:38 UTC
Created attachment 160266 [details]
OLIB cataloging system item modification log

The modification logs for a bib record puts all bibliographic and item information in a single text box when an edit occurs.  For easier reading it would be nice to only show the fields/information that were modified. 

A previous catalog our library used would show a single line per change when an item was modified.  It would show the date | person who made the change | old value | new value.  This kept an accurate history and made reviewing the changes easy to read. As there is a single modification page for all items on a bib record the object column identifying which item was changed would need to be included. 

A similar table could be created for bib record modifications identifying the MARC field that was changed either in the Object column or in its own column, along with the old and new values.
Comment 1 Angela Berrett 2023-12-22 17:29:28 UTC
Created attachment 160267 [details]
Current Koha modification log view
Comment 2 Kathleen L. 2024-06-21 14:26:00 UTC
We often find it difficult to identify the edit that has been made int he modification log. Agree that a more concise change log as Angela describes would be helpful. 

A step in that direction might be do highlight or change the color of the field(s) that had been edited. I imagine that might be easier coding?
Comment 3 Laura O'Neil 2024-06-21 15:20:35 UTC
Yes please, this would be a great enhancement. +1
Comment 4 Angela Berrett 2025-02-28 18:59:58 UTC
(In reply to Kathleen L. from comment #2)
> We often find it difficult to identify the edit that has been made int he
> modification log. Agree that a more concise change log as Angela describes
> would be helpful. 
> 
> A step in that direction might be do highlight or change the color of the
> field(s) that had been edited. I imagine that might be easier coding?

I like the idea of highlighting as a start.  With the 24.11 enhancement to log an item's previous data as well as the changed data this could be a useful conversation again.
Comment 5 vstever 2025-04-10 19:54:46 UTC
Definitely would like to have this. I find it very challenging to parse down to the actual change -- I feel like I waste a lot of time struggling to understand.
Comment 6 Andrew Fuerste-Henry 2025-04-11 13:46:17 UTC
Would it be sufficient to just include the action_logs.diff column in the log viewer, or would be want to format that data somehow? For reference, here's that diff column after an edit to remove a public note:

{"D":{"datelastseen":{"O":"2025-04-11 13:44:14","N":"2025-04-11 13:44:00"},"timestamp":{"O":"2025-04-11 13:44:14","N":"2025-04-11 13:44:45"},"itemnotes":{"N":null,"O":"boop"}}}
Comment 7 Angela Berrett 2025-04-11 18:16:44 UTC
(In reply to Andrew Fuerste-Henry from comment #6)
> Would it be sufficient to just include the action_logs.diff column in the
> log viewer, or would be want to format that data somehow? For reference,
> here's that diff column after an edit to remove a public note:
> 
> {"D":{"datelastseen":{"O":"2025-04-11 13:44:14","N":"2025-04-11
> 13:44:00"},"timestamp":{"O":"2025-04-11 13:44:14","N":"2025-04-11
> 13:44:45"},"itemnotes":{"N":null,"O":"boop"}}}

That would be sufficient if formatting is difficult - at least in my opinion.
Comment 8 Andrew Fuerste-Henry 2025-04-14 13:10:31 UTC
Created attachment 180904 [details] [review]
Bug 35645: Show diff in log viewer

To test:
1 - apply patch
2 - search the log viewer for item edits or something else that records a diff value
3 - see that diff in the new column
4 - confirm the diff value is present in exports and prints
5 - confirm you can use column config to hide that diff value
Comment 9 Andrew Fuerste-Henry 2025-04-14 13:12:06 UTC
This simply makes the diff visible. It should be pretty doable to get it to format more readably (for someone with more display skill than I).
Comment 10 Andrew Fuerste-Henry 2025-04-14 13:15:03 UTC
Though I must admit, the change I've made here is really broader than the current title of this bug. Angela, do you mind if I re-title and re-focus this, or should I file my own bug?
Comment 11 Angela Berrett 2025-04-14 14:52:26 UTC
(In reply to Andrew Fuerste-Henry from comment #10)
> Though I must admit, the change I've made here is really broader than the
> current title of this bug. Angela, do you mind if I re-title and re-focus
> this, or should I file my own bug?

Would you call this more of an "interim solution" that is a step towards redesigning the front-end format? If so, another bug might be good, and just link it to this one as the end goal. It sounds like the ideal format is a more concise and reader-friendly one (less punctuation, more full words) for those of us who are not great at reading code. If this is a final solution, then you are welcome to change this bug.
Comment 12 Andrew Fuerste-Henry 2025-04-14 15:43:42 UTC
I've filed a new bug for my patch to just make the diff visible and will leave this one for a more refined view. I also saw bug 36698 for a nice view of the diff.