When viewing a list, the focus/cursor is no longer on the "add items" field below the list. Previously a user could simply scan or enter barcode numbers to add multiple items. Now a user must manually focus on this field for each added item, slowing list creation.
Created attachment 23921 [details] [review] Moved add barcode to be focus I've moved the barcode interface to the top of the page. I'm not sure if the barcode interface should go there though. Maybe it can be redirected to focus at the bottom of the page if it previously has just entered a barcode.
I like the idea that we might place focus on the input field if the page is being redisplayed after a barcode was entered. If we did might even add an "Add item" link to the page which lists existing shelves. I don't think this patch is the correct solution, and anyway it inadvertently adds a couple of patch files which we don't want.
I'll second Owen's comment. Permit me to expand my explanation. Before 3.14 when one loaded this shelves.pl page for a certain list, the focus (cursor) went to the "add items" barcode field. To create a list, one would then just scan (or type in) an item barcode. The page would then reload with the new item in the list. Adding another item was a simple as scanning yet another barcode. Quick list creation (especially for merging items!) Now, the focus does not go to any field. To create a list now, I have place the cursor in the barcode field (or tab to it), scan the item. Then to add a second item, scroll down, again place the cursor, scan. I list of ten items used to require ten scans. Now it requires ten scans, plus ten mouse movements and clicks, plus scrolling as the list gets longer. The solution does not seem to be to move the location of the "add item" field, but to make the focus on the page load on that barcode field. That would restore the earlier functionality.
In 3.14.01 the bug is even worse ... Now, the focus is not by default on the "add barcode" field, but when data is entered into this field, whether by scanner or keyboard, focus is immediately sent to the "search the catalog" field at the top of the page. This makes it impossible to create lists except by searching for the item in the catalog and adding it to the list from the biblio details. Perhaps our library just disproportionately affected because of needing to clean up an imported database with lots of records needing to be merged, but it seems that whatever patches were applied between 3.12 and 3.14.01 have effectively broken this part of the list feature. That doesn't seem to me to be a "low minor bug". A seriously broken feature doesn't seem minor, or low priority.
If it helps, I've done some playing around to try to contribute more than just complaints. I think I know why the bug is happening and have a few ways to try to solve it, but have no idea how to patch things or use git, etc. Here goes: The focus problem is because shelves.tt calls [% INCLUDE 'cat-search.inc' %]. This include gives #findborrower the class "focus". jQuery then assigns the focus to this field which is hidden on this page by default. The catalog search is visible by default. I fixed the jumpy cursor by editing shelves.tt and adding 'class="focus"'. This does not give it focus, #findborrower still steals it, but at least now data can be entered. It seems that having the include give focus to #findborrower is a bad way of defaulting. Rather each tt should independently give focus to the proper element for this page. Thus, the solution seems to be to edit cat-search.inc, removing focus from #findborrower, then on each tt page assign focus to the appropriate field. Another default is to throw some javascript in that steals focus back to the field we would want.
(In reply to Ian Palko from comment #4) > Now, the focus is not by default on the "add barcode" field, but when data > is entered into this field, whether by scanner or keyboard, focus is > immediately sent to the "search the catalog" field at the top of the page. This sounds like Bug 11567. Are you using a non-English translation which needs to be updated?
(In reply to Owen Leonard from comment #6) > (In reply to Ian Palko from comment #4) > > Now, the focus is not by default on the "add barcode" field, but when data > > is entered into this field, whether by scanner or keyboard, focus is > > immediately sent to the "search the catalog" field at the top of the page. > > This sounds like Bug 11567. Are you using a non-English translation which > needs to be updated? In fact, no. We've used the main English koha without any translation since 3.6. I've never run or needed to run koha-translate.
Be carefull your patch adds a backup file : /koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt~
Created attachment 40231 [details] [review] Bug 11325 - Focus not on "Add Item" in Lists When viewing a list, the focus/cursor is no longer on the "add items" field below the list. This patch moves the "Add Item" form at left part of page so that it is always shown (usefull when there are a lot of items). And adds focus to barcode input so you can enter several items with a barcode scanner. Test instructions: 1. Create a list 2. Make sure you have an object with an assigned barcode 3. Go to the list => The barcode entry interface should be at left and has the focus 4. Enter the barcode and press enter (or use a scanner) => The item is added to the list
I propose another patch, nearlyby : It moves the "Add Item" form at left part of page so that it is always shown (usefull when there are a lot of items). And adds focus to barcode input so you can enter several items with a barcode scanner.
It set this as enhancement, I think its not a bug.
Comment on attachment 23921 [details] [review] Moved add barcode to be focus First patch obsoleted, is malformed and think Fridolin solution es simpler an elegant.
Created attachment 40421 [details] [review] [SIGNED-OFF] Bug 11325: Focus not on "Add Item" in Lists When viewing a list, the focus/cursor is no longer on the "add items" field below the list. This patch moves the "Add Item" form at left part of page so that it is always shown (usefull when there are a lot of items). And adds focus to barcode input so you can enter several items with a barcode scanner. Test instructions: 1. Create a list 2. Make sure you have an object with an assigned barcode 3. Go to the list => The barcode entry interface should be at left and has the focus 4. Enter the barcode and press enter (or use a scanner) => The item is added to the list Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> I like the new position. Works well, focus on input box No errors
Created attachment 40475 [details] [review] Bug 11325: Focus not on "Add Item" in Lists When viewing a list, the focus/cursor is no longer on the "add items" field below the list. This patch moves the "Add Item" form at left part of page so that it is always shown (usefull when there are a lot of items). And adds focus to barcode input so you can enter several items with a barcode scanner. Test instructions: 1. Create a list 2. Make sure you have an object with an assigned barcode 3. Go to the list => The barcode entry interface should be at left and has the focus 4. Enter the barcode and press enter (or use a scanner) => The item is added to the list Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> I like the new position. Works well, focus on input box No errors Signed-off-by: Jonathan Druart <jonathan.druart@koha-community.org>
*** Bug 14663 has been marked as a duplicate of this bug. ***
Patch pushed to master. Good one Frido!
*** Bug 17280 has been marked as a duplicate of this bug. ***