Bug 31407: Set focus for cursor to Currency when adding a new currency
authorKatrin Fischer <katrin.fischer.83@web.de>
Sat, 4 Feb 2023 23:58:05 +0000 (23:58 +0000)
committerArthur Suzuki <arthur.suzuki@biblibre.com>
Fri, 17 Feb 2023 13:03:19 +0000 (14:03 +0100)
This makes sure that the focus is on the first field of the
form when adding a new currency.

To test:
* Go to administration > currencies
* Add a new currency
* Verify the focus is not on the form
* Apply patch
* Repeat, verify the focus is now on the first input "currency"

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit fcb19865e82c6389f64a984ed8ef0dbde5afc2d7)
Signed-off-by: Jacob O'Mara <jacob.omara@ptfs-europe.com>
(cherry picked from commit 1d19b62a24a50f3458040881e3463e7d827d5612)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit f09eed687cf35f9c4f8423cda74be5ca4ed3ec0f)
Signed-off-by: Arthur Suzuki <arthur.suzuki@biblibre.com>
koha-tmpl/intranet-tmpl/prog/en/modules/admin/currency.tt

index cc9fce0..c12b362 100644 (file)
                     <input type="hidden" name="currency_code" id="currency" value="[% currency.currency | html %]" />[% currency.currency | html %]
                 [% ELSE %]
                     <label for="currency_code" class="required">Currency: </label>
-                    <input type="text" name="currency_code" id="currency_code" size="50" maxlength="50" required="required" class="required" /> <span class="required">Required</span>
+                    <input type="text" name="currency_code" id="currency_code" class="focus" size="50" maxlength="50" required="required" class="required" /> <span class="required">Required</span>
                 [% END %]
             </li>
             <li>