Bug 8521 - Error in warning message when deleting list
authorOwen Leonard <oleonard@myacpl.org>
Tue, 15 Jul 2014 19:35:54 +0000 (15:35 -0400)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Tue, 5 Aug 2014 23:44:28 +0000 (20:44 -0300)
commitb3cd7f110a7535d597060a2d654dcc3e404e34f0
tree72217352a2b0dba15d150373da4b29305c817f3f
parent2197d1280622923b0c1046dd079fc8ea0c418154
Bug 8521 - Error in warning message when deleting list

When deleting a list the operation is blocked if there are items still
on the list, and the interface shows a warning which includes a count of
the items on the list. This count is broken for lists containing more
items than the number specified in the numSearchResults system
preference.

This patch corrects the item count to use an actual count of the total
number of results, not the total number of results in the first page of
results.

The template change to the staff client copies some language logic from
the OPAC template for dealing with a single number of list entries.

Test in both the OPAC and the staff client.

Check the number specified in the numSearchResults system preference and
locate or create a list containing more than that number of items. Try
to delete the list. You should receive a warning message stating the
correct total number of items on the list.

Test also with a list which contains fewer than numSearchResults
entries, and a list which contains zero entries.

Signed-off-by: Ian Beardslee <ian@catalyst.net.nz>
Tested Public and Private lists with 0, 5 & 25 entries, Public with 40 and Private with 45.  Working as expected.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Works as described, passes tests and QA script.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/VirtualShelves/Page.pm
koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt