Bug 7469: put focus on 1st field of creation form instead of search box (Acquisition)
When a user creates a new vendor, a new borrower or a new basket (maybe on others page too, to be listed), a creation form is displayed, but the focus is still on the search textbox on page top. It would be probably better to switch the focus to the first field of the creation form. This patch adds the focus, for acquisitions module, on first input for pages with a data creation or modification or pages with only one form (like Z3950 search). Test plan : Go to pages and look where is the focus : - acqui/basketgroup.pl : focus on "Basket group name:" - acqui/basketheader.pl : focus on "Basket name:" - acqui/invoices.tt : focus on "Invoice no:" - acqui/modordernotes.pl : focus on "Notes:" - acqui/neworderempty.pl : focus on "Title:" - acqui/supplier.pl : focus on "Name:" - acqui/z3950_search.pl : focus on "Title:" Signed-off-by: Melia Meggs <melia@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> The focus choice is relevant and works as described. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
This commit is contained in:
parent
301d20715f
commit
f92c74b65a
7 changed files with 7 additions and 7 deletions
|
@ -182,7 +182,7 @@ function submitForm(form) {
|
|||
<fieldset id="various" class="brief">
|
||||
<ol>
|
||||
<li><label for="basketgroupname">Basket group name:</label>
|
||||
<input type="text" name="basketgroupname" id="basketgroupname" value="[% name %]" /></li>
|
||||
<input type="text" name="basketgroupname" id="basketgroupname" value="[% name %]" class="focus" /></li>
|
||||
<li><label for="billingplace">Billing place:</label>
|
||||
<select name="billingplace" id="billingplace" style="width:13em;">
|
||||
<option value="">--</option>
|
||||
|
|
|
@ -66,7 +66,7 @@ function Check(ff) {
|
|||
[% END %]
|
||||
<li>
|
||||
<label for="basketname" class="required">Basket name: </label>
|
||||
<input type="text" name="basketname" id="basketname" size="40" maxlength="80" value="[% basketname %]" />
|
||||
<input type="text" name="basketname" id="basketname" size="40" maxlength="80" value="[% basketname %]" class="focus" />
|
||||
</li>
|
||||
<li>
|
||||
<label for="billingplace">Billing place:</label>
|
||||
|
|
|
@ -145,7 +145,7 @@ $(document).ready(function() {
|
|||
<ol>
|
||||
<li>
|
||||
<label for="invoicenumber">Invoice no:</label>
|
||||
<input type="text" id="invoicenumber" name="invoicenumber" value="[% invoicenumber %]" />
|
||||
<input type="text" id="invoicenumber" name="invoicenumber" value="[% invoicenumber %]" class="focus" />
|
||||
</li>
|
||||
<li>
|
||||
<label for="supplier">Vendor:</label>
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
<form action="/cgi-bin/koha/acqui/modordernotes.pl" method="post">
|
||||
<fieldset class="brief">
|
||||
<label for="ordernotes">Notes:</label>
|
||||
<textarea id="ordernotes" name="ordernotes" rows="3" cols="30">[% ordernotes %]</textarea>
|
||||
<textarea id="ordernotes" name="ordernotes" rows="3" cols="30" class="focus">[% ordernotes %]</textarea>
|
||||
</fieldset>
|
||||
<input type="hidden" name="referrer" value="[% referrer %]" />
|
||||
<input type="hidden" name="ordernumber" value="[% ordernumber %]" />
|
||||
|
|
|
@ -239,7 +239,7 @@ $(document).ready(function()
|
|||
<input type="hidden" name="title" value="[% title |html %]" /> <span class="title">[% title |html %]</span>
|
||||
[% ELSE %]
|
||||
<label for="entertitle" class="required">Title: </label>
|
||||
<input type="text" id="entertitle" size="50" name="title" value="[% title |html %]" />
|
||||
<input type="text" id="entertitle" size="50" name="title" value="[% title |html %]" class="focus" />
|
||||
[% END %]
|
||||
</li>
|
||||
<li>
|
||||
|
|
|
@ -66,7 +66,7 @@ if (f.company.value == "") {
|
|||
<fieldset class="rows">
|
||||
<legend>Company details</legend>
|
||||
<ol><li><label for="company" class="required">Name: * </label>
|
||||
<input type="text" size="40" id="company" name="company" value="[% name %]" /></li>
|
||||
<input type="text" size="40" id="company" name="company" value="[% name %]" class="focus" /></li>
|
||||
<li><label for="company_postal">Postal address: </label>
|
||||
<textarea id="company_postal" name="company_postal" cols="40" rows="3">[% postal %]</textarea></li>
|
||||
<li><label for="physical">Physical address: </label>
|
||||
|
|
|
@ -90,7 +90,7 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
|
|||
<div class="yui-g">
|
||||
<div class="yui-u first">
|
||||
<fieldset class="rows">
|
||||
<ol><li><label for="searchtitle">Title: </label> <input type="text" id="searchtitle" name="title" value="[% title |html %]" /></li>
|
||||
<ol><li><label for="searchtitle">Title: </label> <input type="text" id="searchtitle" name="title" value="[% title |html %]" class="focus" /></li>
|
||||
<li><label for="isbn">ISBN: </label> <input type="text" id="isbn" name="isbn" value="[% isbn %]" /></li>
|
||||
<li><label for="lccall">LC call number: </label> <input type="text" id="lccall" name="lccall" value="" /></li>
|
||||
<li><label for="controlnumber">Control no.: </label> <input type="text" id="controlnumber" name="controlnumber" value="" /></li>
|
||||
|
|
Loading…
Reference in a new issue