Bugzilla – Attachment 23918 Details for
Bug 11473
View log template has malformed conditionals, and logging info incorrect/inconsistent/unexpected
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11473 - add 'biblio' and 'item' to cataloguing logging info
Bug-11473---add-biblio-and-item-to-cataloguing-log.patch (text/plain), 3.90 KB, created by
David Cook
on 2014-01-06 04:13:20 UTC
(
hide
)
Description:
Bug 11473 - add 'biblio' and 'item' to cataloguing logging info
Filename:
MIME Type:
Creator:
David Cook
Created:
2014-01-06 04:13:20 UTC
Size:
3.90 KB
patch
obsolete
>From 1969ee8353ecdeb8c1f5901b241fde3184a0e444 Mon Sep 17 00:00:00 2001 >From: David Cook <dcook@prosentient.com.au> >Date: Mon, 6 Jan 2014 15:01:10 +1100 >Subject: [PATCH] Bug 11473 - add 'biblio' and 'item' to cataloguing logging > info > >This patch adds the words 'biblio' and 'item' to the 'info' >of the cataloguing logs which were missing them (such as biblio >delete, biblio mod, item mod, upload cover image). > >This patch also adds 'authority' for authority mod. > >_TEST PLAN_ > >Before applying: >1) Create/view mods for items, biblios, and authorities. >2) Create/view biblio deletion >3) Create/view upload cover image log >4) Note that none of these contain the words 'biblio','item',or >'authority' in their "Info" columns. > >Apply patch. > >5) Repeat steps 1-3 >6) Note that the new logs contain 'biblio','item', and 'authority' >in their "Info" column, while the past ones don't. >7) Note also that 'biblio' and 'item' will have 'Biblio' and 'Item' >appear in their "Object" column for the new logs >--- > C4/AuthoritiesMarc.pm | 2 +- > C4/Biblio.pm | 4 ++-- > C4/Items.pm | 2 +- > tools/upload-cover-image.pl | 2 +- > 4 files changed, 5 insertions(+), 5 deletions(-) > >diff --git a/C4/AuthoritiesMarc.pm b/C4/AuthoritiesMarc.pm >index a22190b..f7eb122 100644 >--- a/C4/AuthoritiesMarc.pm >+++ b/C4/AuthoritiesMarc.pm >@@ -739,7 +739,7 @@ sub ModAuthority { > "VALUES (?,?)"; > $dbh->do($sqlinsert,undef,($authid,0)); > } >- logaction( "AUTHORITIES", "MODIFY", $authid, "BEFORE=>" . $oldrecord->as_formatted ) if C4::Context->preference("AuthoritiesLog"); >+ logaction( "AUTHORITIES", "MODIFY", $authid, "authority BEFORE=>" . $oldrecord->as_formatted ) if C4::Context->preference("AuthoritiesLog"); > return $authid; > } > >diff --git a/C4/Biblio.pm b/C4/Biblio.pm >index 71e9366..dc40d68 100644 >--- a/C4/Biblio.pm >+++ b/C4/Biblio.pm >@@ -316,7 +316,7 @@ sub ModBiblio { > > if ( C4::Context->preference("CataloguingLog") ) { > my $newrecord = GetMarcBiblio($biblionumber); >- logaction( "CATALOGUING", "MODIFY", $biblionumber, "BEFORE=>" . $newrecord->as_formatted ); >+ logaction( "CATALOGUING", "MODIFY", $biblionumber, "biblio BEFORE=>" . $newrecord->as_formatted ); > } > > # Cleaning up invalid fields must be done early or SetUTF8Flag is liable to >@@ -470,7 +470,7 @@ sub DelBiblio { > # from being generated by _koha_delete_biblioitems > $error = _koha_delete_biblio( $dbh, $biblionumber ); > >- logaction( "CATALOGUING", "DELETE", $biblionumber, "" ) if C4::Context->preference("CataloguingLog"); >+ logaction( "CATALOGUING", "DELETE", $biblionumber, "biblio" ) if C4::Context->preference("CataloguingLog"); > > return; > } >diff --git a/C4/Items.pm b/C4/Items.pm >index 2b83ffc..5680db7 100644 >--- a/C4/Items.pm >+++ b/C4/Items.pm >@@ -583,7 +583,7 @@ sub ModItem { > # item status is possible > ModZebra( $biblionumber, "specialUpdate", "biblioserver" ); > >- logaction("CATALOGUING", "MODIFY", $itemnumber, Dumper($item)) if C4::Context->preference("CataloguingLog"); >+ logaction("CATALOGUING", "MODIFY", $itemnumber, "item ".Dumper($item)) if C4::Context->preference("CataloguingLog"); > } > > =head2 ModItemTransfer >diff --git a/tools/upload-cover-image.pl b/tools/upload-cover-image.pl >index b85a81a..8ca419c 100755 >--- a/tools/upload-cover-image.pl >+++ b/tools/upload-cover-image.pl >@@ -151,7 +151,7 @@ if ($fileID) { > $filename =~ s/^\s+//; > $filename =~ s/\s+$//; > if (C4::Context->preference("CataloguingLog")) { >- logaction('CATALOGUING', 'MODIFY', $biblionumber, "cover image: $filename"); >+ logaction('CATALOGUING', 'MODIFY', $biblionumber, "biblio cover image: $filename"); > } > my $srcimage = GD::Image->new("$dir/$filename"); > if ( defined $srcimage ) { >-- >1.7.7.4
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 11473
:
23915
|
23916
|
23917
|
23918
|
23922
|
23923
|
23924
|
23925
|
24152
|
24153
|
24154
|
24155