Bug 28079 - Set focus to search box field when adding an order to basket
Summary: Set focus to search box field when adding an order to basket
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Acquisitions (show other bugs)
Version: master
Hardware: All All
: P5 - low trivial (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-04-02 15:45 UTC by Séverine Queune
Modified: 2021-10-22 15:36 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Text to go in the release notes:
Version(s) released in:
21.11.00


Attachments
Bug 28079: Set focus to search box field when adding an order to basket (7.55 KB, patch)
2021-10-11 18:17 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 28079: Set focus to search box field when adding an order to basket (7.60 KB, patch)
2021-10-11 20:12 UTC, David Nind
Details | Diff | Splinter Review
Bug 28079: Set focus to search box field when adding an order to basket (7.67 KB, patch)
2021-10-19 21:53 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Séverine Queune 2021-04-02 15:45:58 UTC
When adding an order to a basket, you have to click in the input box before searching for an existing record.
It could be usefull if the cursor was focused on the search box.
Comment 1 Owen Leonard 2021-10-11 18:17:19 UTC
Created attachment 126049 [details] [review]
Bug 28079: Set focus to search box field when adding an order to basket

This patch modifies the "Add to basket" modal in acquisitions so that
focus is automatically moved to the first form field when the modal
appears.

The patch also corrects the modal markup so that it's more consistent
with default Bootstrap markup.

To test, apply the patch and go to Acquisitions.

- Search for a vendor and, if necessary, create a basket.
- Click the "Add to basket" button. The modal which appears should
  have a header reading "Add order to basket <basketname>"
- The form field should have cursor focus.
- View the basket and click the "Add to basket" button in the toolbar.
- The modal shown should also be correct.
Comment 2 David Nind 2021-10-11 20:12:42 UTC
Created attachment 126050 [details] [review]
Bug 28079: Set focus to search box field when adding an order to basket

This patch modifies the "Add to basket" modal in acquisitions so that
focus is automatically moved to the first form field when the modal
appears.

The patch also corrects the modal markup so that it's more consistent
with default Bootstrap markup.

To test, apply the patch and go to Acquisitions.

- Search for a vendor and, if necessary, create a basket.
- Click the "Add to basket" button. The modal which appears should
  have a header reading "Add order to basket <basketname>"
- The form field should have cursor focus.
- View the basket and click the "Add to basket" button in the toolbar.
- The modal shown should also be correct.

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 Katrin Fischer 2021-10-19 21:53:09 UTC
Created attachment 126554 [details] [review]
Bug 28079: Set focus to search box field when adding an order to basket

This patch modifies the "Add to basket" modal in acquisitions so that
focus is automatically moved to the first form field when the modal
appears.

The patch also corrects the modal markup so that it's more consistent
with default Bootstrap markup.

To test, apply the patch and go to Acquisitions.

- Search for a vendor and, if necessary, create a basket.
- Click the "Add to basket" button. The modal which appears should
  have a header reading "Add order to basket <basketname>"
- The form field should have cursor focus.
- View the basket and click the "Add to basket" button in the toolbar.
- The modal shown should also be correct.

Signed-off-by: David Nind <david@davidnind.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 4 Jonathan Druart 2021-10-21 08:32:51 UTC
Pushed to master for 21.11, thanks to everybody involved!