Koha How-To

Koha Lists Form Focus

I’ve had a few partners contacting me asking if there is a way to make the cursor focus on ‘add to’ box on the lists function in the Koha staff client. The answer is of course!

So, when looking at a list in the staff client, the box to add more items to the list is at the bottom:

Add to Koha List

If you’d like your cursor to focus down in that box by default you just have to add the following to your intranetuserjs system preference:

[code language=”javascript” wraplines=”true” toolbar=”true”]
$(document).ready(function(){
if (window.location.href.indexOf("virtualshelves/shelves.pl") > -1) {
$("input[name=’addbarcode’]").focus();
}
});
[/code]

See this and other custom JQuery on the Koha wiki.