[Bug 40654] New: Sorting holds table can cause priority issues
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Bug ID: 40654 Summary: Sorting holds table can cause priority issues Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: major Priority: P5 - low Component: Hold requests Assignee: koha-bugs@lists.koha-community.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, lisette@bywatersolutions.com, tomascohen@gmail.com The table of holds has oddities about how holds are updated, and the datatables sorting has made this worse. To recreate: 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - See all the other priorities change 6 - Click 'Update holds' 7 - Many unintended changes are saved 8 - Sort alphabetically the other direction and click the arrow to move another hold to the top - weirdness occurs I also saw that only 19-20 holds would be affect sometimes, I think sorting on this table may need to rethought -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |33575 CC| |lucas@bywatersolutions.com Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33575 [Bug 33575] Add table settings to the holds table for a specific record in the staff interface -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |lucas@bywatersolutions.com |ity.org | -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|lucas@bywatersolutions.com |koha-bugs@lists.koha-commun | |ity.org --- Comment #1 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- This is because when rank-request is changed there is JS to move the entire row with insertBefore/insertAfter, I don't think we should be doing that with a dataTable. Instead we should only be adjusting the other priorities when a change is made to one. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |lucas@bywatersolutions.com |ity.org | -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Daniel B. <dbarden@cuyahogalibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dbarden@cuyahogalibrary.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Kristi Krueger <kkrueger@cuyahogalibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kkrueger@cuyahogalibrary.or | |g -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #2 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 185419 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185419&action=edit Bug 40654: Fix how rank/priority is adjusted when changing from the UI To test: 0 - APPLY PATCH 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - All the priorities should now ajust accordingly but they will NOT be resorted on the fly 6 - Play with adjusting some priorities, making sure everything correctly adjusts. 7 - Click 'Update holds' to make sure the priorities adjust right 8 - Make sure you test with the 'del' option and the adjustments still work. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #3 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- This patch makes it so we no longer move the entire row around, we shouldn't do that in a dataTable. Instead, it recalculates priority for all holds on the record after one priority is changed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 David Flater <flaterdavid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #185419|0 |1 is obsolete| | --- Comment #4 from David Flater <flaterdavid@gmail.com> --- Created attachment 185477 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185477&action=edit Bug 40654: Fix how rank/priority is adjusted when changing from the UI To test: 0 - APPLY PATCH 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - All the priorities should now ajust accordingly but they will NOT be resorted on the fly 6 - Play with adjusting some priorities, making sure everything correctly adjusts. 7 - Click 'Update holds' to make sure the priorities adjust right 8 - Make sure you test with the 'del' option and the adjustments still work. Signed-off-by: David Flater <flaterdavid@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 David Flater <flaterdavid@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |flaterdavid@gmail.com Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |emily.lamancusa@montgomeryc | |ountymd.gov Status|Signed Off |Failed QA --- Comment #5 from Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> --- Sorting worked correctly for every combination I tested, but there still seems to be some weirdness with the 'del' option. For example: I placed 10 holds on a bib for the following patrons, in the following order: 1. Marie Mcknight 2. Floyd Delgado 3. Joyce Gaines 4. Edna Acosta 5. Henry Acevedo 6. Nicole Schneider 7. Mary Burton 8. Terrence Mcconnell 9. Marilyn Mcfarland 10. Marcus Welch Then sorted the holds table alphabetically: 4. Edna 2. Floyd 5. Henry 3. Joyce 10. Marcus 1. Marie 9. Marilyn 7. Mary 6. Nicole 8. Terrence Next, I used the 'del' option to cancel Floyd's hold, and noticed the following errors in the priority calculation: Name Original Rank Expected Actual Edna 4 3 2 X Henry 5 4 4 Joyce 3 2 3 X Marcus 10 9 7 X Marie 1 1 1 Marilyn 9 8 9 X Mary 7 6 6 Nicole 6 5 5 Terrence 8 7 8 X In other words, Edna skipped ahead to rank 2 instead of 3, pushing Joyce down one. Marcus skipped ahead to rank 7 instead of 9, pushing Marilyn and Terrence down one. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #6 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Ah! Thanks, Emily. I think I see the problem with the 'del', a fix is incoming! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #185477|0 |1 is obsolete| | --- Comment #7 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 185589 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185589&action=edit Bug 40654: Fix how rank/priority is adjusted when changing from the UI To test: 0 - APPLY PATCH 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - All the priorities should now ajust accordingly but they will NOT be resorted on the fly 6 - Play with adjusting some priorities, making sure everything correctly adjusts. 7 - Click 'Update holds' to make sure the priorities adjust right 8 - Make sure you test with the 'del' option and the adjustments still work. Signed-off-by: David Flater <flaterdavid@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #185589|0 |1 is obsolete| | --- Comment #8 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 185590 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185590&action=edit Bug 40654: Fix how rank/priority is adjusted when changing from the UI To test: 0 - APPLY PATCH 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - All the priorities should now ajust accordingly but they will NOT be resorted on the fly 6 - Play with adjusting some priorities, making sure everything correctly adjusts. 7 - Click 'Update holds' to make sure the priorities adjust right 8 - Make sure you test with the 'del' option and the adjustments still work. Signed-off-by: David Flater <flaterdavid@gmail.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #9 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 185597 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185597&action=edit Bug 40654: Adjust display to show current priority -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #185597|0 |1 is obsolete| | --- Comment #10 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 185600 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185600&action=edit Bug 40654: Adjust display to show current priority -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |String patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #185590|0 |1 is obsolete| | --- Comment #11 from Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> --- Created attachment 185605 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185605&action=edit Bug 40654: Fix how rank/priority is adjusted when changing from the UI To test: 0 - APPLY PATCH 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - All the priorities should now ajust accordingly but they will NOT be resorted on the fly 6 - Play with adjusting some priorities, making sure everything correctly adjusts. 7 - Click 'Update holds' to make sure the priorities adjust right 8 - Make sure you test with the 'del' option and the adjustments still work. Signed-off-by: David Flater <flaterdavid@gmail.com> Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #185600|0 |1 is obsolete| | --- Comment #12 from Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> --- Created attachment 185606 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185606&action=edit Bug 40654: Adjust display to show current priority Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Emily Lamancusa (emlam) <emily.lamancusa@montgomerycountymd.gov> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Patch complexity|String patch |Trivial patch QA Contact|testopia@bugs.koha-communit |emily.lamancusa@montgomeryc |y.org |ountymd.gov -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #13 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Created attachment 185630 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=185630&action=edit Bug 40654: [24.11.x] Fix how rank/priority is adjusted when changing from the UI To test: 0 - APPLY PATCH 1 - Place 50 holds on a bib record https://github.com/kidclamp/handy-koha-script/blob/main/randhold.pl 2 - View the holds page for the record 3 - Sort the holds alphabetically 4 - Change the dropdown priortiy for the alphabetically first hold to 1 5 - All the priorities should now ajust accordingly but they will NOT be resorted on the fly 6 - Play with adjusting some priorities, making sure everything correctly adjusts. 7 - Click 'Update holds' to make sure the priorities adjust right 8 - Make sure you test with the 'del' option and the adjustments still work. Signed-off-by: David Flater <flaterdavid@gmail.com> Signed-off-by: Emily Lamancusa <emily.lamancusa@montgomerycountymd.gov> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #14 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- squashed and rebased for 24.11.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |25.11.00 released in| | Status|Passed QA |Pushed to main -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #15 from Lucas Gass (lukeg) <lucas@bywatersolutions.com> --- Nice work everyone! Pushed to main for 25.11 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This patchset fixes a release notes| |problem where hold priority | |could be incorrectly | |updated depending on how | |the table is sorted on | |reserve/request.tt. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |rel_23_11_candidate, | |rel_24_05_candidate, | |rel_24_11_candidate, | |rel_25_05_candidate -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Lucas Gass (lukeg) <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |40706 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40706 [Bug 40706] Improve the display of priority on reserve/request.pl -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Paul Derscheid <paul.derscheid@lmscloud.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to main |Pushed to stable Version(s)|25.11.00 |25.11.00,25.05.03 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 --- Comment #16 from Paul Derscheid <paul.derscheid@lmscloud.de> --- Nice work everyone! Pushed to 25.05.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Michelle Spinney <mspinney@clamsnet.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mspinney@clamsnet.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m Status|Pushed to stable |Pushed to oldstable Version(s)|25.11.00,25.05.03 |25.11.00,25.05.03,24.11.09 released in| | --- Comment #17 from Fridolin Somers <fridolin.somers@biblibre.com> --- Pushed to 24.11.x for 24.11.09 Thanks a lot for dedicated patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Paul Derscheid <paul.derscheid@lmscloud.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|rel_25_05_candidate | CC| |paul.derscheid@lmscloud.de -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40654 Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to oldstable |Needs documenting CC| |wainuiwitikapark@catalyst.n | |et.nz --- Comment #18 from Wainui Witika-Park <wainuiwitikapark@catalyst.net.nz> --- Not backporting to 22.11.x as it wasn't backported to 24.05.x -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org