From 0133cb540ffefd1ce7730f0d671d12df44840ab3 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 6 May 2022 20:10:54 +0000 Subject: [PATCH] Bug 30668: Do not record itme location updates in cataloguing log To test: 1 - Set a rule in UpdateItemLocationOnCheckin 2 - Enable cataloguing log 3 - Check in an item that will trigger a change 4 - Check the modification log for item - there is a cataloguing entry 5 - Apply patch 6 - Repeat 7 - No log! --- C4/Circulation.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/C4/Circulation.pm b/C4/Circulation.pm index 2ae081d6b1..d312961478 100644 --- a/C4/Circulation.pm +++ b/C4/Circulation.pm @@ -2110,7 +2110,7 @@ sub AddReturn { (!defined $item->location && $update_loc_rules->{_ALL_} ne "") ) { $messages->{'ItemLocationUpdated'} = { from => $item->location, to => $update_loc_rules->{_ALL_} }; - $item->location($update_loc_rules->{_ALL_})->store({ skip_record_index => 1, skip_holds_queue => 1}); + $item->location($update_loc_rules->{_ALL_})->store({ log_action => 0, skip_record_index => 1, skip_holds_queue => 1}); } } else { @@ -2119,7 +2119,7 @@ sub AddReturn { if ( $update_loc_rules->{$key} eq '_BLANK_') { $update_loc_rules->{$key} = '' ;} if ( ($item->location eq $key && $item->location ne $update_loc_rules->{$key}) || ($key eq '_BLANK_' && $item->location eq '' && $update_loc_rules->{$key} ne '') ) { $messages->{'ItemLocationUpdated'} = { from => $item->location, to => $update_loc_rules->{$key} }; - $item->location($update_loc_rules->{$key})->store({ skip_record_index => 1, skip_holds_queue => 1}); + $item->location($update_loc_rules->{$key})->store({ log_action => 0, skip_record_index => 1, skip_holds_queue => 1}); last; } } -- 2.30.2