View | Details | Raw Unified | Return to bug 12631
Collapse All | Expand All

(-)a/tools/inventory.pl (-3 / +10 lines)
Lines 194-204 if ( $uploadbarcodes && length($uploadbarcodes) > 0 ) { Link Here
194
194
195
# now build the result list: inventoried items if requested, and mis-placed items -always-
195
# now build the result list: inventoried items if requested, and mis-placed items -always-
196
my $inventorylist;
196
my $inventorylist;
197
my $wrongplacelist;
197
my @items_with_problems;
198
my @items_with_problems;
198
if ( $markseen or $op ) {
199
if ( $markseen or $op ) {
199
    # retrieve all items in this range.
200
    # retrieve all items in this range.
200
    my $totalrecords;
201
    my $totalrecords;
201
    ($inventorylist, $totalrecords) = GetItemsForInventory($minlocation, $maxlocation, $location, $itemtype, $ignoreissued, '', $branchcode, $branch, 0, undef , $staton);
202
203
    # We use datelastseen only when comparing the results to the barcode file.
204
    my $paramdatelastseen = ($compareinv2barcd) ? $datelastseen : '';
205
    ($inventorylist, $totalrecords) = GetItemsForInventory($minlocation, $maxlocation, $location, $itemtype, $ignoreissued, $paramdatelastseen, $branchcode, $branch, 0, undef, $staton);
206
207
    # For the items that may be marked as "wrong place", we only check the location (callnumbers, location and branch)
208
    ($wrongplacelist, $totalrecords) = GetItemsForInventory($minlocation, $maxlocation, $location, undef, undef, undef, $branchcode, $branch, 0, undef, undef);
209
202
}
210
}
203
211
204
# If "compare barcodes list to results" has been checked, we want to alert for missing items
212
# If "compare barcodes list to results" has been checked, we want to alert for missing items
Lines 248-254 foreach my $item ( @scanned_items ) { Link Here
248
        $item->{problem} = 'changestatus';
256
        $item->{problem} = 'changestatus';
249
        push @items_with_problems, { %$item };
257
        push @items_with_problems, { %$item };
250
    }
258
    }
251
    if (none { $item->{barcode} eq $_->{barcode} && !$_->{'onloan'} } @$inventorylist) {
259
    if (none { $item->{barcode} eq $_->{barcode} && !$_->{'onloan'} } @$wrongplacelist) {
252
        $item->{problem} = 'wrongplace';
260
        $item->{problem} = 'wrongplace';
253
        push @items_with_problems, { %$item };
261
        push @items_with_problems, { %$item };
254
    }
262
    }
255
- 

Return to bug 12631