Browse Source

Bug 27192: Automatically set focus to the item type input box

When adding a new item type, you have to click inside the
"Ιtem type:" input box before you can start entering text.

This patch fixes that by adding the "focus" class to the relevant
<input> element so that cursor focus is set when the page loads.

Test plan:

1) Try to add a new item type: notice how you have to manually
   click inside the "Item type:" input box before you start typing.
2) Apply this patch.
3) Repeat step 1) -- this time the "Item type:" input box should
   gain focus automatically.

Signed-off-by: Kelly McElligott <kelly@bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
21.05.x
Andreas Roussos 3 years ago
committed by Jonathan Druart
parent
commit
a219a78239
  1. 2
      koha-tmpl/intranet-tmpl/prog/en/modules/admin/itemtypes.tt

2
koha-tmpl/intranet-tmpl/prog/en/modules/admin/itemtypes.tt

@ -112,7 +112,7 @@ Item types administration
[% ELSE %]
<li>
<label for="itemtype" class="required">Item type: </label>
<input type="text" id="itemtype" name="itemtype" size="10" maxlength="10" required="required" /> <span class="required">Required</span>
<input type="text" id="itemtype" name="itemtype" size="10" maxlength="10" required="required" class="focus" /> <span class="required">Required</span>
</li>
[% END %]
<li>

Loading…
Cancel
Save