Bug 10005 - inventory checks items in without warning
Summary: inventory checks items in without warning
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Tools (show other bugs)
Version: master
Hardware: All All
: P5 - low major (vote)
Assignee: Jonathan Druart
QA Contact:
URL:
Whiteboard:
Keywords:
: 12327 (view as bug list)
Depends on:
Blocks:
 
Reported: 2013-04-08 20:26 UTC by Nicole C. Engard
Modified: 2016-06-21 21:38 UTC (History)
8 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 10005: Inventory - Add an option to not check in items (3.45 KB, patch)
2015-07-14 14:06 UTC, Jonathan Druart
Details | Diff | Splinter Review
[SIGNED OFF] Bug 10005: Inventory - Add an option to not check in items (3.51 KB, patch)
2015-08-08 14:34 UTC, Jason Robb
Details | Diff | Splinter Review
[PASSED QA] Bug 10005: Inventory - Add an option to not check in items (3.63 KB, patch)
2015-09-07 21:30 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Nicole C. Engard 2013-04-08 20:26:55 UTC
I got this via email:

----------

This is my first time doing inventory in KOHA at our high school. I've done it at our middle school before but we always cut off book circulation before doing inventory. At the high school, our collection is so large that we have to do inventory earlier and need to continue circulating through the process. We started the process fine but ran into a problem today when I was uploading our fiction barcodes into KOHA to see the dates last seen. When I uploaded them into the Inventory/Stocktaking area, I got a list of barcodes with the message "item was on loan. It was returned before marked as seen." When I looked up the barcodes, they were all books that were checked out during the day today. When I went back into those patron accts, their checkouts had been erased.

----------

So, I think the problem here is that there is no warning or way to tell Koha to not check the items in, it just checks them in and that's that.  We need the inventory tool to either ask before running if it should check things in (an enhancement) or we need a warning saying that it will check things in (a temp fix for the bug).
Comment 1 Jonathan Druart 2015-07-14 14:06:59 UTC Comment hidden (obsolete)
Comment 2 Jonathan Druart 2015-07-14 14:07:20 UTC
*** Bug 12327 has been marked as a duplicate of this bug. ***
Comment 3 M. Tompsett 2015-07-18 20:38:07 UTC
Comment on attachment 40990 [details] [review]
Bug 10005: Inventory - Add an option to not check in items

Review of attachment 40990 [details] [review]:
-----------------------------------------------------------------

::: tools/inventory.pl
@@ +218,5 @@
> +                        if ($doreturn){
> +                            push @errorloop, {'barcode'=>$barcode,'ERR_ONLOAN_RET'=>1}
> +                        } else {
> +                            push @errorloop, {'barcode'=>$barcode,'ERR_ONLOAN_NOT_RET'=>1}
> +                        }

This unless statement merely doesn't check them in. Where's the warning as requested in comment #1?
Comment 4 Jonathan Druart 2015-08-04 06:43:51 UTC
(In reply to M. Tompsett from comment #3)
> Comment on attachment 40990 [details] [review] [review]
> Bug 10005: Inventory - Add an option to not check in items
> 
> Review of attachment 40990 [details] [review] [review]:
> -----------------------------------------------------------------
> 
> ::: tools/inventory.pl
> @@ +218,5 @@
> > +                        if ($doreturn){
> > +                            push @errorloop, {'barcode'=>$barcode,'ERR_ONLOAN_RET'=>1}
> > +                        } else {
> > +                            push @errorloop, {'barcode'=>$barcode,'ERR_ONLOAN_NOT_RET'=>1}
> > +                        }
> 
> This unless statement merely doesn't check them in. Where's the warning as
> requested in comment #1?

I don't get it.
Did you test the patch?

From the description;
"I think the problem here is that there is no warning or way to tell Koha to not check the items in"
I have chosen the second way and added a checkbox.
Comment 5 Jason Robb 2015-08-08 14:34:54 UTC Comment hidden (obsolete)
Comment 6 Katrin Fischer 2015-09-07 21:26:51 UTC
I've added a missing </li>.
The patch would be a little nicer, if there was a nice message for 'already on loan' - but this works, as it no longer checks the item in.
Comment 7 Katrin Fischer 2015-09-07 21:30:28 UTC
Created attachment 42443 [details] [review]
[PASSED QA] Bug 10005: Inventory - Add an option to not check in items

The inventory tools automatically check in items, this patch adds it as
an option.

Test plan:
1/ Check an item out, fill a file with its barcode, and use this file in
the inventory tools.
2/ Check the new checkbox and confirm that the item is not checked in
3/ Repeat again and don't check it, the behavior should be the same as before
this patch.

Signed-off-by: Jason Robb <jrobb@sekls.org>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Added a missing </li>.
Patch works as expected.
Comment 8 Tomás Cohen Arazi 2015-09-16 14:08:24 UTC
Patch pushed to master.

Thanks Jonathan!
Comment 9 Chris Cormack 2015-09-22 17:57:32 UTC
Pushed to 3.20.x will be in 3.20.4
Comment 10 Sophie MEYNIEUX 2015-11-20 10:04:53 UTC
Could this one be in 3.18 ? Because it could result in severe loss of data.
Comment 11 Katrin Fischer 2015-11-20 12:36:30 UTC
(In reply to Sophie MEYNIEUX from comment #10)
> Could this one be in 3.18 ? Because it could result in severe loss of data.

Adding Liz to the CC list :)
Comment 12 Sophie MEYNIEUX 2015-11-20 15:00:26 UTC
Sorry I didn't check before, but apparently it is in 3.18.11