Summary: | Batch modification of checked out and lost items checks them in | ||
---|---|---|---|
Product: | Koha | Reporter: | Owen Leonard <oleonard> |
Component: | Tools | Assignee: | Jonathan Druart <jonathan.druart> |
Status: | CLOSED FIXED | QA Contact: | Testopia <testopia> |
Severity: | critical | ||
Priority: | P5 - low | CC: | chris, gaetan.boisson, hector.hecaxmmx, jonathan.druart, liz, nengard, tomascohen |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | Trivial patch | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: | Circulation function: | ||
Bug Depends on: | 5533 | ||
Bug Blocks: | |||
Attachments: |
Bug 12311: Do not return a lost item if modified in a batch
[SIGNED-OFF]Bug 12311: Do not return a lost item if modified in a batch [PASSED QA] Bug 12311: Do not return a lost item if modified in a batch |
Description
Owen Leonard
2014-05-23 16:38:29 UTC
It seems that this behavior exists for a while. There was a discussion on bug 5533 and I am not sure how we should fix this bug. bug 5533 comment 2: "Another update - if you mark items lost using the batch edit tool the lost items remain on the patron's record as checked out instead of being removed." I am sure it's easy to fix, but I would like to know the different use cases to take into account. The code is: 200 if ( my $item = ModItemFromMarc( $localmarcitem, $itemdata->{biblionumber}, $itemnumber ) ) { 201 LostItem($itemnumber, 'MARK RETURNED') if $item->{itemlost}; 202 } I need help on this one to provide a fix. ping? Is this really critical? I think yes. If it's true it unexpectedly checks items in, then that's really bad. I think the problem might be that Koha ususally wants to return an item if it's set to lost... and only the longoverdue script manages to avoid this? What about: only trigger the check in, if the lost status is changed in the batch edit? Created attachment 42554 [details] [review] Bug 12311: Do not return a lost item if modified in a batch If a item is lost and issued, and you modify it in a batch, the item will be marked as returned. It should only be returned if the item is marked as lost. Test plan: 1/ Check an item out and mark it as lost 2/ Edit it in a batch (tools/batchMod.pl) and edit a field (notes for instance) 3/ The item should still be issued to the patron 4/ Edit it in a batch and edit the lost value, marked it as not lost 5/ The item should still be issued to the patron 6/ Edit it in a batch and edit the lost value, marked it as lost 7/ The item should have been returned. Created attachment 42796 [details] [review] [SIGNED-OFF]Bug 12311: Do not return a lost item if modified in a batch If a item is lost and issued, and you modify it in a batch, the item will be marked as returned. It should only be returned if the item is marked as lost. Test plan: 1/ Check an item out and mark it as lost 2/ Edit it in a batch (tools/batchMod.pl) and edit a field (notes for instance) 3/ The item should still be issued to the patron 4/ Edit it in a batch and edit the lost value, marked it as not lost 5/ The item should still be issued to the patron 6/ Edit it in a batch and edit the lost value, marked it as lost 7/ The item should have been returned. Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Works as advertised. Just one comment, lost status can be changed only if you change default framework to another framework then edit the item. If you change it in Item menu at left side of screen this will remove the item from patron’s checkouts and patron charged for lost item. Created attachment 42961 [details] [review] [PASSED QA] Bug 12311: Do not return a lost item if modified in a batch If a item is lost and issued, and you modify it in a batch, the item will be marked as returned. It should only be returned if the item is marked as lost. Test plan: 1/ Check an item out and mark it as lost 2/ Edit it in a batch (tools/batchMod.pl) and edit a field (notes for instance) 3/ The item should still be issued to the patron 4/ Edit it in a batch and edit the lost value, marked it as not lost 5/ The item should still be issued to the patron 6/ Edit it in a batch and edit the lost value, marked it as lost 7/ The item should have been returned. Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com> Works as advertised. Just one comment, lost status can be changed only if you change default framework to another framework then edit the item. If you change it in Item menu at left side of screen this will remove the item from patron’s checkouts and patron charged for lost item. Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> For testing purposes the lost item field can be set to visible in the framework used. That will allow changing it without returning it at the same time. The other option is using the longoverdues.pl script. Patch pushed to master. Thanks Jonathan! Pushed to 3.20.x will be in 3.20.5 Pushed to 3.18.x, is in 3.18.12. |