Koha/tools
Jonathan Druart 83b364ec56 Bug 20462: Ensure batch item deletion will not delete the same item twice
This has been done on bug 9509 when barcodes are scaned, but not when using a text file.

Test plan (stolen from Barton on the bug report):
1) Create a text file containing duplicate barcodes

Here's a quick way to do that, substitute INSTANCE for the instance name of your test server:

sudo koha-mysql INSTANCE <<< "select barcode from items where barcode is not null limit 3" | sed '1d;p' > /tmp/dup_barcodes.txt

2) Go to Home › Tools › Batch item deletion
3) Click 'Choose File', select the file you created in step 1.
4) Click 'Continue'
5) Note that duplicate items appear in the list of items to batch delete
6) Check 'Delete records if no items remain'
7) This will trigger a software error

Note that entering the barcodes via the 'scan items one by one' text box removes duplicates in the list, so this only causes problems when uploading a file.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2018-04-02 18:07:44 -03:00
..
csv-profiles
quotes Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
ajax-inventory.pl
automatic_item_modification_by_age.pl
background-job-progress.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
batch_delete_records.pl Bug 18149: Move CountUsage calls to Koha namespace 2017-09-19 11:47:32 -03:00
batch_record_modification.pl Bug 19040: Refactor GetMarcBiblio parameters 2017-08-25 10:23:42 -03:00
batch_records_ajax.pl Bug 19937: Silence warnings t/db_dependent/www/batch.t 2018-01-15 12:22:16 -03:00
batchMod.pl Bug 20462: Ensure batch item deletion will not delete the same item twice 2018-04-02 18:07:44 -03:00
cleanborrowers.pl Bug 16966: move parameters to hashref 2017-03-03 17:20:05 +00:00
copy-holidays.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
csv-profiles.pl Bug 8612: [Follow-up] Make usage and type different columns in table 2017-06-05 12:02:08 -03:00
exceptionHolidays.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
export.pl Bug 18201: Export data -Fix "Remove non-local items" option and add "Removes non-local records" option for existing functionality 2017-12-21 13:10:03 -03:00
holidays.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
import_borrowers.pl Bug 12598: Add use Koha::Patron::debarments statement 2018-02-16 14:05:17 -03:00
inventory.pl Bug 20067: Fix other checks for linked authorised value categories 2018-03-26 17:01:10 -03:00
koha-news.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
letter.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
manage-marc-import.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
marc_modification_templates.pl Bug 16295: Fix access to MMT admin page 2017-05-28 22:09:35 -04:00
modborrowers.pl Bug 19673: Allow to set patron attributes to 0 with batch patron modification 2018-03-28 16:04:47 -03:00
newHolidays.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
overduerules.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
picture-upload.pl Bug 17829: Move GetMember to Koha::Patron 2017-07-10 13:14:19 -03:00
quotes-upload.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
quotes.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
scheduler.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
showdiffmarc.pl Bug 19040: [QA Follow-up] Adjust embed_items parameter in showdiffmarc 2017-08-25 10:23:42 -03:00
stage-marc-import.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
tools-home.pl Bug 18403: Patron reviews 2018-02-12 15:41:41 -03:00
upload-cover-image.pl Bug 20017: use Modern::Perl in Tools perl scripts 2018-02-05 09:46:45 -03:00
upload-file.pl Bug 17501: Rename Upload to Uploader 2017-01-20 14:20:06 +00:00
upload.pl Bug 19420: (QA Follow-up) Change in error reporting affects upload.pl 2017-11-08 13:31:37 -03:00
viewlog.pl Bug 18789: (QA follow-up) Fix viewlog when accessed via circulation 2018-02-16 13:03:59 -03:00