Bug 28353 - Regression: Batch item deletion no longer shows which items were not removed
Summary: Regression: Batch item deletion no longer shows which items were not removed
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Tools (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low normal
Assignee: Jonathan Druart
QA Contact: Testopia
URL:
Keywords: Manual
Depends on: 8132
Blocks: 31630
  Show dependency treegraph
 
Reported: 2021-05-13 21:47 UTC by Donna
Modified: 2023-06-08 22:26 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
This restores and improves the messages displayed when batch deleting items (Tools > Catalog > Batch item deletion). The messages displayed are: - "Warning, the following barcodes were not found:", followed by a list of barcodes - "Warning, the following items cannot be deleted:", followed by a list of barcodes
Version(s) released in:
21.11.00,21.05.01,20.11.07
Circulation function:


Attachments
Bug 28353: Display a list of items that cannot be deleted (5.28 KB, patch)
2021-05-18 07:44 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 28353: Display a list of items that cannot be deleted (5.34 KB, patch)
2021-05-29 00:51 UTC, David Nind
Details | Diff | Splinter Review
Bug 28353: Display a list of items that cannot be deleted (5.39 KB, patch)
2021-06-03 10:46 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 Donna 2021-05-13 21:47:00 UTC
In 19.11 when using the batch item deletion tool, the confirmation screen included the total number of items and bibs deleted, and listed the items that could not be deleted, such as if they were checked out, etc.

In 20.05 the user only sees the number of items and bibs deleted and no message that items in the batch were not deleted.  

The results page should show a list of items in the batch that were not able to be deleted.
Comment 1 LeeAnn Nilsson 2021-05-14 20:51:24 UTC
This is a big problem for our libraries.  I do cataloging for multiple libraries and librarians send me large lists of barcodes to delete.  The new feature is not efficient.  When I use this tool, I need the warnings on the results page to say which barcodes were not deleted and why, so I can refer those items back to the librarians to follow up on.  Thanks, LeeAnn
Comment 2 Lisette Scheer 2021-05-14 20:51:52 UTC
(In reply to Donna from comment #0)
 
> The results page should show a list of items in the batch that were not able
> to be deleted.

+1 This would be much more helpful than the current setup. 

Lisette
Comment 3 Jonathan Druart 2021-05-18 07:44:49 UTC
Created attachment 121089 [details] [review]
Bug 28353: Display a list of items that cannot be deleted

We used to display a list of items that cannot be deleted (checked out
or on hold) on the Batch item deletion tool.
With bug 8132 we improve the error handling, but the info is spread in
the table.

This patch adds, at the top of the page, the list of items (barcode)
that cannot be removed.
Comment 4 Jonathan Druart 2021-05-18 07:45:38 UTC
With this patch I get: https://snipboard.io/phjBsA.jpg

Would that work for you?
Comment 5 LeeAnn Nilsson 2021-05-18 18:09:15 UTC
Yes that is helpful.  Thanks
Comment 6 Katrin Fischer 2021-05-24 16:07:18 UTC
(In reply to LeeAnn Nilsson from comment #5)
> Yes that is helpful.  Thanks

Hi Leann, would you be able to sign this off? The sandboxes should work in this case and we just updated the instructions :) 

https://wiki.koha-community.org/wiki/Sandboxes

Also happy to help if you have any questions.
Comment 7 David Nind 2021-05-29 00:51:45 UTC
Created attachment 121504 [details] [review]
Bug 28353: Display a list of items that cannot be deleted

We used to display a list of items that cannot be deleted (checked out
or on hold) on the Batch item deletion tool.
With bug 8132 we improve the error handling, but the info is spread in
the table.

This patch adds, at the top of the page, the list of items (barcode)
that cannot be removed.

Signed-off-by: David Nind <david@davidnind.com>
Comment 8 David Nind 2021-05-29 01:06:14 UTC
Testing notes (using koha-testing-docker).

Test plan:
1. Place a hold for an item and note the barcode
2. Check out an item and note the barcode
3. Go to the batch delete item tool (Tools > Catalog > Batch item deletion) 
   and in the barcode list enter:
   . The barcodes from step 1 and 2
   . An invalid barcode (such as 'XYZ'), 
   . A barcode for an item that can be deleted (= not checked out, not on hold)
   and click 'Continue'
5. The batch item deletion page will show this message:
   . 'Warning, the following barcodes were not found:", followed by a list of barcodes
   (it should list the invalid barcode entered in step 3)
6. Select all the items and click 'Delete selected items'
7. The message says: '1 item(s) deleted'
8. Apply the patch
9. Repeat step 3:
10. The batch item deletion page will show these messages:
    . 'Warning, the following barcodes were not found:", followed by a list of barcodes
    - "Warning, the following items cannot be deleted:", followed by a list of barcodes
11. Click 'Delete selected items", the resulting mesage says '1 item(s) deleted'
12. Sign off!
Comment 9 Katrin Fischer 2021-06-03 10:46:08 UTC
Created attachment 121577 [details] [review]
Bug 28353: Display a list of items that cannot be deleted

We used to display a list of items that cannot be deleted (checked out
or on hold) on the Batch item deletion tool.
With bug 8132 we improve the error handling, but the info is spread in
the table.

This patch adds, at the top of the page, the list of items (barcode)
that cannot be removed.

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 10 Jonathan Druart 2021-06-14 14:22:12 UTC Comment hidden (obsolete)
Comment 11 Jonathan Druart 2021-06-14 14:23:02 UTC
Pushed to master for 21.11, thanks to everybody involved!
Comment 12 Fridolin Somers 2021-06-21 12:30:02 UTC
Pushed to 21.05.x for 21.05.01
Comment 13 Fridolin Somers 2021-06-21 12:30:18 UTC
Pushed to 20.11.x for 20.11.07
Comment 14 Victor Grousset/tuxayo 2021-06-22 00:57:13 UTC
Not backported to oldoldstable (20.05.x). Feel free to ask if it's needed.
Comment 15 LeeAnn Nilsson 2022-09-26 21:26:16 UTC
This has a closed fixed status, but has regressed again.  The only warning given is an unclicked box and when deleting long lists it is hard to notice.  The follow up page use to have a notification stating some barcodes were not deleted, please help.    Thanks, LeeAnn
Comment 16 Katrin Fischer 2022-09-26 21:31:58 UTC
(In reply to LeeAnn Nilsson from comment #15)
> This has a closed fixed status, but has regressed again.  The only warning
> given is an unclicked box and when deleting long lists it is hard to notice.
> The follow up page use to have a notification stating some barcodes were not
> deleted, please help.    Thanks, LeeAnn

Hi LeeAnn, please report this as a new bug. When a bug has been closed and was part of a release, this is always the way to go. With a new bug, the problem will show properly in the release notes and RMaints will be alerted that they need to backport.
Comment 17 Katrin Fischer 2022-09-26 21:32:17 UTC
... you can use the 'Depends on' in the new bug to link to this one!