Bugzilla – Attachment 195035 Details for
Bug 40135
Record diff in action logs when modifying a bibliographic record
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40135: Fix info column prefix for biblio MODIFY logs
b98b622.patch (text/plain), 1.61 KB, created by
Martin Renvoize (ashimema)
on 2026-03-09 21:49:07 UTC
(
hide
)
Description:
Bug 40135: Fix info column prefix for biblio MODIFY logs
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2026-03-09 21:49:07 UTC
Size:
1.61 KB
patch
obsolete
>From b98b62231ac4b9ccc14c0d159a8d1ef46e785127 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@openfifth.co.uk> >Date: Mon, 9 Mar 2026 21:46:09 +0000 >Subject: [PATCH] Bug 40135: Fix info column prefix for biblio MODIFY logs > >The MODIFY path in logaction received the updated biblio as a plain >hashref (not a Koha::Object), so the info column was populated with >raw Dumper output instead of the expected "biblio ..." prefix. > >This broke two things: the 'Modification Log' link from the bib record >sidebar (which filters on info LIKE 'biblio%'), and the Object column >in the log viewer (which detects biblio entries via info.substr(0,6)). > >Following the same pattern as the Koha::Item MODIFY special case, add >a parallel branch for CATALOGUING MODIFY with a hashref \$infos that >sets the info column to "biblio " . Dumper(\$original). This restores >backward-compatible detection while keeping the diff column correctly >populated from the before/after hashrefs (including _marc changes). >--- > C4/Log.pm | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > >diff --git a/C4/Log.pm b/C4/Log.pm >index 24c9b949311..59ef3a4f4c6 100644 >--- a/C4/Log.pm >+++ b/C4/Log.pm >@@ -96,7 +96,11 @@ sub logaction { > $updated = $infos; > if ( ref $infos eq 'HASH' ) { > local $Data::Dumper::Sortkeys = 1; >- $infos = Dumper($updated); >+ if ( $modulename eq 'CATALOGUING' && $actionname eq 'MODIFY' ) { >+ $infos = "biblio " . Dumper( ref $original eq 'HASH' ? $original : {} ); >+ } else { >+ $infos = Dumper($updated); >+ } > } > } > >-- >2.53.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 40135
:
194785
|
194941
|
195009
|
195010
|
195033
|
195034
| 195035