Bugzilla – Attachment 40118 Details for
Bug 14001
Inventory has bad $_ references
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14001 - Inventory has bad $_ references
Bug-14001---Inventory-has-bad--references.patch (text/plain), 2.34 KB, created by
Indranil Das Gupta
on 2015-06-14 06:14:14 UTC
(
hide
)
Description:
Bug 14001 - Inventory has bad $_ references
Filename:
MIME Type:
Creator:
Indranil Das Gupta
Created:
2015-06-14 06:14:14 UTC
Size:
2.34 KB
patch
obsolete
>From 97ca042f217a65aa404cf6415a6d1ed3457d2556 Mon Sep 17 00:00:00 2001 >From: Mark Tompsett <mtompset@hotmail.com> >Date: Wed, 15 Apr 2015 12:33:29 -0400 >Subject: [PATCH] Bug 14001 - Inventory has bad $_ references > >After receiving an error while attempt a simple inventory run, >Two lines were changed from: > ...$_->... >to > ...$item->... >since the loop variable is $item. And $_ is not set to the >expected hash reference, when there is a loop variable. > >This also helps explain the "Why are there blank dates on my >last seen field?" problem that has been mentioned by users. > >TEST PLAN >--------- > 1) Apply this patch after a reset to master. > 2) Log in to staff client > 3) Add one item via z39.50, setting barcode to a known value (BARCODE1) > 4) Wait for the reindex > 5) Home -> Tools -> Inventory/Stocktaking > 6) Browse for a file with the barcode in it > 7) Set the library dropdown to the library branch of the added item. > 8) Check 'Compare barcodes list to results:' > 9) Click 'Submit' > -- This should not die under plack. > This should not generate blank last seen dates. > The last seen dates should be as expected. >10) run koha qa test tools >11) Confirm the two change point correspond to the two change points > in the patch which shall not be pushed to master. > >The test result comply with expected outcome outlined in test plan. > >Signed-off-by: Indranil Das Gupta (L2C2 Technologies) <indradg@gmail.com> >--- > tools/inventory.pl | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/tools/inventory.pl b/tools/inventory.pl >index 63e1da1..976d956 100755 >--- a/tools/inventory.pl >+++ b/tools/inventory.pl >@@ -279,7 +279,7 @@ if ( $compareinv2barcd ) { > my $dls = output_pref( { dt => dt_from_string( $datelastseen ), > dateformat => 'iso' } ); > foreach my $item ( @$inventorylist ) { >- my $cdls = output_pref( { dt => dt_from_string( $_->{datelastseen} ), >+ my $cdls = output_pref( { dt => dt_from_string( $item->{datelastseen} ), > dateformat => 'iso' } ); > if ( $cdls lt $dls ) { > $item->{problem} = 'missingitem'; >@@ -326,7 +326,7 @@ foreach my $item ( @scanned_items ) { > } > > # Modify date last seen for scanned items >- ModDateLastSeen($_->{'itemnumber'}); >+ ModDateLastSeen($item->{'itemnumber'}); > $moddatecount++; > } > >-- >1.9.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 14001
:
37910
|
37924
|
39641
|
39642
|
39643
|
40117
|
40118
|
40164