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

(-)a/C4/Items.pm (-1 / +4 lines)
Lines 1112-1118 sub GetItemsForInventory { Link Here
1112
            if ($f and $sf) {
1112
            if ($f and $sf) {
1113
                # We replace the code with it's description
1113
                # We replace the code with it's description
1114
                my $authvals = C4::Koha::GetKohaAuthorisedValuesFromField($f, $sf, $row->{'frameworkcode'});
1114
                my $authvals = C4::Koha::GetKohaAuthorisedValuesFromField($f, $sf, $row->{'frameworkcode'});
1115
                $row->{$_} = $authvals->{$row->{$_}} if defined $authvals->{$row->{$_}};
1115
                if ( defined $authvals->{ $row->{$_} } ) {
1116
                    $row->{"$_-code"} = $row->{$_};
1117
                    $row->{$_} = $authvals->{ $row->{$_} };
1118
                }
1116
            }
1119
            }
1117
        }
1120
        }
1118
        push @results, $row;
1121
        push @results, $row;
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/inventory.tt (+15 lines)
Lines 163-168 $(document).ready(function(){ Link Here
163
            </fieldset>
163
            </fieldset>
164
        [% END %]
164
        [% END %]
165
165
166
        [% IF (authorised_values) %]
167
            <fieldset class="rows">
168
                <legend>If comparing barcodes list to results, assume items with the following locations should not have been scanned</legend>
169
170
                <ol>
171
                    [% FOREACH value IN authorised_values %]
172
                        <li>
173
                            <label for="ignore_locations">[% value.lib %]</label>
174
                            <input type="checkbox" name="ignore_locations" value="[% value.authorised_value %]">
175
                        </li>
176
                    [% END %]
177
                </ol>
178
            </fieldset>
179
        [% END %]
180
166
        <fieldset class="rows wide">
181
        <fieldset class="rows wide">
167
          <ol>
182
          <ol>
168
        <li><label for="datelastseen">Inventory date:</label>
183
        <li><label for="datelastseen">Inventory date:</label>
(-)a/tools/inventory.pl (-4 / +6 lines)
Lines 37-43 use C4::Circulation; Link Here
37
use C4::Reports::Guided;    #_get_column_defs
37
use C4::Reports::Guided;    #_get_column_defs
38
use C4::Charset;
38
use C4::Charset;
39
use Koha::DateUtils;
39
use Koha::DateUtils;
40
use List::MoreUtils qw( none );
40
use List::MoreUtils qw( none any );
41
41
42
42
43
my $minlocation=$input->param('minlocation') || '';
43
my $minlocation=$input->param('minlocation') || '';
Lines 54-59 my $branch = $input->param('branch'); Link Here
54
my $op         = $input->param('op');
54
my $op         = $input->param('op');
55
my $compareinv2barcd = $input->param('compareinv2barcd');
55
my $compareinv2barcd = $input->param('compareinv2barcd');
56
my $out_of_order = $input->param('out_of_order');
56
my $out_of_order = $input->param('out_of_order');
57
my @ignore_locations = $input->param('ignore_locations');
57
58
58
my ( $template, $borrowernumber, $cookie ) = get_template_and_user(
59
my ( $template, $borrowernumber, $cookie ) = get_template_and_user(
59
    {   template_name   => "tools/inventory.tt",
60
    {   template_name   => "tools/inventory.tt",
Lines 285-292 if ( $compareinv2barcd ) { Link Here
285
    for my $should_be_scanned ( @$inventorylist ) {
286
    for my $should_be_scanned ( @$inventorylist ) {
286
        my $barcode = $should_be_scanned->{barcode};
287
        my $barcode = $should_be_scanned->{barcode};
287
        unless ( grep /^$barcode$/, @scanned_barcodes ) {
288
        unless ( grep /^$barcode$/, @scanned_barcodes ) {
288
            $should_be_scanned->{problem} = 'not_scanned';
289
            unless ( any { $should_be_scanned->{'location-code'} eq $_ } @ignore_locations ) {
289
            push @items_with_problems, { %$should_be_scanned };
290
                $should_be_scanned->{problem} = 'not_scanned';
291
                push @items_with_problems, { %$should_be_scanned };
292
            }
290
        }
293
        }
291
    }
294
    }
292
}
295
}
293
- 

Return to bug 11405