Summary: | "Please select at least one suggestion" when doing a catalog search from suggestions page | ||
---|---|---|---|
Product: | Koha | Reporter: | Katrin Fischer <katrin.fischer> |
Component: | Templates | Assignee: | Owen Leonard <oleonard> |
Status: | CLOSED FIXED | QA Contact: | Testopia <testopia> |
Severity: | normal | ||
Priority: | P5 - low | CC: | Laura.escamilla, lucas, nick |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
GIT URL: | Change sponsored?: | --- | |
Patch complexity: | Small patch | Documentation contact: | |
Documentation submission: | Text to go in the release notes: | ||
Version(s) released in: |
23.05.00,22.11.05
|
Circulation function: | |
Bug Depends on: | |||
Bug Blocks: | 34080 | ||
Attachments: |
Bug 33322: Refine click handler for suggestion batch operations
Bug 33322: Refine click handler for suggestion batch operations Bug 33322: Refine click handler for suggestion batch operations Bug 33322: (QA follow-up) Add comment to clarify selector context |
Description
Katrin Fischer
2023-03-23 15:02:06 UTC
Created attachment 148657 [details] [review] Bug 33322: Refine click handler for suggestion batch operations The handler for suggestion batch operations looks for clicks on "button[type='submit']" which is not very specific. With the new staff interface this ends up including the header search form. This patch modifies the markup of the batch operations section of the template and makes the click handler more specific so that only the right buttons are affected. To test, apply the patch and go to Suggestions. - In the header search form, perform a catalog search. You should be able to click the submit button to successfully initiate the search. - Without checking a checkbox associated with any open suggestion, test the batch operation buttons at the bottom: - Change status - Change item type - Update manager - Delete - Archive All should trigger a JS alert, "Please select at least one suggestion" - Test each batch operation with one or more suggestions selected and confirm that the operation completes successfully. Created attachment 148761 [details] [review] Bug 33322: Refine click handler for suggestion batch operations The handler for suggestion batch operations looks for clicks on "button[type='submit']" which is not very specific. With the new staff interface this ends up including the header search form. This patch modifies the markup of the batch operations section of the template and makes the click handler more specific so that only the right buttons are affected. To test, apply the patch and go to Suggestions. - In the header search form, perform a catalog search. You should be able to click the submit button to successfully initiate the search. - Without checking a checkbox associated with any open suggestion, test the batch operation buttons at the bottom: - Change status - Change item type - Update manager - Delete - Archive All should trigger a JS alert, "Please select at least one suggestion" - Test each batch operation with one or more suggestions selected and confirm that the operation completes successfully. Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com> Created attachment 148925 [details] [review] Bug 33322: Refine click handler for suggestion batch operations The handler for suggestion batch operations looks for clicks on "button[type='submit']" which is not very specific. With the new staff interface this ends up including the header search form. This patch modifies the markup of the batch operations section of the template and makes the click handler more specific so that only the right buttons are affected. To test, apply the patch and go to Suggestions. - In the header search form, perform a catalog search. You should be able to click the submit button to successfully initiate the search. - Without checking a checkbox associated with any open suggestion, test the batch operation buttons at the bottom: - Change status - Change item type - Update manager - Delete - Archive All should trigger a JS alert, "Please select at least one suggestion" - Test each batch operation with one or more suggestions selected and confirm that the operation completes successfully. Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Created attachment 148926 [details] [review] Bug 33322: (QA follow-up) Add comment to clarify selector context I got confused and thought we had a second selector, added a comment as a reminder - feel free to drop that RM Pushed to master for 23.05. Nice work everyone, thanks! Please backport, this was originally spotted in 22.11 Nice work, thanks everyone! Pushed to 22.11.x for the next release. Doesn't apply cleanly to 22.05.x, no backport. If needed please rebase. The bug is a result of the new staff interface so 22.05.x shouldn't need it (In reply to Owen Leonard from comment #10) > The bug is a result of the new staff interface so 22.05.x shouldn't need it Thanks Owen. |