Bug 30725 - BatchDeleteItem job param named wrongly
Summary: BatchDeleteItem job param named wrongly
Status: CLOSED WONTFIX
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low trivial (vote)
Assignee: Fridolin Somers
QA Contact: Testopia
URL:
Keywords:
Depends on: 28445 30710
Blocks:
  Show dependency treegraph
 
Reported: 2022-05-10 14:52 UTC by Tomás Cohen Arazi
Modified: 2023-12-28 20:42 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 30725: Rename BatchDeleteItem job param from record_ids to item_ids (5.04 KB, patch)
2022-05-19 04:05 UTC, Fridolin Somers
Details | Diff | Splinter Review
Bug 30725: Rename BatchDeleteItem job param from record_ids to item_ids (5.09 KB, patch)
2022-05-29 00:26 UTC, David Nind
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Tomás Cohen Arazi 2022-05-10 14:52:09 UTC
It is clearly a copy and paste error, but the parameter is called 'record_ids' when it should be 'item_ids'.
Comment 1 Fridolin Somers 2022-05-19 04:05:52 UTC
Created attachment 135179 [details] [review]
Bug 30725: Rename BatchDeleteItem job param from record_ids to item_ids

It is clearly a copy and paste error, but the parameter is called 'record_ids' when it should be 'item_ids'.

Test plan :
Run prove t/db_dependent/Koha/BackgroundJobs/BatchDeleteItem.t
Perform a batch items deletion via staff interface
Comment 2 Fridolin Somers 2022-05-19 04:07:06 UTC
Then do the same with BatchUpdateItem I bet.
Comment 3 David Nind 2022-05-29 00:26:46 UTC
Created attachment 135442 [details] [review]
Bug 30725: Rename BatchDeleteItem job param from record_ids to item_ids

It is clearly a copy and paste error, but the parameter is called 'record_ids' when it should be 'item_ids'.

Test plan :
Run prove t/db_dependent/Koha/BackgroundJobs/BatchDeleteItem.t
Perform a batch items deletion via staff interface

Signed-off-by: David Nind <david@davidnind.com>
Comment 4 David Nind 2022-05-29 00:27:42 UTC
Testing notes using koha-testing-docker:

- Before applying the patch, I tested Tools > Batch item deletion using these item barcodes for Intermediate Perl (http://127.0.0.1:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=126):
39999000005134
39999000005110
39999000005158
39999000005097
==> Items successfully deleted.

- After applying the patch, I tested with these barcodes for Perl template toolkit (http://127.0.0.1:8081/cgi-bin/koha/catalogue/detail.pl?biblionumber=255):
39999000011111
39999000011135
39999000011074
39999000011098
==> Items successfully deleted.
Comment 5 Jonathan Druart 2022-05-31 08:41:35 UTC
I was using "record" as a generic term, not related to bibliographic records.
If you really want to adjust it, then you should fix BatchUpdateItem as well.
Comment 6 Fridolin Somers 2023-03-29 08:22:39 UTC
(In reply to Jonathan Druart from comment #5)
> I was using "record" as a generic term, not related to bibliographic records.
> If you really want to adjust it, then you should fix BatchUpdateItem as well.

Fair point.
Even "item" can be considered as a generic term for an object in a list.

It works, we should not touch it.