Bug 35360 - Inconsistent use/look of 'Cancel hold(s)' button on circ/waitingreserves.pl
Summary: Inconsistent use/look of 'Cancel hold(s)' button on circ/waitingreserves.pl
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Lucas Gass (lukeg)
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-17 15:29 UTC by Lucas Gass (lukeg)
Modified: 2024-12-20 21:52 UTC (History)
7 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:
24.05.00,23.11.03,23.05.09
Circulation function:


Attachments
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt (5.26 KB, patch)
2023-12-12 22:53 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt (6.11 KB, patch)
2023-12-14 12:31 UTC, Philip Orr
Details | Diff | Splinter Review
Screenshot (66.45 KB, image/png)
2023-12-18 11:35 UTC, Tomás Cohen Arazi (tcohen)
Details
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt (7.62 KB, patch)
2023-12-19 15:03 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt (7.72 KB, patch)
2024-01-19 10:58 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Lucas Gass (lukeg) 2023-11-17 15:29:38 UTC
If you go to circ/waitingreserves.pl there are 3 tabs:

-Holds waiting
-Holds waiting past their expiration date
-Holds with cancellation requests

-Holds waiting includes a 'Canceled selected' button at the top of the table. It is with in a #toolbar.

-Holds waiting past their expiration date includes a 'Cancel selected' and a 'Cancel all' button. None are within a #toolbar. The 'Cancel selected' here lacks a Bootstrap .btn class. The 'Cancel all' button does have a .btn class.

-Holds with cancellation requests has neither a 'Cancel selected' or a 'Cancel all' button.


It would be nice if things were a bit more consistent.
Comment 1 Lucas Gass (lukeg) 2023-12-12 22:06:33 UTC
Also a form element ( cancelAllReserve ) cannot be a child element of a span ( #holdsover-cancel-all ). That creates invalid HTML.
Comment 2 Lucas Gass (lukeg) 2023-12-12 22:53:08 UTC
Created attachment 159779 [details] [review]
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt

To test:
1. Have some holds that are waiting, waiting over expiration date, and cancelled waiting holds.
2. Notice the differences between the 3 tables and their related buttons:
-Holds waiting
-Holds waiting past their expiration date
-Holds with cancellation requests

-Holds waiting includes a 'Canceled selected' button at the top of the table. It is with in a #toolbar.

-Holds waiting past their expiration date includes a 'Cancel selected' and a 'Cancel all' button. None are within a #toolbar. The 'Cancel selected' here lacks a Bootstrap .btn class. The 'Cancel all' button does have a .btn class.

-Holds with cancellation requests has neither a 'Cancel selected' or a 'Cancel all' button.

3. APPLY PATCH
4. Look again and the tables/buttons should be more consistent.
5. The 'Holds with cancellation requests: X' tab should now include a 'Cancel selected (X)' button. Make sure is works.
6. Turn on TransferWhenCancelAllWaitingHolds and make sure the hint displays well in the Holds over table.
Comment 3 Philip Orr 2023-12-14 12:31:07 UTC
Created attachment 159833 [details] [review]
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt

To test:
0. Turn on hold cancellation requests in Administration -> Circulation rules.
1. Have some holds that are waiting, waiting over expiration date, and cancelled waiting holds. In order to create holds waiting over expiration date, if you are in ktd, you can use SQL to update the expirationdate in reserves: UPDATE reserves SET expirationdate="2022-01-01" WHERE reserve_id=1; (make sure it's the correct reserve_id!)
1a. If you are not using ktd, you will need to set ReservesMaxPickUpDelay to 0 days, then return the reserved item and then wait one day before it will be marked as over expiration date.
1b. In order to create cancelled waiting holds, you will need to send a cancel request over the OPAC, that is, reserve something after logging in to the OPAC, return it in the staff interface, and then go to the OPAC -> Your Account -> Holds -> click Cancel on the waiting hold.
2. Notice the differences between the 3 tables and their related buttons:
-Holds waiting
-Holds waiting past their expiration date
-Holds with cancellation requests

-Holds waiting includes a 'Canceled selected' button at the top of the table. It is with in a #toolbar.

-Holds waiting past their expiration date includes a 'Cancel selected' and a 'Cancel all' button. None are within a #toolbar. The 'Cancel selected' here lacks a Bootstrap .btn class. The 'Cancel all' button does have a .btn class.

-Holds with cancellation requests has neither a 'Cancel selected' or a 'Cancel all' button.

3. APPLY PATCH
4. Look again and the tables/buttons should be more consistent.
5. The 'Holds with cancellation requests: X' tab should now include a 'Cancel selected (X)' button. Make sure is works.
6. Make sure TransferWhenCancelAllWaitingHolds is set to "Don't transfer" and make sure the hint displays well in the Holds over table.

Signed-off-by: Philip Orr <philip.orr@lmscloud.de>
Comment 4 Philip Orr 2023-12-14 12:34:08 UTC
I fixed the test plan to include extra steps to explain how to create hold cancellation requests and also for displaying the hint when  TransferWhenCancelAllWaitingHolds is set to "Don't Transfer", not to "Transfer".
Comment 5 Victor Grousset/tuxayo 2023-12-15 00:50:45 UTC
old test plan:

> 6. Turn on TransferWhenCancelAllWaitingHolds and make sure the hint displays well in the Holds over table.

From our understanding, it's the opposite. So test plan was changed to fix this.
Comment 6 Tomás Cohen Arazi (tcohen) 2023-12-18 11:35:02 UTC
Lucas, on the 'Holds waiting past their expiration date' tab there's the extra 'Cancell all' button, which ends up too close to the 'Cancel selected' one. Can you please amend the patch to make it have some default padding we might use everywhere between them? Thanks!
Comment 7 Tomás Cohen Arazi (tcohen) 2023-12-18 11:35:57 UTC
Created attachment 159945 [details]
Screenshot
Comment 8 Lucas Gass (lukeg) 2023-12-19 15:03:06 UTC
Created attachment 160010 [details] [review]
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt

To test:
0. Turn on hold cancellation requests in Administration -> Circulation rules.
1. Have some holds that are waiting, waiting over expiration date, and cancelled waiting holds. In order to create holds waiting over expiration date, if you are in ktd, you can use SQL to update the expirationdate in reserves: UPDATE reserves SET expirationdate="2022-01-01" WHERE reserve_id=1; (make sure it's the correct reserve_id!)
1a. If you are not using ktd, you will need to set ReservesMaxPickUpDelay to 0 days, then return the reserved item and then wait one day before it will be marked as over expiration date.
1b. In order to create cancelled waiting holds, you will need to send a cancel request over the OPAC, that is, reserve something after logging in to the OPAC, return it in the staff interface, and then go to the OPAC -> Your Account -> Holds -> click Cancel on the waiting hold.
2. Notice the differences between the 3 tables and their related buttons:
-Holds waiting
-Holds waiting past their expiration date
-Holds with cancellation requests

-Holds waiting includes a 'Canceled selected' button at the top of the table. It is with in a #toolbar.

-Holds waiting past their expiration date includes a 'Cancel selected' and a 'Cancel all' button. None are within a #toolbar. The 'Cancel selected' here lacks a Bootstrap .btn class. The 'Cancel all' button does have a .btn class.

-Holds with cancellation requests has neither a 'Cancel selected' or a 'Cancel all' button.

3. APPLY PATCH
4. Look again and the tables/buttons should be more consistent.
5. The 'Holds with cancellation requests: X' tab should now include a 'Cancel selected (X)' button. Make sure is works.
6. Make sure TransferWhenCancelAllWaitingHolds is set to "Don't transfer" and make sure the hint displays well in the Holds over table.

Signed-off-by: Philip Orr <philip.orr@lmscloud.de>
Comment 9 Lucas Gass (lukeg) 2023-12-19 15:05:13 UTC
(In reply to Tomás Cohen Arazi from comment #6)
> Lucas, on the 'Holds waiting past their expiration date' tab there's the
> extra 'Cancell all' button, which ends up too close to the 'Cancel selected'
> one. Can you please amend the patch to make it have some default padding we
> might use everywhere between them? Thanks!

Thanks Tomas. There is a form called cancelAllReserve, I wrapped it in the Bootstrap btn-group class as I think that is the way to solve the issue.
Comment 10 Marcel de Rooy 2024-01-19 10:58:23 UTC
Created attachment 161205 [details] [review]
Bug 35360: Make HTML/buttons consistent on waitingreserves.tt

To test:
0. Turn on hold cancellation requests in Administration -> Circulation rules.
1. Have some holds that are waiting, waiting over expiration date, and cancelled waiting holds. In order to create holds waiting over expiration date, if you are in ktd, you can use SQL to update the expirationdate in reserves: UPDATE reserves SET expirationdate="2022-01-01" WHERE reserve_id=1; (make sure it's the correct reserve_id!)
1a. If you are not using ktd, you will need to set ReservesMaxPickUpDelay to 0 days, then return the reserved item and then wait one day before it will be marked as over expiration date.
1b. In order to create cancelled waiting holds, you will need to send a cancel request over the OPAC, that is, reserve something after logging in to the OPAC, return it in the staff interface, and then go to the OPAC -> Your Account -> Holds -> click Cancel on the waiting hold.
2. Notice the differences between the 3 tables and their related buttons:
-Holds waiting
-Holds waiting past their expiration date
-Holds with cancellation requests

-Holds waiting includes a 'Canceled selected' button at the top of the table. It is with in a #toolbar.

-Holds waiting past their expiration date includes a 'Cancel selected' and a 'Cancel all' button. None are within a #toolbar. The 'Cancel selected' here lacks a Bootstrap .btn class. The 'Cancel all' button does have a .btn class.

-Holds with cancellation requests has neither a 'Cancel selected' or a 'Cancel all' button.

3. APPLY PATCH
4. Look again and the tables/buttons should be more consistent.
5. The 'Holds with cancellation requests: X' tab should now include a 'Cancel selected (X)' button. Make sure is works.
6. Make sure TransferWhenCancelAllWaitingHolds is set to "Don't transfer" and make sure the hint displays well in the Holds over table.

Signed-off-by: Philip Orr <philip.orr@lmscloud.de>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 11 Katrin Fischer 2024-01-26 14:17:42 UTC
Pushed for 24.05!

Well done everyone, thank you!
Comment 12 Fridolin Somers 2024-01-31 13:25:37 UTC
Pushed to 23.11.x for 23.11.03
Comment 13 Lucas Gass (lukeg) 2024-02-09 20:05:35 UTC
Backported to 23.05.x for upcoming 23.05.09