Bug 36797: Change WHILE loop into FOREACH
authorLucas Gass <lucas@bywatersolutions.com>
Tue, 7 May 2024 16:03:54 +0000 (16:03 +0000)
committerFridolin Somers <fridolin.somers@biblibre.com>
Wed, 29 May 2024 09:23:36 +0000 (11:23 +0200)
commitc57751bb6483ba6a68b566c7c5803969713398f1
treee054be634764d04c4ee21d96c72c544e65927444
parent71b9421451dce017c12b82f34240431d4069a288
Bug 36797: Change WHILE loop into FOREACH

To test:
1. Find a record that has 1000 non-waiting holds with different priorities.
2. Try loading the reserve page for that record ( /reserve/request.pl?biblionumber=X )
3. Error: Template process failed: undef error - WHILE loop terminated (> 1000 iterations)
4. APPLY PATCH
5. Try again, this time the page should load.
6. Try testing on a record with less than 1000 holds, making sure the priorities are still set right.
7. Make sure you can change your priorities and everything works right.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 5cc42c162c51aa3624f5e46e2ad6c70dd5ee6f01)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc