Bug 11473: (follow-up) ensure link to item is construct correctly

This patch adjusts the check on action_logs.info to better detect
if the event concerns an item.  This fixes a problem where the links
from log entries on item modifications would, if followed, result
in internal server errors.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
Galen Charlton 2014-01-17 06:04:37 +00:00
parent 5885077fbb
commit 490e38069c

View file

@ -115,7 +115,7 @@ if ($do_it) {
@data=@$results;
my $total = scalar @data;
foreach my $result (@data){
if ($result->{'info'} eq 'item'||$result->{module} eq "CIRCULATION"){
if (substr($result->{'info'}, 0, 4) eq 'item' || $result->{module} eq "CIRCULATION"){
# get item information so we can create a working link
my $itemnumber=$result->{'object'};
$itemnumber=$result->{'info'} if ($result->{module} eq "CIRCULATION");