Lines 123-128
for my $authvfield (@$statuses) {
Link Here
|
123 |
} |
123 |
} |
124 |
} |
124 |
} |
125 |
|
125 |
|
|
|
126 |
my $report_lost_items; |
127 |
if ( defined $input->param('ReportLostItems') && $input->param('ReportLostItems') eq 'on' ) { |
128 |
$report_lost_items = "1"; |
129 |
} |
130 |
|
126 |
# if there's a list of not for loans types selected use it rather than |
131 |
# if there's a list of not for loans types selected use it rather than |
127 |
# the full set. |
132 |
# the full set. |
128 |
@notforloans = @{$staton->{'items.notforloan'}} if defined $staton->{'items.notforloan'} and scalar @{$staton->{'items.notforloan'}} > 0; |
133 |
@notforloans = @{$staton->{'items.notforloan'}} if defined $staton->{'items.notforloan'} and scalar @{$staton->{'items.notforloan'}} > 0; |
Lines 162-167
my $results = {};
Link Here
|
162 |
my @scanned_items; |
167 |
my @scanned_items; |
163 |
my @errorloop; |
168 |
my @errorloop; |
164 |
my $moddatecount = 0; |
169 |
my $moddatecount = 0; |
|
|
170 |
my @lost_items; |
165 |
if ( $op eq 'cud-inventory' |
171 |
if ( $op eq 'cud-inventory' |
166 |
&& ( ( $uploadbarcodes && length($uploadbarcodes) > 0 ) || ( $barcodelist && length($barcodelist) > 0 ) ) ) |
172 |
&& ( ( $uploadbarcodes && length($uploadbarcodes) > 0 ) || ( $barcodelist && length($barcodelist) > 0 ) ) ) |
167 |
{ |
173 |
{ |
Lines 225-230
if ( $op eq 'cud-inventory'
Link Here
|
225 |
next; |
231 |
next; |
226 |
} |
232 |
} |
227 |
# Modify date last seen for scanned items, remove lost status |
233 |
# Modify date last seen for scanned items, remove lost status |
|
|
234 |
if ( $item->unblessed->{itemlost} ) { |
235 |
push @lost_items, $barcode; |
236 |
} |
228 |
$item->set({ itemlost => 0, datelastseen => $date_dt })->store; |
237 |
$item->set({ itemlost => 0, datelastseen => $date_dt })->store; |
229 |
my $item_unblessed = $item->unblessed; |
238 |
my $item_unblessed = $item->unblessed; |
230 |
$moddatecount++; |
239 |
$moddatecount++; |
Lines 335-340
for ( my $i = 0; $i < @scanned_items; $i++ ) {
Link Here
|
335 |
$item->{problems}->{wrongplace} = 1; |
344 |
$item->{problems}->{wrongplace} = 1; |
336 |
additemtoresults( $item, $results ); |
345 |
additemtoresults( $item, $results ); |
337 |
} |
346 |
} |
|
|
347 |
|
348 |
# Report a lost item if asked |
349 |
if ( @lost_items && ( scalar grep { $_ eq $item->{barcode} } @lost_items ) && $report_lost_items ) { |
350 |
$item->{problems}->{lost} = 1; |
351 |
additemtoresults( $item, $results ); |
352 |
} |
338 |
} |
353 |
} |
339 |
|
354 |
|
340 |
# Compare barcodes with inventory list, report no_barcode and not_scanned. |
355 |
# Compare barcodes with inventory list, report no_barcode and not_scanned. |
Lines 418-425
if (defined $input->param('CSVexport') && $input->param('CSVexport') eq 'on'){
Link Here
|
418 |
$errstr .= "checked out,"; |
433 |
$errstr .= "checked out,"; |
419 |
} elsif( $key eq 'out_of_order' ) { |
434 |
} elsif( $key eq 'out_of_order' ) { |
420 |
$errstr .= "shelved out of order,"; |
435 |
$errstr .= "shelved out of order,"; |
|
|
436 |
} elsif ( $key eq 'lost' ) { |
437 |
$errstr .= "item was lost"; |
421 |
} |
438 |
} |
422 |
} |
439 |
} |
|
|
440 |
|
423 |
$errstr =~ s/,$//; |
441 |
$errstr =~ s/,$//; |
424 |
push @line, $errstr; |
442 |
push @line, $errstr; |
425 |
$csv->combine(@line); |
443 |
$csv->combine(@line); |
426 |
- |
|
|