[Koha-bugs] [Bug 11325] Focus not on "Add Item" in Lists

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Sat Jan 25 03:39:53 CET 2014


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=11325

--- Comment #5 from Ian Palko <library at stas.org> ---
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.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list